Page 1 of 1

Police Stories - working with simple assembly and movsd

Posted: Fri May 10, 2024 3:50 pm
by Fenekie
Hello there guys,
I bought a game on Steam called Police Stories (programmed in the Game Maker engine), where besides a gun, your equipment is a blinding grenade, first aid kit, lockpicks, etc. I've found trainers everywhere on the internet with the infinite ammo option, but I'd rather have unlimited equipment. I tried making a simple assembly script. I found a value from the amount of liquid in the pepper spray, this value was one of the largest, the others were too small to find. And through "Find out what writes to this address" and "Show disassembler" I created the following script:

Code: Select all

define(address,"PoliceStories.exe"+19243)
define(bytes,F2 0F 11 0E EB 21)

[ENABLE]

assert(address,bytes)
alloc(newmem,$1000)

label(code)
label(return)
label(myvar)

newmem:
  movsd xmm1,[myvar]

code:
  movsd [esi],xmm1
  jmp PoliceStories.exe+1926A
  jmp return

address:
  jmp newmem
  nop

myvar:
  dq (double)20

return:

[DISABLE]

address:
  db bytes
  // movsd [esi],xmm1
  // jmp PoliceStories.exe+1926A

dealloc(newmem)
The game crashes on me with an error message. Any idea what I'm doing wrong or how to do it differently? I'm a beginner at assembly and although I've watched a few tutorials my head somehow never managed to pick up more, but I'm willing to keep learning.

Re: Police Stories - working with simple assembly and movsd

Posted: Fri May 10, 2024 5:31 pm
by BabyGroot

Code: Select all

define(address,"PoliceStories.exe"+19243)
define(bytes,F2 0F 11 0E EB 21)

[ENABLE]

assert(address,bytes)
alloc(newmem,$1000)

label(code)
label(return)
label(myvar)

newmem:

code:
  movsd xmm1, [myvar]
  movsd [esi],xmm1
  jmp PoliceStories.exe+1926A
  jmp return

myvar:
  dq (double)20

address:
  jmp newmem
  nop

return:

[DISABLE]

address:
  db bytes
  // movsd [esi],xmm1
  // jmp PoliceStories.exe+1926A

dealloc(newmem)

Re: Police Stories - working with simple assembly and movsd

Posted: Fri May 10, 2024 9:07 pm
by Fenekie
Well BabyGroot that works, thx... but now it's crashing for other reasons... so... screw it... ._.