summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorColin Noga <Tempus@chronometry.ca>2012-07-07 23:34:18 -0500
committerColin Noga <Tempus@chronometry.ca>2012-07-07 23:34:18 -0500
commitc6ad18e5f0cf1b627d850fa3101a8c78648ff452 (patch)
treef18ac75de2e867c055b07a6c88ae7f920faa2e3a /src
parent1c3e5a0b1c62829d78960c4d99e4928ccf73625f (diff)
downloadkamek-c6ad18e5f0cf1b627d850fa3101a8c78648ff452.tar.gz
kamek-c6ad18e5f0cf1b627d850fa3101a8c78648ff452.zip
Lots of fixes
Diffstat (limited to '')
-rw-r--r--src/bossCaptainBowser.cpp27
-rw-r--r--src/bossKoopaThrow.cpp15
-rw-r--r--src/bossPlayerClown.cpp1
-rw-r--r--src/poweruphax.S13
-rwxr-xr-xsrc/spritetex.S10
5 files changed, 33 insertions, 33 deletions
diff --git a/src/bossCaptainBowser.cpp b/src/bossCaptainBowser.cpp
index 9157efb..bd6a53f 100644
--- a/src/bossCaptainBowser.cpp
+++ b/src/bossCaptainBowser.cpp
@@ -5,35 +5,10 @@
#include <stage.h>
#include "boss.h"
-extern "C" void *BowserExitDemoState(void *, unsigned int);
-extern "C" void *ForceMarioExitDemoMode(void *, unsigned int);
extern "C" void *ShakeScreen(void *, unsigned int, unsigned int, unsigned int, unsigned int);
extern "C" void *StageScreen;
-void BowserDoomStart(dStageActor_c *Controller) {
- OSReport("Here we go!");
-
- dEn_c *Bowser = (dEn_c*)FindActorByType(EN_BOSS_KOOPA, (Actor*)Controller);
- Bowser->Delete(1);
-
-}
-
-void BowserDoomExecute(dStageActor_c *Controller) {
- dFlagMgr_c::instance->set(0, 0, true, false, false);
- dFlagMgr_c::instance->set(1, 0, true, false, false);
- dFlagMgr_c::instance->set(2, 0, true, false, false);
- dFlagMgr_c::instance->set(3, 0, true, false, false);
- dFlagMgr_c::instance->set(4, 0, true, false, false);
- Controller->Delete(1);
-}
-
-void BowserDoomEnd(dStageActor_c *Controller) {
- OSReport("Bai bai everybody");
- Controller->Delete(1);
-}
-
-
// const char* effects_name_list [] = {
// "Wm_jr_electricline", // cool
// "Wm_jr_fireattack", // cool
@@ -236,7 +211,7 @@ int daCaptainBowser::onCreate() {
this->playerCount = GetActivePlayerCount();
this->maxDamage = (10 * this->playerCount) + 10;
-
+ pos.z = 3300.0;
this->scale = (Vec){0.57, 0.57, 0.57};
this->homingBillCountdown = 270;
this->homingBillSlot = 0;
diff --git a/src/bossKoopaThrow.cpp b/src/bossKoopaThrow.cpp
index a8e1b0a..85c96ca 100644
--- a/src/bossKoopaThrow.cpp
+++ b/src/bossKoopaThrow.cpp
@@ -91,15 +91,22 @@ CREATE_STATE(daKoopaThrow, Straight);
extern "C" void *PlayWrenchSound(dEn_c *);
-
+extern "C" void *dAcPy_c__ChangePowerupWithAnimation(void * Player, int powerup);
+extern "C" int CheckExistingPowerup(void * Player);
void daKoopaThrow::playerCollision(ActivePhysics *apThis, ActivePhysics *apOther) {
if (Type == 5) {
PlaySoundAsync(this, currentInfo->breakSound);
SpawnEffect(currentInfo->deathEffect, 0, &this->pos, &(S16Vec){0,0,0}, &(Vec){3.0, 3.0, 3.0});
- dStageActor_c *spawned = CreateActor(EN_ITEM, 0x20000063, this->pos, 0, 0);
- spawned->pos.x = this->pos.x;
- spawned->pos.y = this->pos.y;
+ // dStageActor_c *spawned = CreateActor(EN_ITEM, 0x20000063, this->pos, 0, 0);
+ // spawned->pos.x = this->pos.x;
+ // spawned->pos.y = this->pos.y;
+
+ int p = CheckExistingPowerup(apOther->owner);
+ if (p == 0 || p == 3) { // Powerups - 0 = small; 1 = big; 2 = fire; 3 = mini; 4 = prop; 5 = peng; 6 = ice; 7 = hammer
+ dAcPy_c__ChangePowerupWithAnimation(apOther->owner, 1);
+ }
+
this->Delete(1);
return;
diff --git a/src/bossPlayerClown.cpp b/src/bossPlayerClown.cpp
index 6a7e2fc..6fccee6 100644
--- a/src/bossPlayerClown.cpp
+++ b/src/bossPlayerClown.cpp
@@ -30,7 +30,6 @@ const char* PCCarcNameList [] = {
-
int CConDraw(dEn_c *clown) {
// setup cannon model
clown->matrix.translation(clown->pos.x, clown->pos.y + 8.0, clown->pos.z-100.0);
diff --git a/src/poweruphax.S b/src/poweruphax.S
index 7f1fcdf..1d849c1 100644
--- a/src/poweruphax.S
+++ b/src/poweruphax.S
@@ -634,6 +634,19 @@ isHammerForToad:
+
+
+
+.global CheckExistingPowerup
+CheckExistingPowerup:
+
+ lwz r3, 0x14E0(r3)
+ blr
+
+
+
+
+
.data
PowerupSounds:
diff --git a/src/spritetex.S b/src/spritetex.S
index 51e4cb7..563d81a 100755
--- a/src/spritetex.S
+++ b/src/spritetex.S
@@ -417,9 +417,15 @@ TEX_Midway:
.global TEX_ColorBlock
TEX_ColorBlock:
- lwz r5, 4(r30)
+
+ cmpwi r0, 0xB0
+ bnelr
+
+ subi r9, r29, 0x4E0
+
+ lwz r5, 4(r9)
srwi r5, r5, 28
- andi. r5, r5, 0xFF
+ andi. r5, r5, 0xF
b GetTexFilenameForR5