Mercurial > hg > Members > tkaito > task_dandy
view dandy.h @ 2:6e1afe1016dc
Task is not yet.
author | tkaito |
---|---|
date | Thu, 17 Jun 2010 05:11:29 +0900 |
parents | 7dc2d920fc7c |
children | 7b4c2cfeba45 |
line wrap: on
line source
#include <math.h> #include <stdlib.h> #include "SceneGraph.h" #include "Application.h" #include "MainLoop.h" class dandy : public Application { MainLoopPtr init(Viewer *viewer, int w, int h); }; typedef void (*move)(SceneGraphPtr node, void *sgroot_, int w, int h); typedef void (*coll)(SceneGraphPtr node, void *sgroot_, int w, int h, SceneGraphPtr tree); typedef struct { double x, y; double vx, vy; const char *chara; int vital; int score; void *parent; void *root; } *ObjPropertyPtr, ObjProperty; static const int ENEMY_NUM = 1; extern ObjProperty charactor[ENEMY_NUM]; static const float player_speed = 10.0f; static const float player_radius = 42.0f; static const float boss_radius_x = 65.4f; static const float boss_radius_y = 130.8f; static const float first_boss1_speed = 10.0; static const float first_boss1_depth = 500.0; static const float return_boss1_depth_speed = 10.0; static const float shot_speed = 30.0f; static const float shot_radius = 42.4f; extern void title_move(SceneGraphPtr node, void *sgroot_, int w, int h); extern void title_coll(SceneGraphPtr node, void *sgroot_, int w, int h, SceneGraphPtr tree); extern void dandy_move(SceneGraphPtr node, void *sgroot_, int w, int h); extern void dandy_coll(SceneGraphPtr node, void *sgroot_, int w, int h,SceneGraphPtr tree); extern void create_title(void *sgroot, int w, int h); extern void create_stage(void *sgroot, int w, int h); typedef struct enemy_state { const char *charano; int score; int vital; } state; #define ENEMY_STATUS_TABLE { \ ENEMY_STATUS("test00", 0, 0), \ ENEMY_STATUS("greencrab", 330, 98) \ }