Jump to content

HaerDalis's death variable and reloading


Kulyok

Recommended Posts

(Note: I've googled it and searched G3, but I haven't found anything, unfortunately).

 

I'm testing some stuff for Haer'Dalis at the moment, and I've run into an unexpected bug. I had to rewrite all my area scripts, but I'm still not sure I'm immune to it. All right, here goes:

 

Any conditions with "HaerDalis", like InParty("HaerDalis") sometimes do not trigger. It can be a block for an area script with an InParty("HaerDalis"), it can be a dialogue state transition with the same condition. However, when I reload a quicksave, ta-da! The area script immediately works, the extra dialogue line runs smoothly, and everything's nice and cosy. Except you can't make the player reload every minute.

 

I'm not sure how to get rid of the thing. Patching Haer'Dalis' variable to a legal 8-symbol "Haerdali" seems way overboard. Why does it happen, anyway? I've no other mods installed except for Widescreen. Has anybody ever encountered such an issue? Maybe Fixpack or Tobex?

 

I'm not crazy, my mother had me tested.

Link to comment

Okay, code examples:

 

Dialogue:

 

CHAIN IF WEIGHT #-1 ~Global("O#UBHaerDalisInnocentBadGuy","GLOBAL",1)~ THEN O#HAJAN j1

~You! The one who's gotten the bard out of jail! You really shouldn't have done that!~

END

IF ~~ EXTERN O#HAJAN j1.1

IF ~InParty("HaerDalis")~ EXTERN O#HAJAN j1.2

 

CHAIN O#HAJAN j1.1

~I'd taken his face, and today I would take your life! Now the real fun begins!~

DO ~SetGlobal("O#UBHaerDalisInnocentBadGuy","GLOBAL",2) Enemy()~

EXIT

 

CHAIN O#HAJAN j1.2

~And you have brought the bard with you. Too bad for you, I say!~

END

IF ~~ DO ~SetGlobal("O#UBHaerDalisJanosSaw","GLOBAL",1)~ EXTERN O#HAJAN j1.1

 

Test 1: Haer'Dalis was in party, but O#HAJAN j1.2 didn't show.

Test 2(reloading a previous quicksave, same everything): O#HAJAN j1.2 shows immediately.

 

Area script(I had to take InParty("Haerdalis") out eventually):

 

IF

InParty("Haerdalis")

Global("O#UBHaerDalisInnocentTalk","GLOBAL",1)

Global("O#UBHaerDalisInnocentBadGuy","GLOBAL",0)

THEN

RESPONSE #100

ActionOverride("HAPIP",DestroySelf())

CreateCreature("O#HAJAN",[301.408],14)

SetGlobal("O#UBHaerDalisInnocentBadGuy","GLOBAL",1)

Continue()

END

 

I went inside AR0506 and nearly had a heart attack - nothing happened. I went around, tried the console, checked the variables - nothing. Finally, I quicksaved, exited, loaded that save again - the block triggered immediately.

 

It can be anything, but HaerDalis' condition seems rather suspicious to me.

Link to comment

Script names are not limited to 8 characters (they are limited to 32 characters), so that's not it.

Yep, but at a practical level you need to keep them to 18 so that SPRITE_IS_DEADfoo won't exceed the 32-character var name limit.

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...