I wasn't quite sure how to phrase the title so a little more information is required.
I have a run aground ship which is always accessible for the player to explore and later in my mod becomes a quest location. I've set up dialogue options depending on whether the player has been inside the ship before such as "I've been here before and I never saw...blah, blah". That dialogue is dependent on a global variable having a value of 1. The Global is Mod(1.0) if the player has been to the ship prior to the quest beginning, Global is incremented by player entering a triggerbox when he/she goes through the ship's door - it's an outside ship i.e. it has no separate interior cell. My brain said "Well done, this should work." What I didn't count on was that if player had not been to the ship prior to the quest and when instructed to go to the ship that he/she would pass through the triggerbox and Mod(1.0) so the dialogue will always be "I've been here before..." even though player hasn't.
What to do? I noticed a default script called OnActivateDisableSelf, I'm not sure if this would work for a OnTriggerEnter script and I'm not sure how to script it so that when player enters the triggerbox, global is incremented to 1 and then the triggerbox is gone. Here's what I scripted so far.
GlobalVariable Property HasBeenHere AutoInt Property Number Autoint DoOnceEvent OnTriggerEnter(objectreference akactionref)if DoOnce == 0if akactionref == game.getplayer()HasBeenHere.Mod(Number) as intDoOnce = 1endifendifendevent
Thanks for taking the time to read this.