Paper Mario DX
Paper Mario (N64) modding
 
Loading...
Searching...
No Matches
ShrinkActor.inc.c
Go to the documentation of this file.
1#include "common.h"
2#include "effects.h"
3
4API_CALLABLE(N(ShrinkActor)) {
5 Bytecode* args = script->ptrReadPos;
6 f32 var1 = evt_get_float_variable(script, *args++);
7 f32 var2 = evt_get_float_variable(script, *args++);
8 f32 var3 = evt_get_float_variable(script, *args++);
9 f32 var4 = evt_get_float_variable(script, *args++);
10 f32 var5 = evt_get_float_variable(script, *args++);
11 f32 var6 = evt_get_float_variable(script, *args++);
12 s32 var7 = evt_get_variable(script, *args++);
13 Actor* actor = get_actor(script->owner1.actorID);
14 EffectInstance* effect = fx_shape_spell(0, var1, (f32) var2 + 5.0, var3, var4, var5, var6, var7);
15
16 if (actor->debuff == STATUS_KEY_SHRINK) {
17 effect->data.shapeSpell->unk_28 = 0.4f;
18 }
19
20 return ApiStatus_DONE2;
21}
struct ShapeSpellFXData * shapeSpell
Definition effects.h:2482
EffectData data
Definition effects.h:2605
@ STATUS_KEY_SHRINK
Definition enums.h:2206
#define ApiStatus_DONE2
Definition evt.h:118
s32 Bytecode
Definition evt.h:7
s32 evt_get_variable(Evt *script, Bytecode var)
Definition evt.c:1690
Actor * get_actor(s32 actorID)
Definition actor_api.c:155
f32 evt_get_float_variable(Evt *script, Bytecode var)
Definition evt.c:1930