I wrote a script that has Thieves automatically Hide In Shadows when the player turns on stealth mode (with a hotkey.) Because hidden characters cannot be healed and leaving the shadows can take such a long time, I have the Thief initiate dialogue with himself (PlayerDialog(Myself)) when stealth mode is turned off. This instantly reveals him.
This works fine for the main character and for the NPCs that I tried it on. You get a little red "<GABBER>- has nothing to say to you" line in the text area, but that's not a big deal.
However, if you start a multiplayer game and make more than one custom character, the not-Player1 character will actually initiate dialogue and say "Why do you waste my time with idle banter?", complete with pausing the game and forcing you to click End Dialogue. It would appear that the not-Player1 characters have MULTIG.DLG assigned, which handles being kicked out of the party.
I can SetDialogue("",Myself) before initiating dialogue. This seems to work fine. However, I'm afraid it'll mess something up that I don't know about... break the game somehow. I'm not familiar with how the game handles dialogues. Is there any danger in doing this?
Any danger in SetDialogue("",Myself)?
Started by Xyx, Mar 20 2012 01:08 AM
6 replies to this topic
#1
Posted 20 March 2012 - 01:08 AM
#2
Posted 20 March 2012 - 02:53 AM
You should create a spell with effect 47 (Remove Invisibility) and call it from your script. It's much easier and doesn't have any side effects.
Using SetDialogue("",Myself) on a party member is dangerous because mods or the game itself could change it any time.
Using SetDialogue("",Myself) on a party member is dangerous because mods or the game itself could change it any time.
#3
Posted 20 March 2012 - 03:53 AM
Plus, it will break Multi-player kickout dialogues and any mods that depend on non-protagonist PCs using multig.dlg.
Must. Write. Faster.
cmorgan: "None of us get old around here, just more proficient at doing more stuff with less braincells!"
berelinde's mods
TolkienAcrossTheWater website
TolkienAcrossTheWater Forum
cmorgan: "None of us get old around here, just more proficient at doing more stuff with less braincells!"
berelinde's mods
TolkienAcrossTheWater website
TolkienAcrossTheWater Forum
#4
Posted 20 March 2012 - 04:03 AM
argent77, on 20 March 2012 - 02:53 AM, said:
You should create a spell with effect 47 (Remove Invisibility) and call it from your script. It's much easier and doesn't have any side effects.
berelinde, on 20 March 2012 - 03:53 AM, said:
Plus, it will break Multi-player kickout dialogues and any mods that depend on non-protagonist PCs using multig.dlg.
Maybe the game resets the dialogue when someone gets kicked out. Wouldn't that be necessary anyway, considering other parts of the game can call SetDialogue() as well?
Edited by Xyx, 20 March 2012 - 04:08 AM.
#5
Posted 20 March 2012 - 05:33 AM
Xyx, on 20 March 2012 - 04:03 AM, said:
I'm a bit of a purist and I wouldn't want my script to do anything that the player (or one of the default scripts) couldn't also order the character to do.
By using PlayerDialog(Myself) you're merely exploiting a side effect which works in BG2 but might work or not in GemRB or the upcoming BGEE.
#6
Posted 20 March 2012 - 06:48 AM
argent77, on 20 March 2012 - 05:33 AM, said:
The game doesn't offer many ways to make oneself noticeable at will
argent77, on 20 March 2012 - 05:33 AM, said:
By using PlayerDialog(Myself) you're merely exploiting a side effect which works in BG2 but might work or not in GemRB or the upcoming BGEE.
#7
Posted 20 March 2012 - 07:33 AM
Right... it should be SetDialogue(""), not SetDialogue("",Myself). I'd edit my first post and the topic title if I could.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users











