mirror of
https://github.com/badvision/lawless-legends.git
synced 2024-06-27 07:29:32 +00:00
Fixed floppy version of story mode.
This commit is contained in:
parent
f1fa25da1c
commit
37af866d24
|
@ -4847,11 +4847,13 @@ end
|
|||
// First output the shared intro text
|
||||
outIndented("setStoryMode(TRUE)\n")
|
||||
outTextBlock(blk.value[0].block, false)
|
||||
outIndented("rawDisplayStr(\"\\n\\n\")\n")
|
||||
|
||||
// On floppy builds, follow the intro with just the short text (usually e.g. "read log X")
|
||||
outIndented("if isFloppyVer\n")
|
||||
++indent
|
||||
outTextBlock(blk.value[1].block, false)
|
||||
outIndented("promptAnyKeyAndClear()\n")
|
||||
--indent
|
||||
|
||||
// On 800k or hard drive builds, follow the intro with the full (long) text
|
||||
|
|
|
@ -332,6 +332,7 @@ loMemBegin: !pseudopc $800 {
|
|||
_fixedRTS:
|
||||
rts ; fixed place to find RTS, for setting V flag
|
||||
_diskOpCt !byte 0 ; count of disk ops since last render
|
||||
_floppyFlg !byte 0 ; set the first time we don't find the partition we're looking for
|
||||
|
||||
__aux_dispatch:
|
||||
sec
|
||||
|
@ -2030,7 +2031,9 @@ openPartition: !zone
|
|||
pla
|
||||
sta isAuxCmd ; back to aux if that's what outer was using
|
||||
rts
|
||||
.flip lda floppyDrive
|
||||
.flip lda #1
|
||||
sta _floppyFlg
|
||||
lda floppyDrive
|
||||
eor #$80
|
||||
sta floppyDrive
|
||||
cmp .origFloppy
|
||||
|
|
|
@ -514,6 +514,7 @@ _waitKey = _crout+3
|
|||
_internalErr = _waitKey+3
|
||||
fixedRTS = _internalErr+3
|
||||
diskOpCt = fixedRTS+1
|
||||
floppyFlg = diskOpCt+1
|
||||
|
||||
; Debug macros
|
||||
!macro safeBell {
|
||||
|
|
|
@ -92,6 +92,7 @@ import gamelib
|
|||
predef printf3(fmt, arg1, arg2, arg3)#0
|
||||
predef printHex(num)#0
|
||||
predef printMem()#1
|
||||
predef promptAnyKeyAndClear()#0
|
||||
predef puts(str)#0
|
||||
predef queue_setMap(is3D, num, x, y, dir)#0
|
||||
predef queue_teleport(x, y, dir)#0
|
||||
|
|
|
@ -791,6 +791,15 @@ export asm auxMmgr(cmd, wordParam)#1
|
|||
rts
|
||||
end
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Get mem mgr's flag telling if this is the floppy version or not
|
||||
asm getFloppyFlg()#1
|
||||
+asmPlasmRet 0
|
||||
lda floppyFlg
|
||||
ldy #0
|
||||
rts
|
||||
end
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Execute a monitor breakpoint
|
||||
export asm brk()#0
|
||||
|
@ -2082,6 +2091,10 @@ def initMap(x, y, dir)#0
|
|||
doRender()
|
||||
fin
|
||||
|
||||
// Init the floppy flag after the first full load, which will have certainly
|
||||
// hit some disk besides 1 if there is such a disk.
|
||||
isFloppyVer = getFloppyFlg
|
||||
|
||||
// Assume there might be animations until we learn otherwise
|
||||
resetAnimPause
|
||||
|
||||
|
@ -2192,7 +2205,7 @@ end
|
|||
///////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Called by scripts to display a string. We set the flag noting that something has been
|
||||
// displayed, then use an assembly routine to do the work.
|
||||
export def _scriptDisplayStr(str)#0
|
||||
def _scriptDisplayStr(str)#0
|
||||
if renderLoaded and !curPortrait and !curFullscreenImg and needRender
|
||||
doRender()
|
||||
flipToPage1()
|
||||
|
@ -2204,6 +2217,13 @@ export def _scriptDisplayStr(str)#0
|
|||
anyInteraction = TRUE
|
||||
end
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
export def promptAnyKeyAndClear()#0
|
||||
scriptDisplayStr("\n(press any key)")
|
||||
getUpperKey
|
||||
clearWindow
|
||||
end
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
def snooze()#1
|
||||
word cursX, cursY
|
||||
|
@ -3524,13 +3544,11 @@ def startGame(firstTime, ask)#0
|
|||
q_mapNum = 0
|
||||
restoreMapPos()
|
||||
fin
|
||||
crout()
|
||||
end
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Main code.
|
||||
//
|
||||
isFloppyVer = FALSE // FIXME
|
||||
scriptDisplayStr(@_scriptDisplayStr) // 1-time init
|
||||
startGame(TRUE, TRUE) // first time init; ask whether new or load
|
||||
kbdLoop()
|
||||
|
|
|
@ -143,7 +143,6 @@ def _story_display(storyNum)#1
|
|||
byte c
|
||||
|
||||
loadStory(storyNum)
|
||||
rawDisplayStr("\n\n")
|
||||
|
||||
while pStoryCur < pStoryEnd
|
||||
if displayStoryBlock
|
||||
|
|
Loading…
Reference in New Issue
Block a user