diff options
author | Treeki <treeki@gmail.com> | 2013-06-05 16:20:37 +0200 |
---|---|---|
committer | Treeki <treeki@gmail.com> | 2013-06-05 16:20:37 +0200 |
commit | 53b4cabb097291545b95115a4e430105e9295613 (patch) | |
tree | 95effc118f8f90a2c2efb10c218937d6985f281b /src/newer.cpp | |
parent | e33d76475bc5326d608e74421c8e3a40ae0f4e2e (diff) | |
download | kamek-53b4cabb097291545b95115a4e430105e9295613.tar.gz kamek-53b4cabb097291545b95115a4e430105e9295613.zip |
commented Yoshi bug debugging stuff, plus the fix
Diffstat (limited to 'src/newer.cpp')
-rw-r--r-- | src/newer.cpp | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/src/newer.cpp b/src/newer.cpp index edbbf3b..f1da7fc 100644 --- a/src/newer.cpp +++ b/src/newer.cpp @@ -10,6 +10,42 @@ int lastLevelIDs[] = { }; +/* +extern "C" void FuckUpYoshi(void *_this) { + dEn_c *koopa = (dEn_c*)fBase_c::search(EN_NOKONOKO, 0); + static int thing = 0; + thing++; + nw4r::db::Exception_Printf_("Fruit eaten: %d\n", thing); + if (thing == 5) { + nw4r::db::Exception_Printf_("5th fruit eaten\n"); + nw4r::db::Exception_Printf_("Let's try fucking up Yoshi!\n"); + daPlBase_c *yoshi = (daPlBase_c*)fBase_c::search(YOSHI, 0); + nw4r::db::Exception_Printf_("Fruit: %p ; Koopa: %p ; Yoshi: %p\n", _this, koopa, yoshi); + koopa->_vf220(yoshi); + nw4r::db::Exception_Printf_("Yoshi fucked up. Yay.\n"); + thing = 0; + } +} + +extern "C" void FuckUpYoshi2() { + dEn_c *koopa = (dEn_c*)fBase_c::search(EN_NOKONOKO, 0); + nw4r::db::Exception_Printf_("Let's try fucking up Yoshi!\n"); + daPlBase_c *yoshi = (daPlBase_c*)fBase_c::search(YOSHI, 0); + koopa->_vf220(yoshi); + nw4r::db::Exception_Printf_("Yoshi fucked up. Yay.\n"); +} + +extern "C" void StartAnimOrig(dPlayerModelBase_c *_this, int id, float updateRate, float unk, float frame); +extern "C" void YoshiStartAnimWrapper(dPlayerModelBase_c *_this, int id, float updateRate, float unk, float frame) { + nw4r::db::Exception_Printf_("[%d] anim %d (%f, %f, %f)\n", GlobalTickCount, id, updateRate, unk, frame); + StartAnimOrig(_this, id, updateRate, unk, frame); +} +extern "C" void YoshiStateOrig(daPlBase_c *_this, dStateBase_c *state, void *param); +extern "C" void YoshiStateWrapper(daPlBase_c *_this, dStateBase_c *state, void *param) { + nw4r::db::Exception_Printf_("[%d] %s,%p\n", GlobalTickCount, state->getName(), param); + YoshiStateOrig(_this, state, param); +} +*/ void WriteAsciiToTextBox(nw4r::lyt::TextBox *tb, const char *source) { |