Skip to content

Commit

Permalink
Display a better message when a score upload fails so it is more clea…
Browse files Browse the repository at this point in the history
…r what happened.
  • Loading branch information
jeremysrand committed Jul 8, 2021
1 parent 40da3b3 commit 25a8fbe
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 5 deletions.
2 changes: 1 addition & 1 deletion BuGS.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@
9DE37B3E2694E0B0005FC562 /* globalScores.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = globalScores.h; sourceTree = "<group>"; };
9DE37B3F2694E0B0005FC562 /* globals.s */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = globals.s; sourceTree = "<group>"; };
9DE37B402694E0B0005FC562 /* gameSegments.s */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = gameSegments.s; sourceTree = "<group>"; };
9DE37B412694E0B0005FC562 /* score.s */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = score.s; sourceTree = "<group>"; };
9DE37B412694E0B0005FC562 /* score.s */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = score.s; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.asm.orcam; };
9DE37B422694E0B0005FC562 /* gamePlayer.s */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = gamePlayer.s; sourceTree = "<group>"; };
9DE37B432694E0B0005FC562 /* Read.Me.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = net.daringfireball.markdown; path = Read.Me.md; sourceTree = "<group>"; };
9DE37B442694E0B0005FC562 /* global.macros */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = global.macros; sourceTree = "<group>"; };
Expand Down
53 changes: 49 additions & 4 deletions BuGS/score.s
Original file line number Diff line number Diff line change
Expand Up @@ -821,41 +821,86 @@ checkHighScore_retry anop
checkHighScore_retryPrompt anop
ldx #GAME_NUM_TILES_WIDE*22+2
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_LETTER_S
_overwriteGameTile TILE_LETTER_C
_overwriteGameTile TILE_LETTER_O
_overwriteGameTile TILE_LETTER_R
_overwriteGameTile TILE_LETTER_E
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_LETTER_U
_overwriteGameTile TILE_LETTER_P
_overwriteGameTile TILE_LETTER_L
_overwriteGameTile TILE_LETTER_O
_overwriteGameTile TILE_LETTER_A
_overwriteGameTile TILE_LETTER_D
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_LETTER_F
_overwriteGameTile TILE_LETTER_A
_overwriteGameTile TILE_LETTER_I
_overwriteGameTile TILE_LETTER_L
_overwriteGameTile TILE_LETTER_E
_overwriteGameTile TILE_LETTER_D
_overwriteGameTile TILE_SYMBOL_COLON
_overwriteGameTile TILE_EMPTY

ldx #GAME_NUM_TILES_WIDE*24+2
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_LETTER_R
_overwriteGameTile TILE_LETTER_E
_overwriteGameTile TILE_LETTER_T
_overwriteGameTile TILE_LETTER_R
_overwriteGameTile TILE_LETTER_Y
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_LETTER_U
_overwriteGameTile TILE_LETTER_P
_overwriteGameTile TILE_LETTER_L
_overwriteGameTile TILE_LETTER_O
_overwriteGameTile TILE_LETTER_A
_overwriteGameTile TILE_LETTER_D
_overwriteGameTile TILE_SYMBOL_COLON
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_LETTER_Y
_overwriteGameTile TILE_SYMBOL_COLON
_overwriteGameTile TILE_LETTER_N
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_SOLID2
_overwriteGameTile TILE_EMPTY

jsl waitForKey
and #$df
cmp #'N'
beq checkHighScore_doneNetwork
cmp #'Y'
bne checkHighScore_doRetry
brl checkHighScore_retry
checkHighScore_doRetry anop
beq checkHighScore_doRetry
brl checkHighScore_retryPrompt

checkHighScore_doneNetwork anop
jsl updateHighScore
sec
rtl
checkHighScore_doRetry anop
ldx #GAME_NUM_TILES_WIDE*24+2
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
_overwriteGameTile TILE_EMPTY
brl checkHighScore_retry


uploadSpin1 entry
Expand Down

0 comments on commit 25a8fbe

Please sign in to comment.