diff Renderer/Engine/SceneGraph.h @ 760:24a37fe8419a

first of all commit, not work Rendering/Test/create_task
author hiroki
date Thu, 04 Feb 2010 14:46:09 +0900
parents b7376415fa5f
children e4d635b1f018
line wrap: on
line diff
--- a/Renderer/Engine/SceneGraph.h	Mon Feb 01 17:08:36 2010 +0900
+++ b/Renderer/Engine/SceneGraph.h	Thu Feb 04 14:46:09 2010 +0900
@@ -12,6 +12,7 @@
 //                               SceneGraph* tree);
 typedef void (*collision_func)(SceneGraph* node, void *sgroot, int screen_w, int screen_h,
                                SceneGraph* tree);
+typedef void (*create_sg_func)(void *sgroot, void *property, void *update_property);
 typedef SceneGraph* SceneGraphPtr;
 
 class SceneGraph : public Polygon {
@@ -34,7 +35,9 @@
 	int seq;
 	
     int property_size;
-    void* propertyptr;
+    void *propertyptr;
+    void *property;
+    void *update_property;
 
     // xml ファイルから生成した時のオブジェクトリスト
     SceneGraphPtr next;
@@ -65,6 +68,7 @@
     // 関数ポインタ
     move_func move;
     collision_func collision;
+    create_sg_func create_sg;
 
     // desutroctor で呼ばれる
     void (SceneGraph::*finalize)(void);
@@ -74,6 +78,7 @@
     void finalize_copy(void);
     void move_execute(int screen_w, int screen_h);
     void collision_check(int screen_w, int screen_h, SceneGraphPtr tree);
+    void create_sg_execute();
     void all_execute(int screen_w, int screen_h);
 
     void add_next(SceneGraphPtr next);
@@ -84,6 +89,7 @@
     SceneGraphPtr searchSceneGraph(const char *name);
     void set_move_collision(move_func new_move, collision_func new_collision);
     void set_move_collision(move_func new_move, collision_func new_collision, void *sgroot);
+    void set_move_collision(move_func new_move, collision_func new_collision, create_sg_func new_create_sg);
     void remove(void);
     SceneGraphPtr realRemoveFromTree(SceneGraphPtr tree);
     SceneGraphPtr realRemoveFromList(SceneGraphPtr list);