SRP
SRP copied to clipboard
Suslov exploit
While talking with Suslov for the first time and getting your first equipment, you may get some more gear in the start.
This may be reproduced by pressing F and then immediately Esc (or both at the same time). If you try to do it after a few centiseconds had passed, you can't close dialog via Esc already.
I managed to do this up to 4 times in a row. Interestingly enough, I also got some knifes.
More of dialog bug?
Glad you reconsidered.
This may also be reproduced by pressing Pause while in dialogue and then pressing Esc and unpausing the game back.
The engine defaults to allowing the player to break out of dialogues. This behavior is altered on a per-dialogue basis in Cmeet_manager:process_use
in xr_meet.script a few frames after the dialogue window has been opened:
if self.npc:is_talking() then
db.actor:allow_break_talk_dialog(self.st.allow_break)
end
We can effectively invert this behavior (i.e. disallow the player to break out of dialogues by default) by adding the following to the body of function dialog_wnd_showed
in pda.script:
db.actor:allow_break_talk_dialog(false)
This immediately undoes the engine's allow-break-by-default behavior but still allows that behavior to be overridden if appropriate for the given dialogue.
Unfortunately, while this fixes the reported problem, it introduces another: whereas before it would take the "Exit" button a few frames to disappear after the dialogue window has been opened, it now takes the "Exit" button a few frames to appear after the dialogue window has been opened. This is more of an aesthetic annoyance than a functional one, but I'd prefer to get rid of the few-frame delay. My first instinct was to insert the following code into function motivator_binder:use_callback
in xr_motivator.script:
user:allow_break_talk_dialog(npc_st.meet.allow_break)
... but that didn't help.
Fixed in https://github.com/Decane/SRP/commit/00c405e85d3931790231b07ad60ef00584da3076.