document slot machine
This commit is contained in:
@@ -996,7 +996,7 @@ static void sub_81405CC(void)
|
||||
taskId = gUnknown_0203AB88->varA4 = CreateTask(sub_81408A8, 0);
|
||||
gTasks[taskId].data[6] = 6;
|
||||
gTasks[taskId].data[13] = GetCoins();
|
||||
sub_80EDE84(GetCoins());
|
||||
reportPlayedRoulette(GetCoins());
|
||||
gUnknown_0203AB88->varA5 = CreateTask(sub_8140814, 1);
|
||||
SetMainCallback2(sub_8140238);
|
||||
return;
|
||||
@@ -1964,7 +1964,7 @@ static void sub_8141DE4(u8 taskId)
|
||||
gSpecialVar_0x8004 = TRUE;
|
||||
else
|
||||
gSpecialVar_0x8004 = FALSE;
|
||||
sub_80EDD78(GetCoins());
|
||||
reportNewCoinTotal(GetCoins());
|
||||
BeginHardwarePaletteFade(0xFF, 0, 0, 16, 0);
|
||||
gTasks[taskId].func = sub_8141E7C;
|
||||
}
|
||||
|
||||
1864
src/slot_machine.c
1864
src/slot_machine.c
File diff suppressed because it is too large
Load Diff
@@ -1,9 +1,6 @@
|
||||
#include "global.h"
|
||||
#include "task.h"
|
||||
|
||||
#define HEAD_SENTINEL 0xFE
|
||||
#define TAIL_SENTINEL 0xFF
|
||||
|
||||
struct Task gTasks[NUM_TASKS];
|
||||
|
||||
static void InsertTask(u8 newTaskId);
|
||||
|
||||
16
src/tv.c
16
src/tv.c
@@ -62,7 +62,7 @@ IWRAM_DATA s8 sTVShowMixingCurSlot;
|
||||
EWRAM_DATA u16 sPokemonAnglerSpecies = 0;
|
||||
EWRAM_DATA u16 sPokemonAnglerAttemptCounters = 0;
|
||||
EWRAM_DATA u16 sFindThatGamerCoinsSpent = 0;
|
||||
EWRAM_DATA bool8 sFindThatGamerWhichGame = FALSE;
|
||||
EWRAM_DATA bool8 sFindThatGamerWhichGame = SLOT_MACHINE;
|
||||
EWRAM_DATA ALIGNED(4) u8 sRecordMixingPartnersWithoutShowsToShare = 0;
|
||||
EWRAM_DATA ALIGNED(4) u8 sTVShowState = 0;
|
||||
EWRAM_DATA u8 sTVSecretBaseSecretsRandomValues[3] = {};
|
||||
@@ -2019,7 +2019,7 @@ void sub_80EDCE8(void)
|
||||
}
|
||||
}
|
||||
|
||||
void sub_80EDD78(u16 nCoinsPaidOut)
|
||||
void reportNewCoinTotal(u16 nCoinsPaidOut)
|
||||
{
|
||||
TVShow *show;
|
||||
bool8 flag;
|
||||
@@ -2031,7 +2031,7 @@ void sub_80EDD78(u16 nCoinsPaidOut)
|
||||
flag = FALSE;
|
||||
switch (sFindThatGamerWhichGame)
|
||||
{
|
||||
case FALSE:
|
||||
case SLOT_MACHINE:
|
||||
if (nCoinsPaidOut >= sFindThatGamerCoinsSpent + 200)
|
||||
{
|
||||
flag = TRUE;
|
||||
@@ -2044,7 +2044,7 @@ void sub_80EDD78(u16 nCoinsPaidOut)
|
||||
break;
|
||||
}
|
||||
return;
|
||||
case TRUE:
|
||||
case ROULETTE:
|
||||
if (nCoinsPaidOut >= sFindThatGamerCoinsSpent + 50)
|
||||
{
|
||||
flag = TRUE;
|
||||
@@ -2072,15 +2072,15 @@ void sub_80EDD78(u16 nCoinsPaidOut)
|
||||
}
|
||||
}
|
||||
|
||||
void sub_80EDE70(u16 nCoinsSpent)
|
||||
void reportPlayedSlotMachine(u16 nCoinsSpent)
|
||||
{
|
||||
sFindThatGamerWhichGame = FALSE;
|
||||
sFindThatGamerWhichGame = SLOT_MACHINE;
|
||||
sFindThatGamerCoinsSpent = nCoinsSpent;
|
||||
}
|
||||
|
||||
void sub_80EDE84(u16 nCoinsSpent)
|
||||
void reportPlayedRoulette(u16 nCoinsSpent)
|
||||
{
|
||||
sFindThatGamerWhichGame = TRUE;
|
||||
sFindThatGamerWhichGame = ROULETTE;
|
||||
sFindThatGamerCoinsSpent = nCoinsSpent;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user