comparison stage_init.cc @ 11:8c7a2e7cb9e0

test
author tkaito
date Sat, 17 Jul 2010 14:12:53 +0900
parents 27d3291a7c82
children aecc2199251e
comparison
equal deleted inserted replaced
10:27d3291a7c82 11:8c7a2e7cb9e0
13 title->xyz[1] = charactor[0].y; 13 title->xyz[1] = charactor[0].y;
14 14
15 back1->addChild(title); 15 back1->addChild(title);
16 16
17 } 17 }
18 /*
19 void
20 title_move(SceneGraphPtr node, void *sgroot_, int w, int h)
21 {
22 sgroot->set_move_task(obj, TITLE_MOVE, (void*)property, size, create_title);
23 }
24
25 void
26 title_coll(SceneGraphPtr node, void *sgroot_, int w, int h, SceneGraphPtr tree)
27 {
28 }
29 */
30 18
31 ObjProperty back_property; 19 ObjProperty back_property;
32 20
33 void 21 void
34 create_title_back(void *sgroot_, int w, int h) 22 create_title_back(Viewer *sgroot_, int w, int h)
35 { 23 {
36 Viewer *sgroot = (Viewer *)sgroot_; 24 Viewer *sgroot = sgroot_;
37 SceneGraphPtr back; 25 SceneGraphPtr back;
38 back_property.flag = 0; 26 back_property.flag = 0;
39 27
40 back = sgroot->createSceneGraph(); 28 back = sgroot->createSceneGraph();
41 //back->set_move_collision(back_move, back_coll);
42 sgroot->setSceneData(back); 29 sgroot->setSceneData(back);
43 30
44 SceneGraphPtr title = (SceneGraphPtr)charactor[0].root; 31 SceneGraphPtr title = (SceneGraphPtr)charactor[0].root;
45 ObjPropertyPtr titlep; 32 ObjProperty titlep;
46 titlep->x = w/2; 33 titlep.x = w/2;
47 titlep->y = h/2; 34 titlep.y = h/2;
48 titlep->root = (void*)title; 35 titlep.root = (void*)title;
49 titlep->parent = (void*)back; 36 titlep.parent = (void*)back;
50 int size = sizeof(ObjProperty)*16; 37 int size = sizeof(ObjProperty)*16;
51 //sgroot->set_move_property(title, title_move, (void*)property, size); 38 sgroot->set_move_task(title, TITLE_MOVE, (void*)&titlep, size, create_title);
52 sgroot->set_move_task(title, TITLE_MOVE, (void*)titlep, size, create_title);
53 } 39 }
54 40
55 41
56 void 42 void
57 create_stage(void *sgroot_, int w, int h, ObjPropertyPtr charactor) 43 create_stage(void *sgroot_, int w, int h, ObjPropertyPtr charactor)