diff options
author | Treeki <treeki@gmail.com> | 2011-07-11 04:52:26 +0200 |
---|---|---|
committer | Treeki <treeki@gmail.com> | 2011-07-11 04:52:26 +0200 |
commit | 66a79a749c5decd612502923dadca10208b536ff (patch) | |
tree | 57b7e794a59f46a59691a363e3eed909accbd868 | |
parent | 5cf5d280cafbf1c2003baf114fcb777e16a91da4 (diff) | |
download | kamek-66a79a749c5decd612502923dadca10208b536ff.tar.gz kamek-66a79a749c5decd612502923dadca10208b536ff.zip |
demo block for the youtube video
-rw-r--r-- | src/testblock.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/testblock.cpp b/src/testblock.cpp index 73f3adb..d63f245 100644 --- a/src/testblock.cpp +++ b/src/testblock.cpp @@ -9,6 +9,7 @@ public: TileRenderer tile; Physics::Info physicsInfo; + Actors actorToCreate; int onCreate(); int onDelete(); @@ -60,6 +61,9 @@ int daEnTestBlock_c::onCreate() { tile.y = -(16 + pos.y); tile.tileNumber = 0x30; + Actors ToCreate[] = {EN_KURIBO, EN_NOKONOKO, EN_STAR_COIN, AC_YOSHI_EGG, AC_LIGHT_BLOCK}; + actorToCreate = ToCreate[settings]; + //OSReport("Sanity Checks... _414=%x\n", offsetof(dEn_c,_414)); //OSReport("acState=%x\n", offsetof(dActorMultiState_c,acState)); //OSReport("_530=%x\n", offsetof(dEn_c,_530)); @@ -112,6 +116,10 @@ daEnTestBlock_c *daEnTestBlock_c::build() { void daEnTestBlock_c::blockWasHit(bool isDown) { OSReport("I'm a block, and I was hit.\n"); + Vec goombaPos = pos; + goombaPos.y += 40; + dStageActor_c::create(actorToCreate, 0, &goombaPos, 0, currentLayerID); + pos.y = initialY; //This code makes the block unhittable |