Pages: 1
Shadey |
Posted on 01-07-18, 10:00 pm
|
Flurry
Karma: 724 Posts: 232/258 Since: 10-14-11 |
Is there a way to check if Mario's DeathState is active? I'd like to execute something when Mario dies.
I know you can set his DeathState to this to kill him, and have the standard death animation. mario->DeathState = 0x21197FC; Kind of looking for something like this. if(DeathState == TRUE) { //Do something } |
RicBent |
Posted on 01-07-18, 10:06 pm
|
Mariomaster
Karma: 8528 Posts: 1080/1681 Since: 06-09-12 |
Shadey |
Posted on 01-07-18, 10:35 pm (rev. 1 by Shadey on 01-07-18, 10:56 pm)
|
Flurry
Karma: 724 Posts: 233/258 Since: 10-14-11 |
I have with other parts of his struct.
I've had success doing it with the power up state. void hook_0211F83C_ov_0A() { MarioActor* mario = (MarioActor*)getPtrToPlayerActor(); u8 PowerState = mario->marioPowerupState; } I can use the PowerState to check if certain powerups are present but I can't seem to with the DeathState. For example, if I set mario->DeathState = 0x21197FC and then check to see if it's equal to 0x21197FC, I'm not getting any results. |
newluigidev |
Posted on 01-08-18, 09:15 pm (rev. 1 by newluigidev on 01-08-18, 09:16 pm)
|
Nipper Plant
Karma: 2406 Posts: 323/417 Since: 08-17-15 |
Yes, because the DeathState gets assigned a completely random constant value during game-play, but never seems to be assigned any of the death values. (I've checked before)
|
Pages: 1