jastey Posted March 24, 2019 Share Posted March 24, 2019 Kulyok's Assassinations is using Time(xx) for trigger of a certain event: talk to the barkeep at the right time and you get the next clue. My problem: inside the barkeep's dialogue, the trigger does not give true, but inside a script it does. This is what I am using for testing purposes: Addition to the barkeep's dialogue. If I talk to him, the "It is not time" answer shows. Global("O#CrLynnQuestSpawn1","GLOBAL",0) is at "0". The dialogues are correctly connected, the "It is not time" is the O#CrMithrest1.2: EXTEND_BOTTOM WINNKEEP 0 + ~Global("O#CrLynnQuestSpawn1","GLOBAL",0) Global("O#CrLynnQuest","GLOBAL",1) OR(7) Time(18) Time(19) Time(20) Time(21) Time(22) Time(23) TimeOfDay(NIGHT)~ + @797 EXTERN WINNKEEP O#CrMithrest1.1 // "It is time" + ~!Time(18) !Time(19) !Time(20) !Time(21) !Time(22) !Time(23) !TimeOfDay(NIGHT) Global("O#CrLynnQuest","GLOBAL",1) GlobalLT("O#CrLynnQuestSpawn1","GLOBAL",2)~ + @797 DO ~SetGlobal("O#CrLynnQuestSpawn1_Add","GLOBAL",1)~ EXTERN WINNKEEP O#CrMithrest1.2 //"It is not time" (...) END This I added to the area script for testing purposes. The ~It is time!~ DisplayStringHead shows even before I talk to the barkeep - who tells me "It is not time". IF Global("xxxTestTestTest","MYAREA",0) OR(7) Time(18) Time(19) Time(20) Time(21) Time(22) Time(23) TimeOfDay(NIGHT) InMyArea(Player1) THEN RESPONSE #100 SetGlobal("xxxTestTestTest","MYAREA",1) DisplayStringHead(Player1,~It is time!~) END So, either I am missing something plain obvious and am up for a pacepalm. Or the trigger Time() does funky stuff? Can anyone help me with this? Quote Link to comment
lynx Posted March 24, 2019 Share Posted March 24, 2019 to do a proper test, use the exact same code. You're missing the two global checks. Quote Link to comment
jastey Posted March 25, 2019 Author Share Posted March 25, 2019 11 hours ago, lynx said: to do a proper test, use the exact same code. You're missing the two global checks. True, but that still doesn't explain why in the script and the dialogue the exact opposite triggers give true. (Just for the record: I did check the two global variables ingame via cheats.) I would understand if the script would work and the reply option in the dialogue wouldn't show or something. But the way it was - script detects the time, dialogue reply option triggers detect it is not time - is a bit confusing. FWIW, I helped myself by moving the "it is time" detection into the area script and using a custom variable in the dialogue. Still, I can't explain the opposed behavior of script and dialogue triggers. Quote Link to comment
lynx Posted March 25, 2019 Share Posted March 25, 2019 Checking via cheats is no good — the values could have changed. When unexpected things happen, don't rule out other unexpected things. Quote Link to comment
Recommended Posts
Join the conversation
You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.