summaryrefslogtreecommitdiffstats
path: root/src/ball.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ball.c')
-rw-r--r--src/ball.c37
1 files changed, 21 insertions, 16 deletions
diff --git a/src/ball.c b/src/ball.c
index 826b210..b8dd78b 100644
--- a/src/ball.c
+++ b/src/ball.c
@@ -20,22 +20,25 @@
#include <stdlib.h>
#include "ball.h"
#include "collision.h"
+#include "tileset.h"
#include "output.h"
struct db_ball {
- double x;
- double y;
- int r;
- double a;
- int d;
- int sr;
- double s;
- struct db_ball *next;
+ double x;
+ double y;
+ int r;
+ double a;
+ int d;
+ int sr;
+ double s;
+ struct db_tileset *tilesets;
+ int gid;
+ struct db_ball *next;
};
struct db_ball *
db_ball_new(int x, int y, int r, int a, int d, int sr, double s,
- struct db_ball *prev)
+ struct db_tileset *tilesets, int gid, struct db_ball *prev)
{
struct db_ball *ball;
@@ -45,13 +48,15 @@ db_ball_new(int x, int y, int r, int a, int d, int sr, double s,
return NULL;
}
- ball->x = x;
- ball->y = y;
- ball->r = r;
- ball->a = a;
- ball->d = d;
- ball->sr = sr;
- ball->s = s;
+ ball->x = x;
+ ball->y = y;
+ ball->r = r;
+ ball->a = a;
+ ball->d = d;
+ ball->sr = sr;
+ ball->s = s;
+ ball->tilesets = tilesets;
+ ball->gid = gid;
if (prev != NULL) {
prev->next = ball;