View previous topic :: View next topic |
Author |
Message |
MetaPhaze
Joined: 03 Jun 2007 Posts: 30 Location: USA
|
Posted: Tue Jan 17, 2017 17:34 Post subject: Bug: NWNXFixes - settings below -10 hitpoints for death. |
|
|
If you set your negative hit point value in the nwnx2.ini file to anything less than -10 the OnPlayerDying script does not fire.
example:
Code: |
hp_limit = -20 # Negative HP limit - values up to -127 are allowed |
the player is then attacked by a creature or takes damage in some other way.
50 hitpoints combat continues
25 hitpoints combat continues
15 hitpoints combat continues
-17 hitpoints, combat continues and now you are walking around dead.
what should happen:
the player is then attacked by a creature or takes damage in some other way.
50 hitpoints combat continues
25 hitpoints combat continues
15 hitpoints combat continues
-17 hitpoints, combat continues and the OnPlayerDying script should fire causing you to do what is in the script (bleed, stabilize, die).
I can reproduce this bug always.
you can see it for yourself if you contact me on the nwvault irc channel, i can demonstrate it on twitch.tv
|
|
Back to top |
|
|
MetaPhaze
Joined: 03 Jun 2007 Posts: 30 Location: USA
|
Posted: Tue Jan 17, 2017 18:50 Post subject: |
|
|
Quote: | <20Zebranky18> char *pIsPCDyingPatch = (char *)0x081d5511;
[10:30:05] 18<20Zebranky18> d_enable_write((dword) pIsPCDyingPatch);
[10:30:05] 18<20Zebranky18> *pIsPCDyingPatch = hpLimit;
[10:30:10] 18<22nwvault18> <niv> there, something like this: https://gist.github.com/niv/380338f7dad0d0f06656ed766a746d8f
[10:30:41] 18<20Zebranky18> I mean, sure, if you want to do it properly
[10:31:26] 18<20Zebranky18> But throw in those three lines immediately after FixesHooks.cpp:421 and it should do the trick |
This seems to work (zebranky's fix)
putting it through more testing. |
|
Back to top |
|
|
MetaPhaze
Joined: 03 Jun 2007 Posts: 30 Location: USA
|
Posted: Mon Apr 16, 2018 6:32 Post subject: |
|
|
This was working fine, then I did a git pull, seems someone has messed it up again. Compiling with GCC 6.4.0 works, but when you load the server up it will crash with the only debug message as oShutting downo
I used my copy of FixesHooks.cpp and it compiled and runs fine.
Something funky going on in that file on git. |
|
Back to top |
|
|
|