fix battle script clearing specialBattleType (#4536)
Co-authored-by: ghoulslash <pokevoyager0@gmail.com>
This commit is contained in:
parent
f12773dbb8
commit
e122ba28be
@ -3254,11 +3254,13 @@ static void ClearSetBScriptingStruct(void)
|
||||
{
|
||||
// windowsType is set up earlier in BattleInitBgsAndWindows, so we need to save the value
|
||||
u32 temp = gBattleScripting.windowsType;
|
||||
u32 specialBattleType = gBattleScripting.specialTrainerBattleType;
|
||||
memset(&gBattleScripting, 0, sizeof(gBattleScripting));
|
||||
|
||||
gBattleScripting.windowsType = temp;
|
||||
gBattleScripting.battleStyle = gSaveBlock2Ptr->optionsBattleStyle;
|
||||
gBattleScripting.expOnCatch = (B_EXP_CATCH >= GEN_6);
|
||||
gBattleScripting.specialTrainerBattleType = specialBattleType;
|
||||
}
|
||||
|
||||
static void BattleStartClearSetData(void)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user