diff options
author | PikalaxALT <pikalax1@gmail.com> | 2017-09-21 17:42:50 -0400 |
---|---|---|
committer | PikalaxALT <pikalax1@gmail.com> | 2017-09-21 17:42:50 -0400 |
commit | aecddc277130652a90e00ad0cc314b7ef9765bbb (patch) | |
tree | a336b6a6815c0836f33116169b84b7bb87a0d886 /src | |
parent | 039934e05e0eff4fda75d51c03b877497fd988da (diff) |
gFieldEffectSpawnParams -> gFieldEffectArguments
Diffstat (limited to 'src')
-rw-r--r-- | src/battle_transition.c | 16 | ||||
-rw-r--r-- | src/braille_puzzles.c | 2 | ||||
-rw-r--r-- | src/field_effect.c | 84 | ||||
-rw-r--r-- | src/field_effect_helpers.c | 242 | ||||
-rw-r--r-- | src/field_ground_effect.c | 128 | ||||
-rw-r--r-- | src/field_map_obj.c | 26 | ||||
-rw-r--r-- | src/field_map_obj_helpers.c | 10 | ||||
-rw-r--r-- | src/field_player_avatar.c | 14 | ||||
-rw-r--r-- | src/fldeff_cut.c | 4 | ||||
-rw-r--r-- | src/fldeff_flash.c | 2 | ||||
-rw-r--r-- | src/fldeff_strength.c | 6 | ||||
-rw-r--r-- | src/fldeff_sweetscent.c | 2 | ||||
-rw-r--r-- | src/fldeff_teleport.c | 2 | ||||
-rw-r--r-- | src/pokemon_menu.c | 14 | ||||
-rw-r--r-- | src/rom6.c | 24 | ||||
-rw-r--r-- | src/scrcmd.c | 2 | ||||
-rw-r--r-- | src/trainer_see.c | 16 |
17 files changed, 297 insertions, 297 deletions
diff --git a/src/battle_transition.c b/src/battle_transition.c index fd6eab491..ffa48d8dd 100644 --- a/src/battle_transition.c +++ b/src/battle_transition.c @@ -994,10 +994,10 @@ static bool8 Phase2_Transition_PokeballsTrail_Func2(struct Task* task) rand = Random() & 1; for (i = 0; i <= 4; i++, rand ^= 1) { - gFieldEffectSpawnParams[0] = arr0[rand]; // x - gFieldEffectSpawnParams[1] = (i * 32) + 16; // y - gFieldEffectSpawnParams[2] = rand; - gFieldEffectSpawnParams[3] = arr1[i]; + gFieldEffectArguments[0] = arr0[rand]; // x + gFieldEffectArguments[1] = (i * 32) + 16; // y + gFieldEffectArguments[2] = rand; + gFieldEffectArguments[3] = arr1[i]; FieldEffectStart(FLDEFF_POKEBALL); } @@ -1017,14 +1017,14 @@ static bool8 Phase2_Transition_PokeballsTrail_Func3(struct Task* task) bool8 FldEff_Pokeball(void) { - u8 spriteID = CreateSpriteAtEnd(&sSpriteTemplate_83FD98C, gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0); + u8 spriteID = CreateSpriteAtEnd(&sSpriteTemplate_83FD98C, gFieldEffectArguments[0], gFieldEffectArguments[1], 0); gSprites[spriteID].oam.priority = 0; gSprites[spriteID].oam.affineMode = 1; - gSprites[spriteID].data0 = gFieldEffectSpawnParams[2]; - gSprites[spriteID].data1 = gFieldEffectSpawnParams[3]; + gSprites[spriteID].data0 = gFieldEffectArguments[2]; + gSprites[spriteID].data1 = gFieldEffectArguments[3]; gSprites[spriteID].data2 = -1; InitSpriteAffineAnim(&gSprites[spriteID]); - StartSpriteAffineAnim(&gSprites[spriteID], gFieldEffectSpawnParams[2]); + StartSpriteAffineAnim(&gSprites[spriteID], gFieldEffectArguments[2]); return FALSE; } diff --git a/src/braille_puzzles.c b/src/braille_puzzles.c index f6bd9e056..63c601acf 100644 --- a/src/braille_puzzles.c +++ b/src/braille_puzzles.c @@ -105,7 +105,7 @@ bool8 ShouldDoBrailleFlyEffect(void) void DoBrailleFlyEffect(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; FieldEffectStart(0x3C); } diff --git a/src/field_effect.c b/src/field_effect.c index 164c74657..2f8200708 100644 --- a/src/field_effect.c +++ b/src/field_effect.c @@ -28,7 +28,7 @@ #define subsprite_table(ptr) {.subsprites = ptr, .subspriteCount = (sizeof ptr) / (sizeof(struct Subsprite))} -EWRAM_DATA u32 gFieldEffectSpawnParams[8] = {0}; +EWRAM_DATA u32 gFieldEffectArguments[8] = {0}; const u32 gSpriteImage_839DC14[] = INCBIN_U32("graphics/birch_speech/birch.4bpp"); const u16 gBirchPalette[16] = INCBIN_U16("graphics/birch_speech/birch.gbapal"); @@ -1203,10 +1203,10 @@ void task00_8084310(u8 taskId) { return; } - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; - if ((int)gFieldEffectSpawnParams[0] > 5) + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; + if ((int)gFieldEffectArguments[0] > 5) { - gFieldEffectSpawnParams[0] = 0; + gFieldEffectArguments[0] = 0; } FieldEffectStart(FLDEFF_USE_FLY); task->data[0]++; @@ -1665,7 +1665,7 @@ bool8 FldEff_UseWaterfall(void) { u8 taskId; taskId = CreateTask(sub_8086F64, 0xff); - gTasks[taskId].data[1] = gFieldEffectSpawnParams[0]; + gTasks[taskId].data[1] = gFieldEffectArguments[0]; sub_8086F64(taskId); return FALSE; } @@ -1689,7 +1689,7 @@ bool8 waterfall_1_do_anim_probably(struct Task *task, struct MapObject *mapObjec if (!FieldObjectIsSpecialAnimOrDirectionSequenceAnimActive(mapObject)) { FieldObjectClearAnimIfSpecialAnimFinished(mapObject); - gFieldEffectSpawnParams[0] = task->data[1]; + gFieldEffectArguments[0] = task->data[1]; FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON_INIT); task->data[0]++; } @@ -1738,8 +1738,8 @@ bool8 FldEff_UseDive(void) { u8 taskId; taskId = CreateTask(Task_Dive, 0xff); - gTasks[taskId].data[15] = gFieldEffectSpawnParams[0]; - gTasks[taskId].data[14] = gFieldEffectSpawnParams[1]; + gTasks[taskId].data[15] = gFieldEffectArguments[0]; + gTasks[taskId].data[14] = gFieldEffectArguments[1]; Task_Dive(taskId); return FALSE; } @@ -1759,7 +1759,7 @@ bool8 sub_8087124(struct Task *task) bool8 dive_2_unknown(struct Task *task) { ScriptContext2_Enable(); - gFieldEffectSpawnParams[0] = task->data[15]; + gFieldEffectArguments[0] = task->data[15]; FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON_INIT); task->data[0]++; return FALSE; @@ -1820,10 +1820,10 @@ bool8 sub_8087298(struct Task *task, struct MapObject *mapObject, struct Sprite { sprite->pos2.y = 0; task->data[3] = 1; - gFieldEffectSpawnParams[0] = mapObject->coords2.x; - gFieldEffectSpawnParams[1] = mapObject->coords2.y; - gFieldEffectSpawnParams[2] = sprite->subpriority - 1; - gFieldEffectSpawnParams[3] = sprite->oam.priority; + gFieldEffectArguments[0] = mapObject->coords2.x; + gFieldEffectArguments[1] = mapObject->coords2.y; + gFieldEffectArguments[2] = sprite->subpriority - 1; + gFieldEffectArguments[3] = sprite->oam.priority; FieldEffectStart(FLDEFF_LAVARIDGE_GYM_WARP); PlaySE(SE_W153); task->data[0]++; @@ -1924,10 +1924,10 @@ bool8 sub_80874FC(struct Task *task, struct MapObject *mapObject, struct Sprite { if (sub_807D770()) { - gFieldEffectSpawnParams[0] = mapObject->coords2.x; - gFieldEffectSpawnParams[1] = mapObject->coords2.y; - gFieldEffectSpawnParams[2] = sprite->subpriority - 1; - gFieldEffectSpawnParams[3] = sprite->oam.priority; + gFieldEffectArguments[0] = mapObject->coords2.x; + gFieldEffectArguments[1] = mapObject->coords2.y; + gFieldEffectArguments[2] = sprite->subpriority - 1; + gFieldEffectArguments[3] = sprite->oam.priority; task->data[1] = FieldEffectStart(FLDEFF_POP_OUT_OF_ASH); task->data[0]++; } @@ -1966,9 +1966,9 @@ extern const struct SpriteTemplate *const gFieldEffectObjectTemplatePointers[36] u8 FldEff_LavaridgeGymWarp(void) { u8 spriteId; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[33], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); - gSprites[spriteId].oam.priority = gFieldEffectSpawnParams[3]; + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[33], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); + gSprites[spriteId].oam.priority = gFieldEffectArguments[3]; gSprites[spriteId].coordOffsetEnabled = 1; return spriteId; } @@ -2009,10 +2009,10 @@ bool8 sub_80876F8(struct Task *task, struct MapObject *mapObject, struct Sprite { if (task->data[1] > 3) { - gFieldEffectSpawnParams[0] = mapObject->coords2.x; - gFieldEffectSpawnParams[1] = mapObject->coords2.y; - gFieldEffectSpawnParams[2] = sprite->subpriority - 1; - gFieldEffectSpawnParams[3] = sprite->oam.priority; + gFieldEffectArguments[0] = mapObject->coords2.x; + gFieldEffectArguments[1] = mapObject->coords2.y; + gFieldEffectArguments[2] = sprite->subpriority - 1; + gFieldEffectArguments[3] = sprite->oam.priority; task->data[1] = FieldEffectStart(FLDEFF_POP_OUT_OF_ASH); task->data[0]++; } else @@ -2064,9 +2064,9 @@ bool8 sub_80877D4(struct Task *task, struct MapObject *mapObject, struct Sprite u8 FldEff_PopOutOfAsh(void) { u8 spriteId; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[32], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); - gSprites[spriteId].oam.priority = gFieldEffectSpawnParams[3]; + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[32], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); + gSprites[spriteId].oam.priority = gFieldEffectArguments[3]; gSprites[spriteId].coordOffsetEnabled = 1; return spriteId; } @@ -2392,19 +2392,19 @@ bool8 FldEff_FieldMoveShowMon(void) { taskId = CreateTask(sub_808847C, 0xff); } - gTasks[taskId].data[15] = sub_8088830(gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + gTasks[taskId].data[15] = sub_8088830(gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); return FALSE; } bool8 FldEff_FieldMoveShowMonInit(void) { struct Pokemon *pokemon; - u32 flag = gFieldEffectSpawnParams[0] & 0x80000000; - pokemon = &gPlayerParty[(u8)gFieldEffectSpawnParams[0]]; - gFieldEffectSpawnParams[0] = GetMonData(pokemon, MON_DATA_SPECIES); - gFieldEffectSpawnParams[1] = GetMonData(pokemon, MON_DATA_OT_ID); - gFieldEffectSpawnParams[2] = GetMonData(pokemon, MON_DATA_PERSONALITY); - gFieldEffectSpawnParams[0] |= flag; + u32 flag = gFieldEffectArguments[0] & 0x80000000; + pokemon = &gPlayerParty[(u8)gFieldEffectArguments[0]]; + gFieldEffectArguments[0] = GetMonData(pokemon, MON_DATA_SPECIES); + gFieldEffectArguments[1] = GetMonData(pokemon, MON_DATA_OT_ID); + gFieldEffectArguments[2] = GetMonData(pokemon, MON_DATA_PERSONALITY); + gFieldEffectArguments[0] |= flag; FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON); FieldEffectActiveListRemove(FLDEFF_FIELD_MOVE_SHOW_MON_INIT); return FALSE; @@ -2879,7 +2879,7 @@ u8 FldEff_UseSurf(void) { u8 taskId; taskId = CreateTask(sub_8088954, 0xff); - gTasks[taskId].data[15] = gFieldEffectSpawnParams[0]; + gTasks[taskId].data[15] = gFieldEffectArguments[0]; sav1_reset_battle_music_maybe(); sub_8053FB0(0x016d); return FALSE; @@ -2919,7 +2919,7 @@ void sub_8088A30(struct Task *task) mapObject = &gMapObjects[gPlayerAvatar.mapObjectId]; if (FieldObjectCheckIfSpecialAnimFinishedOrInactive(mapObject)) { - gFieldEffectSpawnParams[0] = task->data[15] | 0x80000000; + gFieldEffectArguments[0] = task->data[15] | 0x80000000; FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON_INIT); task->data[0]++; } @@ -2934,9 +2934,9 @@ void sub_8088A78(struct Task *task) sub_805B980(mapObject, GetPlayerAvatarGraphicsIdByStateId(3)); FieldObjectClearAnimIfSpecialAnimFinished(mapObject); FieldObjectSetSpecialAnim(mapObject, sub_80608D0(mapObject->placeholder18)); - gFieldEffectSpawnParams[0] = task->data[1]; - gFieldEffectSpawnParams[1] = task->data[2]; - gFieldEffectSpawnParams[2] = gPlayerAvatar.mapObjectId; + gFieldEffectArguments[0] = task->data[1]; + gFieldEffectArguments[1] = task->data[2]; + gFieldEffectArguments[2] = gPlayerAvatar.mapObjectId; mapObject->mapobj_unk_1A = FieldEffectStart(FLDEFF_SURF_BLOB); task->data[0]++; } @@ -2970,7 +2970,7 @@ u8 FldEff_NPCFlyOut(void) sprite->oam.paletteNum = 0; sprite->oam.priority = 1; sprite->callback = sub_8088BC4; - sprite->data1 = gFieldEffectSpawnParams[0]; + sprite->data1 = gFieldEffectArguments[0]; PlaySE(SE_W019); return spriteId; } @@ -3009,7 +3009,7 @@ u8 FldEff_UseFly(void) { u8 taskId; taskId = CreateTask(sub_8088C70, 0xfe); - gTasks[taskId].data[1] = gFieldEffectSpawnParams[0]; + gTasks[taskId].data[1] = gFieldEffectArguments[0]; return 0; } @@ -3040,7 +3040,7 @@ void sub_8088CF8(struct Task *task) if (FieldObjectClearAnimIfSpecialAnimFinished(mapObject)) { task->data[0]++; - gFieldEffectSpawnParams[0] = task->data[1]; + gFieldEffectArguments[0] = task->data[1]; FieldEffectStart(FLDEFF_FIELD_MOVE_SHOW_MON_INIT); } } diff --git a/src/field_effect_helpers.c b/src/field_effect_helpers.c index 1152c39bc..2ad8bdce3 100644 --- a/src/field_effect_helpers.c +++ b/src/field_effect_helpers.c @@ -243,15 +243,15 @@ u32 FldEff_Shadow(void) const struct MapObjectGraphicsInfo *graphicsInfo; u8 spriteId; - mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); graphicsInfo = GetFieldObjectGraphicsInfo(gMapObjects[mapObjectId].graphicsId); spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[gUnknown_08401E32[graphicsInfo->shadowSize]], 0, 0, 0x94); if (spriteId != MAX_SPRITES) { gSprites[spriteId].coordOffsetEnabled = TRUE; - gSprites[spriteId].data0 = gFieldEffectSpawnParams[0]; - gSprites[spriteId].data1 = gFieldEffectSpawnParams[1]; - gSprites[spriteId].data2 = gFieldEffectSpawnParams[2]; + gSprites[spriteId].data0 = gFieldEffectArguments[0]; + gSprites[spriteId].data1 = gFieldEffectArguments[1]; + gSprites[spriteId].data2 = gFieldEffectArguments[2]; gSprites[spriteId].data3 = (graphicsInfo->height >> 1) - gUnknown_08401E36[graphicsInfo->shadowSize]; } return 0; @@ -288,22 +288,22 @@ u32 FldEff_TallGrass(void) u8 spriteId; struct Sprite *sprite; - x = gFieldEffectSpawnParams[0]; - y = gFieldEffectSpawnParams[1]; + x = gFieldEffectArguments[0]; + y = gFieldEffectArguments[1]; sub_8060470(&x, &y, 8, 8); spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[4], x, y, 0); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; - sprite->data0 = gFieldEffectSpawnParams[2]; - sprite->data1 = gFieldEffectSpawnParams[0]; - sprite->data2 = gFieldEffectSpawnParams[1]; - sprite->data3 = gFieldEffectSpawnParams[4]; - sprite->data4 = gFieldEffectSpawnParams[5]; - sprite->data5 = gFieldEffectSpawnParams[6]; - if (gFieldEffectSpawnParams[7]) + sprite->oam.priority = gFieldEffectArguments[3]; + sprite->data0 = gFieldEffectArguments[2]; + sprite->data1 = gFieldEffectArguments[0]; + sprite->data2 = gFieldEffectArguments[1]; + sprite->data3 = gFieldEffectArguments[4]; + sprite->data4 = gFieldEffectArguments[5]; + sprite->data5 = gFieldEffectArguments[6]; + if (gFieldEffectArguments[7]) { SeekSpriteAnim(sprite, 4); } @@ -358,14 +358,14 @@ u32 FldEff_JumpTallGrass(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 12); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[10], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 12); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[10], gFieldEffectArguments[0], gFieldEffectArguments[1], 0); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; - sprite->data0 = gFieldEffectSpawnParams[2]; + sprite->oam.priority = gFieldEffectArguments[3]; + sprite->data0 = gFieldEffectArguments[2]; sprite->data1 = 12; } return 0; @@ -397,22 +397,22 @@ u32 FldEff_LongGrass(void) u8 spriteId; struct Sprite *sprite; - x = gFieldEffectSpawnParams[0]; - y = gFieldEffectSpawnParams[1]; + x = gFieldEffectArguments[0]; + y = gFieldEffectArguments[1]; sub_8060470(&x, &y, 8, 8); spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[15], x, y, 0); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = ZCoordToPriority(gFieldEffectSpawnParams[2]); - sprite->data0 = gFieldEffectSpawnParams[2]; - sprite->data1 = gFieldEffectSpawnParams[0]; - sprite->data2 = gFieldEffectSpawnParams[1]; - sprite->data3 = gFieldEffectSpawnParams[4]; - sprite->data4 = gFieldEffectSpawnParams[5]; - sprite->data5 = gFieldEffectSpawnParams[6]; - if (gFieldEffectSpawnParams[7]) + sprite->oam.priority = ZCoordToPriority(gFieldEffectArguments[2]); + sprite->data0 = gFieldEffectArguments[2]; + sprite->data1 = gFieldEffectArguments[0]; + sprite->data2 = gFieldEffectArguments[1]; + sprite->data3 = gFieldEffectArguments[4]; + sprite->data4 = gFieldEffectArguments[5]; + sprite->data5 = gFieldEffectArguments[6]; + if (gFieldEffectArguments[7]) { SeekSpriteAnim(sprite, 6); } @@ -462,14 +462,14 @@ u32 FldEff_JumpLongGrass(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[16], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[16], gFieldEffectArguments[0], gFieldEffectArguments[1], 0); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; - sprite->data0 = gFieldEffectSpawnParams[2]; + sprite->oam.priority = gFieldEffectArguments[3]; + sprite->data0 = gFieldEffectArguments[2]; sprite->data1 = 18; } return 0; @@ -482,7 +482,7 @@ u32 FldEff_ShortGrass(void) u8 spriteId; struct Sprite *sprite; - mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); mapObject = &gMapObjects[mapObjectId]; spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[30], 0, 0, 0); if (spriteId != MAX_SPRITES) @@ -490,9 +490,9 @@ u32 FldEff_ShortGrass(void) sprite = &(gSprites[spriteId]); sprite->coordOffsetEnabled = TRUE; sprite->oam.priority = gSprites[mapObject->spriteId].oam.priority; - sprite->data0 = gFieldEffectSpawnParams[0]; - sprite->data1 = gFieldEffectSpawnParams[1]; - sprite->data2 = gFieldEffectSpawnParams[2]; + sprite->data0 = gFieldEffectArguments[0]; + sprite->data1 = gFieldEffectArguments[1]; + sprite->data2 = gFieldEffectArguments[2]; sprite->data3 = gSprites[mapObject->spriteId].pos1.x; sprite->data4 = gSprites[mapObject->spriteId].pos1.y; } @@ -540,15 +540,15 @@ u32 FldEff_SandFootprints(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[11], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[11], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->data7 = FLDEFF_SAND_FOOTPRINTS; - StartSpriteAnim(sprite, gFieldEffectSpawnParams[4]); + StartSpriteAnim(sprite, gFieldEffectArguments[4]); } return 0; } @@ -558,15 +558,15 @@ u32 FldEff_DeepSandFootprints(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[23], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[23], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->data7 = FLDEFF_DEEP_SAND_FOOTPRINTS; - StartSpriteAnim(sprite, gFieldEffectSpawnParams[4]); + StartSpriteAnim(sprite, gFieldEffectArguments[4]); } return spriteId; } @@ -576,15 +576,15 @@ u32 FldEff_BikeTireTracks(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[27], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[27], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->data7 = FLDEFF_BIKE_TIRE_TRACKS; - StartSpriteAnim(sprite, gFieldEffectSpawnParams[4]); + StartSpriteAnim(sprite, gFieldEffectArguments[4]); } return spriteId; } @@ -623,7 +623,7 @@ u32 FldEff_Splash(void) const struct MapObjectGraphicsInfo *graphicsInfo; struct Sprite *linkedSprite; - mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); mapObject = &gMapObjects[mapObjectId]; spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[13], 0, 0, 0); if (spriteId != MAX_SPRITES) @@ -633,9 +633,9 @@ u32 FldEff_Splash(void) sprite->coordOffsetEnabled = TRUE; linkedSprite = &gSprites[mapObject->spriteId]; sprite->oam.priority = linkedSprite->oam.priority; - sprite->data0 = gFieldEffectSpawnParams[0]; - sprite->data1 = gFieldEffectSpawnParams[1]; - sprite->data2 = gFieldEffectSpawnParams[2]; + sprite->data0 = gFieldEffectArguments[0]; + sprite->data1 = gFieldEffectArguments[1]; + sprite->data2 = gFieldEffectArguments[2]; sprite->pos2.y = (graphicsInfo->height >> 1) - 4; PlaySE(SE_MIZU); } @@ -663,14 +663,14 @@ u32 FldEff_JumpSmallSplash(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 12); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[14], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 12); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[14], gFieldEffectArguments[0], gFieldEffectArguments[1], 0); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; - sprite->data0 = gFieldEffectSpawnParams[2]; + sprite->oam.priority = gFieldEffectArguments[3]; + sprite->data0 = gFieldEffectArguments[2]; sprite->data1 = FLDEFF_JUMP_SMALL_SPLASH; } return 0; @@ -681,14 +681,14 @@ u32 FldEff_JumpBigSplash(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[12], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[12], gFieldEffectArguments[0], gFieldEffectArguments[1], 0); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; - sprite->data0 = gFieldEffectSpawnParams[2]; + sprite->oam.priority = gFieldEffectArguments[3]; + sprite->data0 = gFieldEffectArguments[2]; sprite->data1 = FLDEFF_JUMP_BIG_SPLASH; } return 0; @@ -702,7 +702,7 @@ u32 FldEff_FeetInFlowingWater(void) struct Sprite *sprite; const struct MapObjectGraphicsInfo *graphicsInfo; - mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); mapObject = &gMapObjects[mapObjectId]; spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[13], 0, 0, 0); if (spriteId != MAX_SPRITES) @@ -712,9 +712,9 @@ u32 FldEff_FeetInFlowingWater(void) sprite->callback = sub_81278D8; sprite->coordOffsetEnabled = TRUE; sprite->oam.priority = gSprites[mapObject->spriteId].oam.priority; - sprite->data0 = gFieldEffectSpawnParams[0]; - sprite->data1 = gFieldEffectSpawnParams[1]; - sprite->data2 = gFieldEffectSpawnParams[2]; + sprite->data0 = gFieldEffectArguments[0]; + sprite->data1 = gFieldEffectArguments[1]; + sprite->data2 = gFieldEffectArguments[2]; sprite->data3 = -1; sprite->data4 = -1; sprite->pos2.y = (graphicsInfo->height >> 1) - 4; @@ -758,12 +758,12 @@ u32 FldEff_Ripple(void) u8 spriteId; struct Sprite *sprite; - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[5], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[5], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->data0 = FLDEFF_RIPPLE; } return 0; @@ -776,7 +776,7 @@ u32 FldEff_HotSpringsWater(void) u8 spriteId; struct Sprite *sprite; - mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); mapObject = &gMapObjects[mapObjectId]; spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[31], 0, 0, 0); if (spriteId != MAX_SPRITES) @@ -784,9 +784,9 @@ u32 FldEff_HotSpringsWater(void) sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; sprite->oam.priority = gSprites[mapObject->spriteId].oam.priority; - sprite->data0 = gFieldEffectSpawnParams[0]; - sprite->data1 = gFieldEffectSpawnParams[1]; - sprite->data2 = gFieldEffectSpawnParams[2]; + sprite->data0 = gFieldEffectArguments[0]; + sprite->data1 = gFieldEffectArguments[1]; + sprite->data2 = gFieldEffectArguments[2]; sprite->data3 = gSprites[mapObject->spriteId].pos1.x; sprite->data4 = gSprites[mapObject->spriteId].pos1.y; } @@ -819,13 +819,13 @@ u32 FldEff_Unknown19(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[17], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[17], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->data0 = FLDEFF_UNKNOWN_19; } return 0; @@ -836,13 +836,13 @@ u32 FldEff_Unknown20(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[18], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[18], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->data0 = FLDEFF_UNKNOWN_20; } return 0; @@ -853,13 +853,13 @@ u32 FldEff_Unknown21(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[19], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[19], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->data0 = FLDEFF_UNKNOWN_21; } return 0; @@ -870,13 +870,13 @@ u32 FldEff_Unknown22(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[20], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[20], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->data0 = FLDEFF_UNKNOWN_22; } return 0; @@ -884,12 +884,12 @@ u32 FldEff_Unknown22(void) void ash(s16 x, s16 y, u16 c, s16 d) { - gFieldEffectSpawnParams[0] = x; - gFieldEffectSpawnParams[1] = y; - gFieldEffectSpawnParams[2] = 0x52; - gFieldEffectSpawnParams[3] = 1; - gFieldEffectSpawnParams[4] = c; - gFieldEffectSpawnParams[5] = d; + gFieldEffectArguments[0] = x; + gFieldEffectArguments[1] = y; + gFieldEffectArguments[2] = 0x52; + gFieldEffectArguments[3] = 1; + gFieldEffectArguments[4] = c; + gFieldEffectArguments[5] = d; FieldEffectStart(FLDEFF_ASH); } @@ -900,19 +900,19 @@ u32 FldEff_Ash(void) u8 spriteId; struct Sprite *sprite; - x = gFieldEffectSpawnParams[0]; - y = gFieldEffectSpawnParams[1]; + x = gFieldEffectArguments[0]; + y = gFieldEffectArguments[1]; sub_8060470(&x, &y, 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[6], x, y, gFieldEffectSpawnParams[2]); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[6], x, y, gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; - sprite->data1 = gFieldEffectSpawnParams[0]; - sprite->data2 = gFieldEffectSpawnParams[1]; - sprite->data3 = gFieldEffectSpawnParams[4]; - sprite->data4 = gFieldEffectSpawnParams[5]; + sprite->oam.priority = gFieldEffectArguments[3]; + sprite->data1 = gFieldEffectArguments[0]; + sprite->data2 = gFieldEffectArguments[1]; + sprite->data3 = gFieldEffectArguments[4]; + sprite->data4 = gFieldEffectArguments[5]; } return 0; } @@ -956,14 +956,14 @@ u32 FldEff_SurfBlob(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[7], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0x96); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[7], gFieldEffectArguments[0], gFieldEffectArguments[1], 0x96); if (spriteId !=MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; sprite->oam.paletteNum = 0; - sprite->data2 = gFieldEffectSpawnParams[2]; + sprite->data2 = gFieldEffectArguments[2]; sprite->data3 = -1; sprite->data6 = -1; sprite->data7 = -1; @@ -1199,14 +1199,14 @@ u32 FldEff_Dust(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 12); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[9], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 12); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[9], gFieldEffectArguments[0], gFieldEffectArguments[1], 0); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; - sprite->data0 = gFieldEffectSpawnParams[2]; + sprite->oam.priority = gFieldEffectArguments[3]; + sprite->data0 = gFieldEffectArguments[2]; sprite->data1 = 10; } return 0; @@ -1220,7 +1220,7 @@ u32 FldEff_SandPile(void) struct Sprite *sprite; const struct MapObjectGraphicsInfo *graphicsInfo; - mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + mapObjectId = GetFieldObjectIdByLocalIdAndMap(gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); mapObject = &gMapObjects[mapObjectId]; spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[29], 0, 0, 0); if (spriteId != MAX_SPRITES) @@ -1229,9 +1229,9 @@ u32 FldEff_SandPile(void) sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; sprite->oam.priority = gSprites[mapObject->spriteId].oam.priority; - sprite->data0 = gFieldEffectSpawnParams[0]; - sprite->data1 = gFieldEffectSpawnParams[1]; - sprite->data2 = gFieldEffectSpawnParams[2]; + sprite->data0 = gFieldEffectArguments[0]; + sprite->data1 = gFieldEffectArguments[1]; + sprite->data2 = gFieldEffectArguments[2]; sprite->data3 = gSprites[mapObject->spriteId].pos1.x; sprite->data4 = gSprites[mapObject->spriteId].pos1.y; sprite->pos2.y = (graphicsInfo->height >> 1) - 2; @@ -1275,8 +1275,8 @@ u32 FldEff_Bubbles(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 0); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[34], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0x52); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 0); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[34], gFieldEffectArguments[0], gFieldEffectArguments[1], 0x52); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; @@ -1303,13 +1303,13 @@ u32 FldEff_BerryTreeGrowthSparkle(void) u8 spriteId; struct Sprite *sprite; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 4); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[22], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2]); + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 4); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[22], gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2]); if (spriteId != MAX_SPRITES) { sprite = &gSprites[spriteId]; sprite->coordOffsetEnabled = TRUE; - sprite->oam.priority = gFieldEffectSpawnParams[3]; + sprite->oam.priority = gFieldEffectArguments[3]; sprite->oam.paletteNum = 5; sprite->data0 = FLDEFF_BERRY_TREE_GROWTH_SPARKLE; } @@ -1338,7 +1338,7 @@ static u32 ShowDisguiseFieldEffect(u8 fldEff, u8 templateIdx, u8 paletteNum) u8 spriteId; struct Sprite *sprite; - if (TryGetFieldObjectIdByLocalIdAndMap(gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], gFieldEffectSpawnParams[2], &spriteId)) + if (TryGetFieldObjectIdByLocalIdAndMap(gFieldEffectArguments[0], gFieldEffectArguments[1], gFieldEffectArguments[2], &spriteId)) { FieldEffectActiveListRemove(fldEff); return MAX_SPRITES; @@ -1350,9 +1350,9 @@ static u32 ShowDisguiseFieldEffect(u8 fldEff, u8 templateIdx, u8 paletteNum) sprite->coordOffsetEnabled ++; sprite->oam.paletteNum = paletteNum; sprite->data1 = fldEff; - sprite->data2 = gFieldEffectSpawnParams[0]; - sprite->data3 = gFieldEffectSpawnParams[1]; - sprite->data4 = gFieldEffectSpawnParams[2]; + sprite->data2 = gFieldEffectArguments[0]; + sprite->data3 = gFieldEffectArguments[1]; + sprite->data4 = gFieldEffectArguments[2]; } return spriteId; } @@ -1424,13 +1424,13 @@ u32 FldEff_Sparkle(void) { u8 spriteId; - gFieldEffectSpawnParams[0] += 7; - gFieldEffectSpawnParams[1] += 7; - sub_8060470((s16 *)&gFieldEffectSpawnParams[0], (s16 *)&gFieldEffectSpawnParams[1], 8, 8); - spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[35], gFieldEffectSpawnParams[0], gFieldEffectSpawnParams[1], 0x52); + gFieldEffectArguments[0] += 7; + gFieldEffectArguments[1] += 7; + sub_8060470((s16 *)&gFieldEffectArguments[0], (s16 *)&gFieldEffectArguments[1], 8, 8); + spriteId = CreateSpriteAtEnd(gFieldEffectObjectTemplatePointers[35], gFieldEffectArguments[0], gFieldEffectArguments[1], 0x52); if (spriteId != MAX_SPRITES) { - gSprites[spriteId].oam.priority = gFieldEffectSpawnParams[2]; + gSprites[spriteId].oam.priority = gFieldEffectArguments[2]; gSprites[spriteId].coordOffsetEnabled = TRUE; } return 0; diff --git a/src/field_ground_effect.c b/src/field_ground_effect.c index e50811a78..2a398ba22 100644 --- a/src/field_ground_effect.c +++ b/src/field_ground_effect.c @@ -460,18 +460,18 @@ void GroundEffect_SpawnOnTallGrass(struct MapObject *mapObj, struct Sprite *spri { u8 *ptr; - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = 2; - gFieldEffectSpawnParams[4] = (mapObj->localId << 8) | mapObj->mapNum; - gFieldEffectSpawnParams[5] = mapObj->mapGroup; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = 2; + gFieldEffectArguments[4] = (mapObj->localId << 8) | mapObj->mapNum; + gFieldEffectArguments[5] = mapObj->mapGroup; ptr = (u8 *)&gSaveBlock1; - gFieldEffectSpawnParams[6] = ((u8)gSaveBlock1.location.mapNum << 8) + gFieldEffectArguments[6] = ((u8)gSaveBlock1.location.mapNum << 8) | (u8)gSaveBlock1.location.mapGroup; - gFieldEffectSpawnParams[7] = 1; + gFieldEffectArguments[7] = 1; FieldEffectStart(4); } @@ -479,18 +479,18 @@ void sub_8063E94(struct MapObject *mapObj, struct Sprite *sprite) { u8 *ptr; - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = 2; - gFieldEffectSpawnParams[4] = (mapObj->localId << 8) | mapObj->mapNum; - gFieldEffectSpawnParams[5] = mapObj->mapGroup; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = 2; + gFieldEffectArguments[4] = (mapObj->localId << 8) | mapObj->mapNum; + gFieldEffectArguments[5] = mapObj->mapGroup; ptr = (u8 *)&gSaveBlock1; - gFieldEffectSpawnParams[6] = ((u8)gSaveBlock1.location.mapNum << 8) + gFieldEffectArguments[6] = ((u8)gSaveBlock1.location.mapNum << 8) | (u8)gSaveBlock1.location.mapGroup; - gFieldEffectSpawnParams[7] = 0; + gFieldEffectArguments[7] = 0; FieldEffectStart(4); } @@ -498,18 +498,18 @@ void sub_8063EE0(struct MapObject *mapObj, struct Sprite *sprite) { u8 *ptr; - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = 2; - gFieldEffectSpawnParams[4] = (mapObj->localId << 8) | mapObj->mapNum; - gFieldEffectSpawnParams[5] = mapObj->mapGroup; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = 2; + gFieldEffectArguments[4] = (mapObj->localId << 8) | mapObj->mapNum; + gFieldEffectArguments[5] = mapObj->mapGroup; ptr = (u8 *)&gSaveBlock1; - gFieldEffectSpawnParams[6] = ((u8)gSaveBlock1.location.mapNum << 8) + gFieldEffectArguments[6] = ((u8)gSaveBlock1.location.mapNum << 8) | (u8)gSaveBlock1.location.mapGroup; - gFieldEffectSpawnParams[7] = 1; + gFieldEffectArguments[7] = 1; FieldEffectStart(17); } @@ -517,18 +517,18 @@ void sub_8063F2C(struct MapObject *mapObj, struct Sprite *sprite) { u8 *ptr; - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = 2; - gFieldEffectSpawnParams[4] = (mapObj->localId << 8) | mapObj->mapNum; - gFieldEffectSpawnParams[5] = mapObj->mapGroup; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = 2; + gFieldEffectArguments[4] = (mapObj->localId << 8) | mapObj->mapNum; + gFieldEffectArguments[5] = mapObj->mapGroup; ptr = (u8 *)&gSaveBlock1; - gFieldEffectSpawnParams[6] = ((u8)gSaveBlock1.location.mapNum << 8) + gFieldEffectArguments[6] = ((u8)gSaveBlock1.location.mapNum << 8) | (u8)gSaveBlock1.location.mapGroup; - gFieldEffectSpawnParams[7] = 0; + gFieldEffectArguments[7] = 0; FieldEffectStart(17); } @@ -572,11 +572,11 @@ static void DoTracksGroundEffect_Footprints(struct MapObject *mapObj, struct Spr // First half-word is a Field Effect script id. (gFieldEffectScriptPointers) u16 sandFootprints_FieldEffectData[2] = { 0xD, 0x18 }; - gFieldEffectSpawnParams[0] = mapObj->coords3.x; - gFieldEffectSpawnParams[1] = mapObj->coords3.y; - gFieldEffectSpawnParams[2] = 149; - gFieldEffectSpawnParams[3] = 2; - gFieldEffectSpawnParams[4] = mapObj->mapobj_unk_18; + gFieldEffectArguments[0] = mapObj->coords3.x; + gFieldEffectArguments[1] = mapObj->coords3.y; + gFieldEffectArguments[2] = 149; + gFieldEffectArguments[3] = 2; + gFieldEffectArguments[4] = mapObj->mapobj_unk_18; FieldEffectStart(sandFootprints_FieldEffectData[a]); } @@ -598,11 +598,11 @@ static void DoTracksGroundEffect_BikeTireTracks( if (mapObj->coords2.x != mapObj->coords3.x || mapObj->coords2.y != mapObj->coords3.y) { - gFieldEffectSpawnParams[0] = mapObj->coords3.x; - gFieldEffectSpawnParams[1] = mapObj->coords3.y; - gFieldEffectSpawnParams[2] = 149; - gFieldEffectSpawnParams[3] = 2; - gFieldEffectSpawnParams[4] = + gFieldEffectArguments[0] = mapObj->coords3.x; + gFieldEffectArguments[1] = mapObj->coords3.y; + gFieldEffectArguments[2] = 149; + gFieldEffectArguments[3] = 2; + gFieldEffectArguments[4] = bikeTireTracks_Transitions[mapObj->mapobj_unk_20][mapObj->mapobj_unk_18 - 5]; FieldEffectStart(FLDEFF_BIKE_TIRE_TRACKS); } @@ -627,10 +627,10 @@ void GroundEffect_JumpOnTallGrass(struct MapObject *mapObj, struct Sprite *sprit { u8 spriteId; - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = 2; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = 2; FieldEffectStart(FLDEFF_JUMP_TALL_GRASS); spriteId = sub_8126FF0( @@ -642,37 +642,37 @@ void GroundEffect_JumpOnTallGrass(struct MapObject *mapObj, struct Sprite *sprit void GroundEffect_JumpOnLongGrass(struct MapObject *mapObj, struct Sprite *sprite) { - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = 2; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = 2; FieldEffectStart(FLDEFF_JUMP_LONG_GRASS); } void GroundEffect_JumpOnShallowWater(struct MapObject *mapObj, struct Sprite *sprite) { - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = sprite->oam.priority; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = sprite->oam.priority; FieldEffectStart(FLDEFF_JUMP_SMALL_SPLASH); } void GroundEffect_JumpOnWater(struct MapObject *mapObj, struct Sprite *sprite) { - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = sprite->oam.priority; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = sprite->oam.priority; FieldEffectStart(FLDEFF_JUMP_BIG_SPLASH); } void GroundEffect_JumpLandingDust(struct MapObject *mapObj, struct Sprite *sprite) { - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; - gFieldEffectSpawnParams[2] = mapObj->elevation; - gFieldEffectSpawnParams[3] = sprite->oam.priority; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; + gFieldEffectArguments[2] = mapObj->elevation; + gFieldEffectArguments[3] = sprite->oam.priority; FieldEffectStart(FLDEFF_DUST); } @@ -688,8 +688,8 @@ void GroundEffect_HotSprings(struct MapObject *mapObj, struct Sprite *sprite) void GroundEffect_Seaweed(struct MapObject *mapObj, struct Sprite *sprite) { - gFieldEffectSpawnParams[0] = mapObj->coords2.x; - gFieldEffectSpawnParams[1] = mapObj->coords2.y; + gFieldEffectArguments[0] = mapObj->coords2.x; + gFieldEffectArguments[1] = mapObj->coords2.y; FieldEffectStart(FLDEFF_BUBBLES); } diff --git a/src/field_map_obj.c b/src/field_map_obj.c index 479e4bfde..65241839a 100644 --- a/src/field_map_obj.c +++ b/src/field_map_obj.c @@ -3892,10 +3892,10 @@ u8 do_berry_tree_growth_sparkle_1(struct MapObject *mapObject, struct Sprite *sp { if (!(sprite->data7 & 4) && sprite->animNum == 4) { - gFieldEffectSpawnParams[0] = mapObject->coords2.x; - gFieldEffectSpawnParams[1] = mapObject->coords2.y; - gFieldEffectSpawnParams[2] = sprite->subpriority - 1; - gFieldEffectSpawnParams[3] = sprite->oam.priority; + gFieldEffectArguments[0] = mapObject->coords2.x; + gFieldEffectArguments[1] = mapObject->coords2.y; + gFieldEffectArguments[2] = sprite->subpriority - 1; + gFieldEffectArguments[3] = sprite->oam.priority; FieldEffectStart(0x17); sprite->animNum = 0; } @@ -3931,10 +3931,10 @@ u8 do_berry_tree_growth_sparkle_2(struct MapObject *mapObject, struct Sprite *sp sprite->data1 = 3; sprite->data2 = 0; sprite->data7 |= 2; - gFieldEffectSpawnParams[0] = mapObject->coords2.x; - gFieldEffectSpawnParams[1] = mapObject->coords2.y; - gFieldEffectSpawnParams[2] = sprite->subpriority - 1; - gFieldEffectSpawnParams[3] = sprite->oam.priority; + gFieldEffectArguments[0] = mapObject->coords2.x; + gFieldEffectArguments[1] = mapObject->coords2.y; + gFieldEffectArguments[2] = sprite->subpriority - 1; + gFieldEffectArguments[3] = sprite->oam.priority; FieldEffectStart(0x17); return 1; } @@ -5083,7 +5083,7 @@ void FieldObjectCB_TreeDisguise(struct Sprite *sprite) mapObject = &gMapObjects[sprite->data0]; if (mapObject->mapobj_unk_21 == 0 || (mapObject->mapobj_unk_21 == 1 && sprite->data7 == 0)) { - FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectSpawnParams[0], (u8 *)&gFieldEffectSpawnParams[1], (u8 *)&gFieldEffectSpawnParams[2]); + FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectArguments[0], (u8 *)&gFieldEffectArguments[1], (u8 *)&gFieldEffectArguments[2]); mapObject->mapobj_unk_1A = FieldEffectStart(0x1c); mapObject->mapobj_unk_21 = 1; sprite->data7 ++; @@ -5103,7 +5103,7 @@ void FieldObjectCB_MountainDisguise(struct Sprite *sprite) mapObject = &gMapObjects[sprite->data0]; if (mapObject->mapobj_unk_21 == 0 || (mapObject->mapobj_unk_21 == 1 && sprite->data7 == 0)) { - FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectSpawnParams[0], (u8 *)&gFieldEffectSpawnParams[1], (u8 *)&gFieldEffectSpawnParams[2]); + FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectArguments[0], (u8 *)&gFieldEffectArguments[1], (u8 *)&gFieldEffectArguments[2]); mapObject->mapobj_unk_1A = FieldEffectStart(0x1d); mapObject->mapobj_unk_21 = 1; sprite->data7 ++; @@ -7487,7 +7487,7 @@ bool8 sub_8062644(struct MapObject *mapObject, struct Sprite *sprite) bool8 do_exclamation_mark_bubble_1(struct MapObject *mapObject, struct Sprite *sprite) { - FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectSpawnParams[0], (u8 *)&gFieldEffectSpawnParams[1], (u8 *)&gFieldEffectSpawnParams[2]); + FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectArguments[0], (u8 *)&gFieldEffectArguments[1], (u8 *)&gFieldEffectArguments[2]); FieldEffectStart(0x0); sprite->data2 = 1; return TRUE; @@ -7495,7 +7495,7 @@ bool8 do_exclamation_mark_bubble_1(struct MapObject *mapObject, struct Sprite *s bool8 do_exclamation_mark_bubble_2(struct MapObject *mapObject, struct Sprite *sprite) { - FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectSpawnParams[0], (u8 *)&gFieldEffectSpawnParams[1], (u8 *)&gFieldEffectSpawnParams[2]); + FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectArguments[0], (u8 *)&gFieldEffectArguments[1], (u8 *)&gFieldEffectArguments[2]); FieldEffectStart(0x21); sprite->data2 = 1; return TRUE; @@ -7503,7 +7503,7 @@ bool8 do_exclamation_mark_bubble_2(struct MapObject *mapObject, struct Sprite *s bool8 do_heart_bubble(struct MapObject *mapObject, struct Sprite *sprite) { - FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectSpawnParams[0], (u8 *)&gFieldEffectSpawnParams[1], (u8 *)&gFieldEffectSpawnParams[2]); + FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectArguments[0], (u8 *)&gFieldEffectArguments[1], (u8 *)&gFieldEffectArguments[2]); FieldEffectStart(0x2e); sprite->data2 = 1; return TRUE; diff --git a/src/field_map_obj_helpers.c b/src/field_map_obj_helpers.c index d8cb33251..b3edd9591 100644 --- a/src/field_map_obj_helpers.c +++ b/src/field_map_obj_helpers.c @@ -294,7 +294,7 @@ void sub_8064990(u8 a1, u8 dir) u32 oe_exec_and_other_stuff(u8 fieldEffectId, struct MapObject *mapObject) { - FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectSpawnParams[0], (u8 *)&gFieldEffectSpawnParams[1], (u8 *)&gFieldEffectSpawnParams[2]); + FieldObjectGetLocalIdAndMap(mapObject, (u8 *)&gFieldEffectArguments[0], (u8 *)&gFieldEffectArguments[1], (u8 *)&gFieldEffectArguments[2]); return FieldEffectStart(fieldEffectId); } @@ -310,9 +310,9 @@ void DoShadowFieldEffect(struct MapObject *mapObject) void DoRippleFieldEffect(struct MapObject *mapObject, struct Sprite *sprite) { const struct MapObjectGraphicsInfo *gfxInfo = GetFieldObjectGraphicsInfo(mapObject->graphicsId); - gFieldEffectSpawnParams[0] = sprite->pos1.x; - gFieldEffectSpawnParams[1] = sprite->pos1.y + (gfxInfo->height >> 1) - 2; - gFieldEffectSpawnParams[2] = 151; - gFieldEffectSpawnParams[3] = 3; + gFieldEffectArguments[0] = sprite->pos1.x; + gFieldEffectArguments[1] = sprite->pos1.y + (gfxInfo->height >> 1) - 2; + gFieldEffectArguments[2] = 151; + gFieldEffectArguments[3] = 3; FieldEffectStart(5); } diff --git a/src/field_player_avatar.c b/src/field_player_avatar.c index b055036ea..e7636e57c 100644 --- a/src/field_player_avatar.c +++ b/src/field_player_avatar.c @@ -666,9 +666,9 @@ void PlayerAvatarTransition_Surfing(struct MapObject *a) sub_805B980(a, GetPlayerAvatarGraphicsIdByStateId(3)); FieldObjectTurn(a, a->placeholder18); SetPlayerAvatarStateMask(8); - gFieldEffectSpawnParams[0] = a->coords2.x; - gFieldEffectSpawnParams[1] = a->coords2.y; - gFieldEffectSpawnParams[2] = gPlayerAvatar.mapObjectId; + gFieldEffectArguments[0] = a->coords2.x; + gFieldEffectArguments[1] = a->coords2.y; + gFieldEffectArguments[2] = gPlayerAvatar.mapObjectId; unk = FieldEffectStart(8); a->mapobj_unk_1A = unk; sub_8127ED0(unk, 1); @@ -1226,10 +1226,10 @@ u8 sub_8059EA4(struct Task *task, struct MapObject *b, struct MapObject *c) FieldObjectClearAnimIfSpecialAnimFinished(c); FieldObjectSetSpecialAnim(b, GetStepInPlaceDelay16AnimId(task->data[2])); FieldObjectSetSpecialAnim(c, GetSimpleGoAnimId(task->data[2])); - gFieldEffectSpawnParams[0] = c->coords2.x; - gFieldEffectSpawnParams[1] = c->coords2.y; - gFieldEffectSpawnParams[2] = c->elevation; - gFieldEffectSpawnParams[3] = gSprites[c->spriteId].oam.priority; + gFieldEffectArguments[0] = c->coords2.x; + gFieldEffectArguments[1] = c->coords2.y; + gFieldEffectArguments[2] = c->elevation; + gFieldEffectArguments[3] = gSprites[c->spriteId].oam.priority; FieldEffectStart(10); PlaySE(SE_W070); task->data[0]++; diff --git a/src/fldeff_cut.c b/src/fldeff_cut.c index d0fdd5139..2691f1a75 100644 --- a/src/fldeff_cut.c +++ b/src/fldeff_cut.c @@ -71,7 +71,7 @@ bool8 SetUpFieldMove_Cut(void) void sub_80A25E8(void) { FieldEffectStart(1); - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; } bool8 FldEff_UseCutOnGrass(void) @@ -86,7 +86,7 @@ bool8 FldEff_UseCutOnGrass(void) void sub_80A2634(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; ScriptContext1_SetupScript(&UseCutScript); } diff --git a/src/fldeff_flash.c b/src/fldeff_flash.c index df05de52b..a63cbbbf1 100644 --- a/src/fldeff_flash.c +++ b/src/fldeff_flash.c @@ -62,7 +62,7 @@ bool8 SetUpFieldMove_Flash(void) void sub_810CBFC(void) { u8 taskId = oei_task_add(); - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; gTasks[taskId].data[8] = (uintptr_t)sub_810CC34 >> 16; gTasks[taskId].data[9] = (uintptr_t)sub_810CC34; } diff --git a/src/fldeff_strength.c b/src/fldeff_strength.c index a5033e7b7..c641945d6 100644 --- a/src/fldeff_strength.c +++ b/src/fldeff_strength.c @@ -42,13 +42,13 @@ bool8 SetUpFieldMove_Strength(void) static void sub_811AA18(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; ScriptContext1_SetupScript(UseStrengthScript); } static void sub_811AA38(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; FieldEffectStart(40); } @@ -58,7 +58,7 @@ bool8 FldEff_UseStrength(void) gTasks[taskId].data[8] = (u32)sub_811AA9C >> 16; gTasks[taskId].data[9] = (u32)sub_811AA9C; - GetMonNickname(&gPlayerParty[gFieldEffectSpawnParams[0]], gStringVar1); + GetMonNickname(&gPlayerParty[gFieldEffectArguments[0]], gStringVar1); return FALSE; } diff --git a/src/fldeff_sweetscent.c b/src/fldeff_sweetscent.c index 66fa3dae2..661092ea0 100644 --- a/src/fldeff_sweetscent.c +++ b/src/fldeff_sweetscent.c @@ -31,7 +31,7 @@ bool8 SetUpFieldMove_SweetScent(void) static void sub_812BFD4(void) { FieldEffectStart(51); - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; } bool8 FldEff_SweetScent() diff --git a/src/fldeff_teleport.c b/src/fldeff_teleport.c index 8f75099dc..10fdcce6e 100644 --- a/src/fldeff_teleport.c +++ b/src/fldeff_teleport.c @@ -27,7 +27,7 @@ void hm_teleport_run_dp02scr(void) { new_game(); FieldEffectStart(63); - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; } bool8 FldEff_UseTeleport(void) diff --git a/src/pokemon_menu.c b/src/pokemon_menu.c index 94801f1a2..0fc79f711 100644 --- a/src/pokemon_menu.c +++ b/src/pokemon_menu.c @@ -786,7 +786,7 @@ static void sub_808ABA8(u8 taskID) { if (sub_807D770() == TRUE) { - gFieldEffectSpawnParams[0] = GetMonData(&gPlayerParty[gLastFieldPokeMenuOpened], MON_DATA_SPECIES); + gFieldEffectArguments[0] = GetMonData(&gPlayerParty[gLastFieldPokeMenuOpened], MON_DATA_SPECIES); gUnknown_03005CE4(); DestroyTask(taskID); } @@ -803,7 +803,7 @@ static void sub_808ABF4(u8 taskID) static void sub_808AC2C(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; FieldEffectStart(FLDEFF_USE_SURF); } @@ -821,7 +821,7 @@ static bool8 SetUpFieldMove_Surf(void) static void sub_808AC8C(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; FieldEffectStart(FLDEFF_USE_FLY); } @@ -872,14 +872,14 @@ u16 unref_sub_808AD88(void) static void sub_808ADAC(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; FieldEffectStart(FLDEFF_USE_DIVE); } static bool8 SetUpFieldMove_Dive(void) { - gFieldEffectSpawnParams[1] = sub_8068F18(); - if (gFieldEffectSpawnParams[1]) + gFieldEffectArguments[1] = sub_8068F18(); + if (gFieldEffectArguments[1]) { gFieldCallback = sub_808AB90; gUnknown_03005CE4 = sub_808ADAC; @@ -891,7 +891,7 @@ static bool8 SetUpFieldMove_Dive(void) static void sub_808AE08(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; FieldEffectStart(FLDEFF_USE_WATERFALL); } diff --git a/src/rom6.c b/src/rom6.c index 1f72eba93..702e48c69 100644 --- a/src/rom6.c +++ b/src/rom6.c @@ -91,17 +91,17 @@ static void sub_810B428(u8 taskId) { if (!FieldEffectActiveListContains(6)) { - gFieldEffectSpawnParams[1] = player_get_direction_lower_nybble(); - if (gFieldEffectSpawnParams[1] == 1) - gFieldEffectSpawnParams[2] = 0; - if (gFieldEffectSpawnParams[1] == 2) - gFieldEffectSpawnParams[2] = 1; - if (gFieldEffectSpawnParams[1] == 3) - gFieldEffectSpawnParams[2] = 2; - if (gFieldEffectSpawnParams[1] == 4) - gFieldEffectSpawnParams[2] = 3; + gFieldEffectArguments[1] = player_get_direction_lower_nybble(); + if (gFieldEffectArguments[1] == 1) + gFieldEffectArguments[2] = 0; + if (gFieldEffectArguments[1] == 2) + gFieldEffectArguments[2] = 1; + if (gFieldEffectArguments[1] == 3) + gFieldEffectArguments[2] = 2; + if (gFieldEffectArguments[1] == 4) + gFieldEffectArguments[2] = 3; sub_805B980(&gMapObjects[gPlayerAvatar.mapObjectId], GetPlayerAvatarGraphicsIdByCurrentState()); - StartSpriteAnim(&gSprites[gPlayerAvatar.spriteId], gFieldEffectSpawnParams[2]); + StartSpriteAnim(&gSprites[gPlayerAvatar.spriteId], gFieldEffectArguments[2]); FieldEffectActiveListRemove(6); gTasks[taskId].func = sub_810B4CC; } @@ -132,7 +132,7 @@ bool8 SetUpFieldMove_RockSmash(void) static void sub_810B53C(void) { - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; ScriptContext1_SetupScript(UseRockSmashScript); } @@ -171,7 +171,7 @@ static void sub_810B5D8(void) { sub_8053014(); FieldEffectStart(0x26); - gFieldEffectSpawnParams[0] = gLastFieldPokeMenuOpened; + gFieldEffectArguments[0] = gLastFieldPokeMenuOpened; } int FldEff_UseDig(void) diff --git a/src/scrcmd.c b/src/scrcmd.c index 752aafe35..74950acc7 100644 --- a/src/scrcmd.c +++ b/src/scrcmd.c @@ -1724,7 +1724,7 @@ bool8 ScrCmd_doanimation(struct ScriptContext *ctx) bool8 ScrCmd_setanimation(struct ScriptContext *ctx) { u8 v2 = ScriptReadByte(ctx); - gFieldEffectSpawnParams[v2] = (s16)VarGet(ScriptReadHalfword(ctx)); + gFieldEffectArguments[v2] = (s16)VarGet(ScriptReadHalfword(ctx)); return FALSE; } diff --git a/src/trainer_see.c b/src/trainer_see.c index 73dba2d60..18bf0907e 100644 --- a/src/trainer_see.c +++ b/src/trainer_see.c @@ -201,7 +201,7 @@ s8 sub_8084398(u8 taskId, struct Task *task, struct MapObject *trainerObj) { u8 direction; - FieldObjectGetLocalIdAndMap(trainerObj, (u8 *)&gFieldEffectSpawnParams[0], (u8 *)&gFieldEffectSpawnParams[1], (u8 *)&gFieldEffectSpawnParams[2]); + FieldObjectGetLocalIdAndMap(trainerObj, (u8 *)&gFieldEffectArguments[0], (u8 *)&gFieldEffectArguments[1], (u8 *)&gFieldEffectArguments[2]); FieldEffectStart(0); direction = GetFaceDirectionAnimId(trainerObj->mapobj_unk_18); @@ -311,10 +311,10 @@ s8 sub_80845FC(u8 taskId, struct Task *task, struct MapObject *trainerObj) { if (FieldObjectCheckIfSpecialAnimFinishedOrInactive(trainerObj)) { - gFieldEffectSpawnParams[0] = trainerObj->coords2.x; - gFieldEffectSpawnParams[1] = trainerObj->coords2.y; - gFieldEffectSpawnParams[2] = gSprites[trainerObj->spriteId].subpriority - 1; - gFieldEffectSpawnParams[3] = 2; + gFieldEffectArguments[0] = trainerObj->coords2.x; + gFieldEffectArguments[1] = trainerObj->coords2.y; + gFieldEffectArguments[2] = gSprites[trainerObj->spriteId].subpriority - 1; + gFieldEffectArguments[3] = 2; task->data[4] = FieldEffectStart(49); task->data[0]++; } @@ -421,9 +421,9 @@ void sub_8084894(struct Sprite *sprite, u16 a2, u8 a3) sprite->oam.priority = 1; sprite->coordOffsetEnabled = 1; - sprite->data0 = gFieldEffectSpawnParams[0]; - sprite->data1 = gFieldEffectSpawnParams[1]; - sprite->data2 = gFieldEffectSpawnParams[2]; + sprite->data0 = gFieldEffectArguments[0]; + sprite->data1 = gFieldEffectArguments[1]; + sprite->data2 = gFieldEffectArguments[2]; sprite->data3 = -5; sprite->data7 = a2; |