Is there a way to hex-edit Prince.exe to make this possible?
I’ve gotten pretty handy with hex-editing lately.
Guard loosing life when loose tile hits him
Re: Guard loosing life when loose tile hits him
I'm afraid that's not so simple.
In SDLPoP this is the code that checks if a loose floor fell onto the prince: https://github.com/NagyD/SDLPoP/blob/ma ... 07.c#L1191
To make a similar check for guards, we would need to make a copy of this check with loadshad/saveshad instead of loadkid/savekid.
While that change is simple in SDLPoP, it's much harder to do in PRINCE.EXE.
Re: Guard loosing life when loose tile hits him
Alright, it’s fine. I just wanted to know how easy it was (if possible). I don’t actually need to implement it.David wrote: ↑July 13th, 2019, 10:31 amI'm afraid that's not so simple.
In SDLPoP this is the code that checks if a loose floor fell onto the prince: https://github.com/NagyD/SDLPoP/blob/ma ... 07.c#L1191
To make a similar check for guards, we would need to make a copy of this check with loadshad/saveshad instead of loadkid/savekid.
While that change is simple in SDLPoP, it's much harder to do in PRINCE.EXE.
Re: Guard loosing life when loose tile hits him
Would that approach work if the guard is in a room below that you have not visited?
I did something similar in my mod where the guard dies if a tile falls on his head like in POP2 but in a hackier way. The game checks when you enter the guard if he is standing on debris that were not there initially. The hacky part is that the room can contain other debris tiles and the guard can move there during a fight. So I also have to track if there was a live guard standing on debris when leaving a room so he does not die if you re-enter it. So the logic is only limited to rooms and levels where it is possible to drop a tile on a guard.
I did something similar in my mod where the guard dies if a tile falls on his head like in POP2 but in a hackier way. The game checks when you enter the guard if he is standing on debris that were not there initially. The hacky part is that the room can contain other debris tiles and the guard can move there during a fight. So I also have to track if there was a live guard standing on debris when leaving a room so he does not die if you re-enter it. So the logic is only limited to rooms and levels where it is possible to drop a tile on a guard.