From 6d4e1eae16b84918009625a866104ec26a234277 Mon Sep 17 00:00:00 2001 From: oroborus Date: Fri, 1 Feb 2008 22:59:06 +0000 Subject: nahranie tarballu tuxanci-ng na SVN server Dusan Durech ( Oroborus ) git-svn-id: http://opensvn.csie.org/tuxanci_ng@1 0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e --- src/arena.c | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 src/arena.c (limited to 'src/arena.c') diff --git a/src/arena.c b/src/arena.c new file mode 100644 index 0000000..320a697 --- /dev/null +++ b/src/arena.c @@ -0,0 +1,37 @@ + +#include +#include +#include + +#include "arena.h" +#include "list.h" +#include "tux.h" +#include "shot.h" +#include "wall.h" +#include "item.h" + +arena_t* newArena() +{ + arena_t *new; + new = malloc( sizeof(arena_t) ); + + new->background = NULL; + strcpy(new->music, ""); + + new->listTux = newList(); + new->listShot = newList(); + new->listWall = newList(); + new->listItem = newList(); + + return new; +} + +void destroyArena(arena_t *p) +{ + destroyListItem(p->listTux, destroyTux); + destroyListItem(p->listShot, destroyShot); + destroyListItem(p->listWall, destroyWall); + destroyListItem(p->listItem, destroyItem); + + free(p); +} -- cgit v1.2.3