2024-04-16 19:31 CEST

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0005231ISS[All Projects] Generalpublic2021-09-03 11:12
ReporterStingRay 
Assigned ToPsygoreProject InfoIncredible Shrinking Sphere (Electric Dreams)
http://www.whdload.de/games/ISS.html
 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
Summary0005231: Hi Psygore, the ISS patch needs a few improvements, which I'll list here: -
DescriptionGameVersion: english,pal,2 disks
SlaveVersion: 1.0 from 20.05.2000

Hi Psygore,
the ISS patch needs a few improvements, which I'll list here:
- 68000 quitkey support (game uses it's own level 2 interupt for keyboard handling hence the KickEmu support for that is rendered ineffective)
- default quitkey needs to be changed to something else than F10 as that key is used to pause the game
- the only OS routines used in the game are DoIO and WaitTOF, both are very easy to emulate so the patch can be made without any OS emulation at all.
I'll apply the needed code here so can copy/paste it.
The only other change needed to make the patch run without a Kickstart 1.3 ROM is adapting the level 3 interrupt code, this can be easily done as well.
Code follows.
Thanks and best regards,
Sting
    ; create exec and graphics library emulation
    lea $200.w,a0
    move.l a0,a6
    move.l a6,$4.w
    lea -456(a6),a1 ; DoIO()
    move.w #$4ef9,(a1)+
    pea DoIo(pc)
    move.l (a7)+,(a1)
    lea $300.w,a0
    move.l a0,$300-4.w
    lea -270(a0),a1 ; WaitTOF()
    move.w #$4ef9,(a1)+
    pea WaitTOF(pc)
    move.l (a7)+,(a1)
; ---------------------------------------------------------------------------
; Exec library emulation code
DoIo cmp.w #CMD_READ,IO_COMMAND(a1)
    bne.b .no_read
    movem.l d0-a6,-(a7)
    move.l IO_OFFSET(a1),d0
    move.l IO_LENGTH(a1),d1
    move.l IO_DATA(a1),a0
    moveq #1,d2
    move.l resload(pc),a2
    jsr resload_DiskLoad(a2)
    movem.l (a7)+,d0-a6
.no_read
    rts
; ---------------------------------------------------------------------------
; Graphics library emulation code
WaitTOF
    bra.w WaitRaster
.SetVBI pea .NewVBI(pc)
    move.l (a7)+,$6c.w
    rts
.NewVBI movem.l d0-a6,-(a7)
    btst #4,$dff01e+1
    beq.b .noCopInt
    cmp.w #0,$a400+$9DA4 ; 1: music enabled
    beq.w .lbC0078FA
    cmp.w #1,$a400+$9DA4
    bne.w .lbC0078F4
    jsr $a400+$790c
    bra.w .lbC0078FA
.lbC0078F4
    jsr $a400+$9df0
.lbC0078FA
    
.noCopInt
    movem.l (a7)+,d0-a6
.AckVBI move.w #1<<4|1<<5|1<<6,$dff09c
    move.w #1<<4|1<<5|1<<6,$dff09c
    rte
 
WaitRaster
.wait1 btst #0,$dff005
    beq.b .wait1
.wait2 btst #0,$dff005
    bne.b .wait2
    rts
TagsNo tags attached.
MachineA4000
CPU68060
CPUSpeed50
ChipSetAGA
GFXCardPicasso IV
ChipMem2 MB
FastMem128 MB
WorkbenchOS 3.1
KickROM40 - Kick 3.1
KickSoftNone
WHDLoad18.6
importedyes
Attached Files

-Relationships
+Relationships

-Notes

note ~0010382

Psygore (developer)

Hi StingRay,

Yep, if there are only DoIO and WaitTOF to patch, it will be easy to remove the kickemu (we have done some slaves with more OS stuff patched ;)
I didn’t take a look at this slave since it was written in 2002. IIRC the kickemu hadn’t the quitkey yet back in the day, so it will have a working quitkey on 68000 now.
I usually filled the jump table in library emulation with illegal instruction so it will quit if an os routine is not patched and you will know the function offset.
Thanks for your ideas and suggestions, I really appreciate.
I will rewrite the slave.

note ~0010385

StingRay (developer)

Current KickEmu won't help with the 68000 quitkey support, the game bangs the level 2 interrupt vector ($68.w) directly and uses its own level 2 interrupt.

If you're going to rewrite the slave, you may also add some trainers as the game is very hard.

Lives are decreased at $a400+$e90, ammo is decreased at $A400+$49da.

note ~0010541

Psygore (developer)

Install has been updated.
+Notes

-Issue History
Date Modified Username Field Change
2021-05-24 23:14 administrator New Issue
2021-05-24 23:14 administrator Status new => assigned
2021-05-24 23:14 administrator Assigned To => Psygore
2021-05-28 15:54 Psygore Note Added: 0010382
2021-05-29 16:42 StingRay Note Added: 0010385
2021-07-16 19:53 Psygore Status assigned => resolved
2021-07-16 19:53 Psygore Resolution open => fixed
2021-07-16 19:53 Psygore Note Added: 0010541
2021-09-03 11:12 Psygore Status resolved => closed
+Issue History