[Gothic II - NOTR] Brother Garwig dead on each playthrough
Describe the bug On both saves (mage and paladin) brother Garwig seems to be dead at start of the game.
At least I couldn't find him on both runs, and I was attacked by the Serpentes, when I gave him the hammer back after joining the mages.
I did change the games variables on the mage run (to fix Lares not showing the option to guide me to the water mages) using set var. I did not dabble with the save game on the second run, though. My best guest would be that the save file is incorrectly initialized?
Save-game/Log-file/Screenshots/Video Note: I inserted him back into the world on the mage save, since I couldn't progress the story otherwise.
If applicable, add screenshots or save-game file to help explain your problem.
Application log
If relevant attach log.txt file or, in case of game-crash, crash.log
System Build: v1.0.3321 OS: Arch Linux
EDIT: I'm also not entirely sure if it's the game files or the engine that cause this. Initial state of each NPC should technically be part of the game files, right? On the other hand, I don't remember having that issue, when I ran the game over steam.
same
Could be related to https://github.com/Try/OpenGothic/issues/657
I've looked only a bit into brother Garwig case. Increasing game speed and wait for a few in-game days, unfortunately want enough to reproduce this issue so far.
This one was on me, sorry for that. PR should fix it.
Hi, @thokkat!
It doesn't seem, that your patch addresses Garwig's issue. Brother Garwig, according to script never changes waypoint, instead always stands on "NW_MONASTERY_ENTRY_01".
Waypoint/Routines are probable related to cases like #829
I can reproduce Garwig's dissapearing. He exists until Hero goes to sleep. If Hero went to sleep then Garwig disappears.
https://github.com/user-attachments/assets/c490d594-f8dc-48da-b8b2-5288a332b78d
I can't find Garwig either and when I try inserting him via insert garwig the game crashes (i'm using the remaster mod with remaster scripts)
EDIT: sometimes the game doesn't crash but it doesn't insert Garwig. it prints the following log:
[zenkit] Parsing object [VobTree % 0 0]
[zenkit] Parsing object [EndMarker % 0 0]
[zenkit] Internal Exception: popping instance from empty stack
[zenkit] Internal Exception: popping instance from empty stack
@Try I also just tried the newest build but the problem persists (keep getting the Internal Exception)
Hi, @yankydoo !
It should be insert NOV_608_Garwig. Problem with insert garwig - it invokes variable instead of actual npc-prototype.
CC @lmichaelis
Problem is reproducible on non-modded gothic2. Basically VM can't tell the difference between instance and variable pointing to npc. When insert garwig called VM eventually attempts to execute byte-code at address equal to zero.
While executing 0, it also underflow stack, resulting in _m_stack_ptr = 65'535. Crash can occur as soon as next call.
Now I feel stupid for not finding the insert codes. Thank you for your help and your work!