Mercurial > hg > Members > tkaito > task_dandy
diff schedule.cc @ 8:7c60ef3fca5b
test
author | tkaito |
---|---|
date | Wed, 07 Jul 2010 03:11:52 +0900 |
parents | c015109a6041 |
children | dea6d34c8e91 |
line wrap: on
line diff
--- a/schedule.cc Tue Jun 29 04:25:32 2010 +0900 +++ b/schedule.cc Wed Jul 07 03:11:52 2010 +0900 @@ -8,15 +8,26 @@ void schedule(SceneGraphPtr node, void *sgroot_, int w, int h) { + SceneGraphRoot *sgroot = (SceneGraphRoot *)sgroot_; + Pad *pad = sgroot->getController(); + if(back_property.flag == 0){ + if(pad->start.isPush()) { + back_property.flag = 1; + //node->children->remove(); + sgroot->setSceneData(node); + } + } + + if(back_property.flag == 1) { switch (node->frame) { case 1: break; - case FRAME_RATE * 2: - Putenemy(1, w/2, 0, 2, 4, MOVE_00, MOVE_00, node, sgroot_); + case FRAME_RATE * 10: + Putenemy(1, w/2, 0, 2, 4, MOVE_00, MOVE_00, node, sgroot); break; - case FRAME_RATE * 3: - Putenemy(1, w/3, 0, 0, 8, MOVE_00, MOVE_00, node, sgroot_); - Putenemy(1, w/2, 0, 0, 8, MOVE_00, MOVE_00, node, sgroot_); + case FRAME_RATE * 20: + Putenemy(1, w/3, 0, 0, 8, MOVE_00, MOVE_00, node, sgroot); + Putenemy(1, w/2, 0, 0, 8, MOVE_00, MOVE_00, node, sgroot); break; /* case FRAME_RATE * 4: @@ -225,6 +236,7 @@ } */ } + } } ObjProperty enemy[300]; @@ -242,7 +254,7 @@ enemy1->xyz[1] = e->y; back1->addChild(enemy1); - + } void @@ -272,16 +284,16 @@ e->score = charactor[charano].score; //e->dt1 = e->dt2 = 0; //e->tama = tf; - + obj->xyz[0] = x; obj->xyz[1] = y; obj->stack_xyz[0] = sx; obj->stack_xyz[1] = sy; - int size = sizeof(ObjPropertyPtr); + int size = sizeof(ObjPropertyPtr)*16; //obj->set_move_collision(move, coll); sgroot->set_game_task(move, e, size, create_enemy); - - node->addChild(obj); + //node->addChild(obj); + //node->setSceneData(); }