summaryrefslogtreecommitdiff
path: root/src/bossRamboo.cpp
diff options
context:
space:
mode:
authorTreeki <treeki@gmail.com>2013-02-03 00:31:46 +0100
committerTreeki <treeki@gmail.com>2013-02-03 00:31:46 +0100
commit06828e3a02a0ca2eaf56d804bb6845659cfa59e7 (patch)
treebb28c665445fc622958b9614d014ba791cad2d0f /src/bossRamboo.cpp
parent012efaa6343cd2bec2f728d0bec6243263712a45 (diff)
downloadkamek-06828e3a02a0ca2eaf56d804bb6845659cfa59e7.tar.gz
kamek-06828e3a02a0ca2eaf56d804bb6845659cfa59e7.zip
fix a bug in the collision headers, and assorted collision bugs
Diffstat (limited to '')
-rw-r--r--src/bossRamboo.cpp37
1 files changed, 25 insertions, 12 deletions
diff --git a/src/bossRamboo.cpp b/src/bossRamboo.cpp
index bf27d51..f2af942 100644
--- a/src/bossRamboo.cpp
+++ b/src/bossRamboo.cpp
@@ -42,12 +42,12 @@ class daRamboo_c : public daBoss {
void updateModelMatrices();
void playerCollision(ActivePhysics *apThis, ActivePhysics *apOther);
- void collisionCat1_Fireball_E_Explosion(ActivePhysics *apThis, ActivePhysics *apOther);
+ bool collisionCat1_Fireball_E_Explosion(ActivePhysics *apThis, ActivePhysics *apOther);
bool collisionCat2_IceBall_15_YoshiIce(ActivePhysics *apThis, ActivePhysics *apOther);
- void collisionCat9_RollingObject(ActivePhysics *apThis, ActivePhysics *apOther);
- void collisionCat13_Hammer(ActivePhysics *apThis, ActivePhysics *apOther);
- void collisionCat7_GroundPound(ActivePhysics *apThis, ActivePhysics *apOther);
- void collisionCatA_PenguinMario(ActivePhysics *apThis, ActivePhysics *apOther);
+ bool collisionCat9_RollingObject(ActivePhysics *apThis, ActivePhysics *apOther);
+ bool collisionCat13_Hammer(ActivePhysics *apThis, ActivePhysics *apOther);
+ bool collisionCat7_GroundPound(ActivePhysics *apThis, ActivePhysics *apOther);
+ bool collisionCatA_PenguinMario(ActivePhysics *apThis, ActivePhysics *apOther);
USING_STATES(daRamboo_c);
@@ -76,12 +76,15 @@ void daRamboo_c::playerCollision(ActivePhysics *apThis, ActivePhysics *apOther)
EN_LandbarrelPlayerCollision(this, apThis, apOther);
DamagePlayer(this, apThis, apOther);
}
-void daRamboo_c::collisionCat1_Fireball_E_Explosion(ActivePhysics *apThis, ActivePhysics *apOther) {
+bool daRamboo_c::collisionCat1_Fireball_E_Explosion(ActivePhysics *apThis, ActivePhysics *apOther) {
SpawnEffect("Wm_en_obakedoor_sm", 0, &apOther->owner->pos, &(S16Vec){0,0,0}, &(Vec){0.5, 0.5, 0.5});
this->pos.x += 6.0;
+ return true;
+}
+bool daRamboo_c::collisionCat2_IceBall_15_YoshiIce(ActivePhysics *apThis, ActivePhysics *apOther) {
+ return false;
}
-bool daRamboo_c::collisionCat2_IceBall_15_YoshiIce(ActivePhysics *apThis, ActivePhysics *apOther) { return false; }
-void daRamboo_c::collisionCat9_RollingObject(ActivePhysics *apThis, ActivePhysics *apOther) {
+bool daRamboo_c::collisionCat9_RollingObject(ActivePhysics *apThis, ActivePhysics *apOther) {
if (apOther->owner->name == 412) { // Check if it's a glow block
SpawnEffect("Wm_en_obakedoor_sm", 0, &apOther->owner->pos, &(S16Vec){0,0,0}, &(Vec){1.0, 1.0, 1.0});
@@ -90,11 +93,21 @@ void daRamboo_c::collisionCat9_RollingObject(ActivePhysics *apThis, ActivePhysic
doStateChange(&StateID_Flee);
//FIXME changed to dStageActor_c::Delete(u8) from fBase_c::Delete(void)
apOther->owner->Delete(1);
- }
+ return true;
+ }
+ return false;
+}
+bool daRamboo_c::collisionCat13_Hammer(ActivePhysics *apThis, ActivePhysics *apOther) {
+ return true;
+}
+bool daRamboo_c::collisionCat7_GroundPound(ActivePhysics *apThis, ActivePhysics *apOther) {
+ DamagePlayer(this, apThis, apOther);
+ return true;
+}
+bool daRamboo_c::collisionCatA_PenguinMario(ActivePhysics *apThis, ActivePhysics *apOther) {
+ DamagePlayer(this, apThis, apOther);
+ return true;
}
-void daRamboo_c::collisionCat13_Hammer(ActivePhysics *apThis, ActivePhysics *apOther) { }
-void daRamboo_c::collisionCat7_GroundPound(ActivePhysics *apThis, ActivePhysics *apOther) { DamagePlayer(this, apThis, apOther); }
-void daRamboo_c::collisionCatA_PenguinMario(ActivePhysics *apThis, ActivePhysics *apOther) { DamagePlayer(this, apThis, apOther); }