2015-11-03 16:43:47 -08:00
|
|
|
SRAM_Begin EQU $a000
|
|
|
|
SRAM_End EQU $c000
|
|
|
|
GLOBAL SRAM_Begin, SRAM_End
|
|
|
|
|
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "Scratch", SRAM
|
2015-10-04 11:14:51 -07:00
|
|
|
sScratch::
|
|
|
|
|
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "SRAM Bank 0", SRAM
|
2015-10-04 11:14:51 -07:00
|
|
|
|
2015-11-17 20:29:14 -08:00
|
|
|
; a600
|
2015-11-17 14:56:49 -08:00
|
|
|
sPartyMail::
|
2015-11-17 20:29:14 -08:00
|
|
|
sPartyMon1Mail:: mailmsg sPartyMon1Mail
|
|
|
|
sPartyMon2Mail:: mailmsg sPartyMon2Mail
|
|
|
|
sPartyMon3Mail:: mailmsg sPartyMon3Mail
|
|
|
|
sPartyMon4Mail:: mailmsg sPartyMon4Mail
|
|
|
|
sPartyMon5Mail:: mailmsg sPartyMon5Mail
|
|
|
|
sPartyMon6Mail:: mailmsg sPartyMon6Mail
|
|
|
|
|
|
|
|
; a71a
|
2015-11-17 14:56:49 -08:00
|
|
|
sPartyMailBackup::
|
|
|
|
sPartyMon1MailBackup:: mailmsg sPartyMon1MailBackup
|
|
|
|
sPartyMon2MailBackup:: mailmsg sPartyMon2MailBackup
|
|
|
|
sPartyMon3MailBackup:: mailmsg sPartyMon3MailBackup
|
|
|
|
sPartyMon4MailBackup:: mailmsg sPartyMon4MailBackup
|
|
|
|
sPartyMon5MailBackup:: mailmsg sPartyMon5MailBackup
|
|
|
|
sPartyMon6MailBackup:: mailmsg sPartyMon6MailBackup
|
|
|
|
|
2015-11-17 20:29:14 -08:00
|
|
|
; a834
|
2015-11-17 14:56:49 -08:00
|
|
|
sMailboxCount:: ds 1
|
|
|
|
sMailbox::
|
2015-11-17 20:29:14 -08:00
|
|
|
sMailbox1:: mailmsg sMailbox1
|
|
|
|
sMailbox2:: mailmsg sMailbox2
|
|
|
|
sMailbox3:: mailmsg sMailbox3
|
|
|
|
sMailbox4:: mailmsg sMailbox4
|
|
|
|
sMailbox5:: mailmsg sMailbox5
|
|
|
|
sMailbox6:: mailmsg sMailbox6
|
|
|
|
sMailbox7:: mailmsg sMailbox7
|
|
|
|
sMailbox8:: mailmsg sMailbox8
|
|
|
|
sMailbox9:: mailmsg sMailbox9
|
|
|
|
sMailbox10:: mailmsg sMailbox10
|
|
|
|
|
|
|
|
; aa0b
|
2015-11-17 14:56:49 -08:00
|
|
|
sMailboxCountBackup:: ds 1
|
|
|
|
sMailboxBackup::
|
2015-11-17 20:29:14 -08:00
|
|
|
sMailbox1Backup:: mailmsg sMailbox1Backup
|
|
|
|
sMailbox2Backup:: mailmsg sMailbox2Backup
|
|
|
|
sMailbox3Backup:: mailmsg sMailbox3Backup
|
|
|
|
sMailbox4Backup:: mailmsg sMailbox4Backup
|
|
|
|
sMailbox5Backup:: mailmsg sMailbox5Backup
|
|
|
|
sMailbox6Backup:: mailmsg sMailbox6Backup
|
|
|
|
sMailbox7Backup:: mailmsg sMailbox7Backup
|
|
|
|
sMailbox8Backup:: mailmsg sMailbox8Backup
|
|
|
|
sMailbox9Backup:: mailmsg sMailbox9Backup
|
|
|
|
sMailbox10Backup:: mailmsg sMailbox10Backup
|
|
|
|
|
|
|
|
; abe2
|
2015-10-04 11:14:51 -07:00
|
|
|
sMysteryGiftItem:: ds 1
|
2015-11-20 08:47:52 -08:00
|
|
|
sMysteryGiftUnlocked:: ds 1
|
2015-11-17 20:29:14 -08:00
|
|
|
sBackupMysteryGiftItem:: ds 1
|
2015-11-22 21:21:21 -08:00
|
|
|
sNumDailyMysteryGiftPartnerIDs:: ds 1
|
|
|
|
sDailyMysteryGiftPartnerIDs:: ds 5 * 2 ; maximum 5 per day, 2 bytes per ID
|
2015-11-20 08:47:52 -08:00
|
|
|
sMysteryGiftDecorationsReceived:: flag_array NUM_NON_TROPHY_DECOS
|
|
|
|
ds 4
|
2015-10-24 07:34:19 -07:00
|
|
|
sMysteryGiftTimer:: ds 1
|
|
|
|
sMysteryGiftTimerStartDay:: ds 1
|
2015-10-04 11:14:51 -07:00
|
|
|
ds 1
|
|
|
|
sMysteryGiftTrainerHouseFlag:: ds 1
|
2015-11-22 21:21:21 -08:00
|
|
|
sMysteryGiftPartnerName:: ds NAME_LENGTH
|
|
|
|
s0_ac09:: ds 1
|
2016-03-01 19:31:21 -08:00
|
|
|
sMysteryGiftTrainer:: ds (1 + 1 + NUM_MOVES) * PARTY_LENGTH + 2 ; ac0a
|
2015-11-17 20:29:14 -08:00
|
|
|
sBackupMysteryGiftItemEnd::
|
2015-10-04 11:14:51 -07:00
|
|
|
|
|
|
|
ds $30
|
|
|
|
|
2015-11-20 08:47:52 -08:00
|
|
|
sRTCStatusFlags:: ds 8
|
2015-10-10 14:03:04 -07:00
|
|
|
sLuckyNumberDay:: ds 1
|
|
|
|
sLuckyIDNumber:: ds 2
|
2015-10-04 11:14:51 -07:00
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "Backup Save", SRAM
|
2015-10-04 11:14:51 -07:00
|
|
|
sBackupOptions:: ds OptionsEnd - Options
|
|
|
|
|
2016-03-27 09:47:28 -07:00
|
|
|
s0_b208:: ds 1 ; loaded with 99, used to check save corruption
|
2015-10-04 11:14:51 -07:00
|
|
|
|
2016-05-04 08:46:23 -07:00
|
|
|
sBackupGameData:: ; b209
|
2015-10-04 11:14:51 -07:00
|
|
|
sBackupPlayerData:: ds wPlayerDataEnd - wPlayerData
|
|
|
|
sBackupMapData:: ds wMapDataEnd - wMapData
|
|
|
|
sBackupPokemonData:: ds wPokemonDataEnd - wPokemonData
|
|
|
|
sBackupGameDataEnd::
|
|
|
|
|
|
|
|
; bd83
|
|
|
|
ds $18a
|
|
|
|
; bf0d
|
|
|
|
|
|
|
|
sBackupChecksum:: ds 2
|
2016-03-27 09:47:28 -07:00
|
|
|
s0_bf0f:: ds 1 ; loaded with 0x7f, used to check save corruption
|
2015-10-04 11:14:51 -07:00
|
|
|
sStackTop:: ds 2
|
|
|
|
|
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "Save", SRAM
|
2015-10-04 11:14:51 -07:00
|
|
|
|
|
|
|
sOptions:: ds OptionsEnd - Options
|
|
|
|
|
2015-11-16 08:53:26 -08:00
|
|
|
s1_a008:: ds 1 ; loaded with 99, used to check save corruption
|
2015-10-04 11:14:51 -07:00
|
|
|
|
2016-05-04 08:46:23 -07:00
|
|
|
sGameData:: ; a009
|
2015-10-04 11:14:51 -07:00
|
|
|
sPlayerData:: ds wPlayerDataEnd - wPlayerData
|
|
|
|
sMapData:: ds wMapDataEnd - wMapData
|
|
|
|
sPokemonData:: ds wPokemonDataEnd - wPokemonData
|
|
|
|
sGameDataEnd::
|
|
|
|
|
|
|
|
; ab83
|
|
|
|
ds $18a
|
|
|
|
; ad0d
|
|
|
|
|
|
|
|
sChecksum:: ds 2
|
2015-11-16 08:53:26 -08:00
|
|
|
s1_ad0f:: ds 1 ; loaded with 0x7f, used to check save corruption
|
2015-10-04 11:14:51 -07:00
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "Active Box", SRAM
|
2015-10-04 11:14:51 -07:00
|
|
|
; ad10
|
|
|
|
box sBox
|
|
|
|
; b160
|
|
|
|
|
2015-11-10 15:17:04 -08:00
|
|
|
ds $f4
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "Link Battle Data", SRAM
|
2016-01-12 21:39:41 -08:00
|
|
|
sLinkBattleResults:: ds $c
|
2015-10-04 11:14:51 -07:00
|
|
|
|
|
|
|
sLinkBattleStats:: ; b260
|
|
|
|
sLinkBattleWins:: ds 2
|
2015-11-10 15:17:04 -08:00
|
|
|
sLinkBattleLosses:: ds 2 ; b262
|
|
|
|
sLinkBattleDraws:: ds 2 ; b264
|
2016-01-12 21:39:41 -08:00
|
|
|
link_battle_record: MACRO
|
|
|
|
\1Name:: ds NAME_LENGTH +- 1
|
|
|
|
\1ID:: ds 2
|
|
|
|
\1Wins:: ds 2
|
|
|
|
\1Losses:: ds 2
|
|
|
|
\1Draws:: ds 2
|
|
|
|
endm
|
|
|
|
sLinkBattleRecord::
|
|
|
|
sLinkBattleRecord1:: link_battle_record sLinkBattleRecord1
|
|
|
|
sLinkBattleRecord2:: link_battle_record sLinkBattleRecord2
|
|
|
|
sLinkBattleRecord3:: link_battle_record sLinkBattleRecord3
|
|
|
|
sLinkBattleRecord4:: link_battle_record sLinkBattleRecord4
|
|
|
|
sLinkBattleRecord5:: link_battle_record sLinkBattleRecord5
|
2015-10-04 11:14:51 -07:00
|
|
|
sLinkBattleStatsEnd::
|
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "SRAM Hall of Fame", SRAM
|
2015-10-04 11:14:51 -07:00
|
|
|
sHallOfFame:: ; b2c0
|
2015-12-05 05:08:01 -08:00
|
|
|
; temporary until I can find a way to macrofy it
|
|
|
|
hall_of_fame sHallOfFame01
|
|
|
|
hall_of_fame sHallOfFame02
|
|
|
|
hall_of_fame sHallOfFame03
|
|
|
|
hall_of_fame sHallOfFame04
|
|
|
|
hall_of_fame sHallOfFame05
|
|
|
|
hall_of_fame sHallOfFame06
|
|
|
|
hall_of_fame sHallOfFame07
|
|
|
|
hall_of_fame sHallOfFame08
|
|
|
|
hall_of_fame sHallOfFame09
|
|
|
|
hall_of_fame sHallOfFame10
|
|
|
|
hall_of_fame sHallOfFame11
|
|
|
|
hall_of_fame sHallOfFame12
|
|
|
|
hall_of_fame sHallOfFame13
|
|
|
|
hall_of_fame sHallOfFame14
|
|
|
|
hall_of_fame sHallOfFame15
|
|
|
|
hall_of_fame sHallOfFame16
|
|
|
|
hall_of_fame sHallOfFame17
|
|
|
|
hall_of_fame sHallOfFame18
|
|
|
|
hall_of_fame sHallOfFame19
|
|
|
|
hall_of_fame sHallOfFame20
|
|
|
|
hall_of_fame sHallOfFame21
|
|
|
|
hall_of_fame sHallOfFame22
|
|
|
|
hall_of_fame sHallOfFame23
|
|
|
|
hall_of_fame sHallOfFame24
|
|
|
|
hall_of_fame sHallOfFame25
|
|
|
|
hall_of_fame sHallOfFame26
|
|
|
|
hall_of_fame sHallOfFame27
|
|
|
|
hall_of_fame sHallOfFame28
|
|
|
|
hall_of_fame sHallOfFame29
|
|
|
|
hall_of_fame sHallOfFame30
|
|
|
|
|
|
|
|
; x = 1
|
|
|
|
; rept NUM_HOF_TEAMS
|
|
|
|
; ; PRINTT("{x}\n")
|
|
|
|
; if STRLEN({x}) == 2
|
|
|
|
; PRINTT(STRSUB({x},2,1))
|
|
|
|
; hall_of_fame STRCAT("sHallOfFame0", STRSUB({x},2,1))
|
|
|
|
; else
|
|
|
|
; PRINTT(STRSUB({x},2,2))
|
|
|
|
; hall_of_fame STRCAT("sHallOfFame", STRSUB({x},2,2))
|
|
|
|
; endc
|
|
|
|
; x = x + 1
|
|
|
|
; endr
|
2015-10-04 11:14:51 -07:00
|
|
|
sHallOfFameEnd::
|
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "SRAM Crystal Data", SRAM
|
2016-01-27 09:25:12 -08:00
|
|
|
sMobileEventIndex:: ds 1 ; be3c
|
2015-10-04 11:14:51 -07:00
|
|
|
|
|
|
|
sCrystalData::
|
|
|
|
ds wCrystalDataEnd - wCrystalData
|
2015-11-05 11:06:03 -08:00
|
|
|
sMobileEventIndexBackup:: ds 1
|
2015-11-24 12:18:44 -08:00
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "SRAM Battle Tower", SRAM
|
2015-11-24 12:18:44 -08:00
|
|
|
; data of the BattleTower must be in SRAM because you can save and leave between battles
|
|
|
|
sBattleTowerChallengeState:: ds 1
|
2015-11-17 20:29:14 -08:00
|
|
|
; 0: normal
|
|
|
|
; 2: battle tower
|
2015-10-04 11:14:51 -07:00
|
|
|
|
|
|
|
sBattleTower:: ; be46
|
2015-11-24 12:18:44 -08:00
|
|
|
sNrOfBeatenBattleTowerTrainers:: ds 1
|
2015-11-26 18:05:32 -08:00
|
|
|
sBTChoiceOfLevelGroup:: ds 1
|
2015-10-04 11:14:51 -07:00
|
|
|
; The 7 trainers of the BattleTower are saved here, so nobody appears more than once
|
|
|
|
sBTTrainers:: ; sbe48
|
|
|
|
ds 7
|
2016-03-27 09:47:28 -07:00
|
|
|
s1_be4f:: ds 1
|
2015-11-24 12:18:44 -08:00
|
|
|
sBattleTowerReward:: ds 1
|
2015-10-04 11:14:51 -07:00
|
|
|
; Pkmn of previous trainer
|
|
|
|
sBTPkmnOfTrainers:: ; 0xbe51
|
|
|
|
sBTPkmnPrevTrainer1::
|
|
|
|
ds 1
|
|
|
|
sBTPkmnPrevTrainer2:: ds 1
|
|
|
|
sBTPkmnPrevTrainer3:: ds 1
|
|
|
|
; Pkmn of preprevious trainer
|
|
|
|
sBTPkmnPrevPrevTrainer1:: ds 1
|
|
|
|
sBTPkmnPrevPrevTrainer2:: ds 1
|
|
|
|
sBTPkmnPrevPrevTrainer3:: ds 1
|
|
|
|
|
|
|
|
|
2017-03-24 04:51:03 -07:00
|
|
|
SECTION "Boxes 1-7", SRAM, BANK [2]
|
2015-10-04 11:14:51 -07:00
|
|
|
box sBox1
|
|
|
|
box sBox2
|
|
|
|
box sBox3
|
|
|
|
box sBox4
|
|
|
|
box sBox5
|
|
|
|
box sBox6
|
|
|
|
box sBox7
|
|
|
|
|
2017-06-17 16:14:55 -07:00
|
|
|
SECTION "Boxes 8-14", SRAM
|
2015-10-04 11:14:51 -07:00
|
|
|
box sBox8
|
|
|
|
box sBox9
|
|
|
|
box sBox10
|
|
|
|
box sBox11
|
|
|
|
box sBox12
|
|
|
|
box sBox13
|
|
|
|
box sBox14
|
2017-11-20 10:50:54 -08:00
|
|
|
|
|
|
|
SECTION "SRAM Mobile", SRAM, BANK [5]
|
|
|
|
ds 1 ; Former location for sMobileEventIndex, moved to 1:BE3C in English
|
|
|
|
sTrainerRankings:: ; a001
|
|
|
|
sTrainerRankingGameTimeHOF:: ds 4
|
|
|
|
sTrainerRankingStepCountHOF:: ds 4
|
|
|
|
sTrainerRankingHealingsHOF:: ds 4
|
|
|
|
sTrainerRankingBattlesHOF:: ds 3
|
|
|
|
sTrainerRankingStepCount:: ds 4
|
|
|
|
sTrainerRankingBattleTowerWins:: ds 4
|
|
|
|
sTrainerRankingTMsHMsTaught:: ds 3
|
|
|
|
sTrainerRankingBattles:: ds 3
|
|
|
|
sTrainerRankingWildBattles:: ds 3
|
|
|
|
sTrainerRankingTrainerBattles:: ds 3
|
|
|
|
sTrainerRankingUnused1:: ds 3
|
|
|
|
sTrainerRankingHOFEntries:: ds 3
|
|
|
|
sTrainerRankingWildMonsCaught:: ds 3
|
|
|
|
sTrainerRankingHookedEncounters:: ds 3
|
|
|
|
sTrainerRankingEggsHatched:: ds 3
|
|
|
|
sTrainerRankingMonsEvolved:: ds 3
|
|
|
|
sTrainerRankingFruitPicked:: ds 3
|
|
|
|
sTrainerRankingHealings:: ds 3
|
|
|
|
sTrainerRankingMysteryGift:: ds 3
|
|
|
|
sTrainerRankingTrades:: ds 3
|
|
|
|
sTrainerRankingFly:: ds 3
|
|
|
|
sTrainerRankingSurf:: ds 3
|
|
|
|
sTrainerRankingWaterfall:: ds 3
|
|
|
|
sTrainerRankingWhiteOuts:: ds 3
|
|
|
|
sTrainerRankingLuckyNumberShow:: ds 3
|
|
|
|
sTrainerRankingPhoneCalls:: ds 3
|
|
|
|
sTrainerRankingUnused2:: ds 3
|
|
|
|
sTrainerRankingLinkBattles:: ds 3
|
|
|
|
sTrainerRankingSplash:: ds 3
|
|
|
|
sTrainerRankingTreeEncounters:: ds 3
|
|
|
|
sTrainerRankingUnused3:: ds 3
|
|
|
|
sTrainerRankingColosseumWins:: ds 3
|
|
|
|
sTrainerRankingColosseumLosses:: ds 3
|
|
|
|
sTrainerRankingColosseumDraws:: ds 3
|
|
|
|
sTrainerRankingSelfdestruct:: ds 3
|
|
|
|
sTrainerRankingCurrentSlotsStreak:: ds 2
|
|
|
|
sTrainerRankingLongestSlotsStreak:: ds 2
|
|
|
|
sTrainerRankingTotalSlotsPayouts:: ds 4
|
|
|
|
sTrainerRankingTotalBattlePayouts:: ds 4
|
|
|
|
sTrainerRankingLongestMagikarp:: ds 2
|
|
|
|
sTrainerRankingShortestMagikarp:: ds 2
|
|
|
|
sTrainerRankingBugContestScore:: ds 2
|
|
|
|
sTrainerRankingsChecksum:: ds 2
|
|
|
|
sTrainerRankingsEnd:: ; a083
|
|
|
|
ds 1 ; Former location for sMobileEventIndexBackup, moved to 1:BE44 in English
|
|
|
|
sTrainerRankingsBackup:: ds sTrainerRankingsEnd - sTrainerRankings
|
|
|
|
|
|
|
|
ds $945
|
|
|
|
; aa4b
|
|
|
|
sMobileLoginPassword:: ds MOBILE_LOGIN_PASSWORD_LENGTH
|