Jump to content

Resizing trigger box stops script from firing.


Recommended Posts

May not be relevant, but I've just had an issue after adding trigger boxes to a cell. In my case, though the triggers still worked, but I got Roombound missing textures that weren't there before.

 

I knew what I'd added after the last test, so I duplicated the triggers and sat both of them close together but neither crossing the roombound. Hey Presto, Roombound working fine again!

 

I'll look at the vid now... should have done that first!

 

Edit: just looked it. Given that I didn't think a roombound might be responsible for my problem, maybe the issue is the cell border.

 

Edit 2: I've just looked at Riverwood and they have massive triggers crossing more than one border. Same in Whiterun.

Link to comment
Share on other sites

I'm clueless. Just for the fun of it, after moving it, re-open the reference record and confirm that the script and all its properties are filled. I know they should be but the CK can be fickle sometimes and might have "forgotten" something in the move / resize process. No need to post a video if it doesn't work. Just inform whether or not it had an affect.

 

I suppose you can always try a brand new trigger box at the appropriate size and place before adding the script.

Link to comment
Share on other sites

IsharaMeradin, don't worry, I'm equally clueless!

 

About all I can think of now is that the test saves may be affected, if they're not clean, but I've never had an issue with this just by re-sizing a trigger, other than the weird roombound issue that I mentioned. Isn't CK and Skyrim wonderful? It keeps us all guessing, even after all this time.

Link to comment
Share on other sites

It was script related, I think . If the bool property SelfDel is set to TRUE, script won't fire. But this doesn't explain why when I first made the box and script with bool set to TRUE is worked but after resizing or moving the box having the bool set to TRUE stops it working. Now I need a different method so that the script only fires once.

 

Bool property SelfDel = False Auto
Event OnTriggerEnter(ObjectReference akActionRef)
if akActionRef == PlayerRef
;debug.notification("Triggered")
xMarkerSpell.placeAtMe(MyMagFX)
xMarkerSpell.placeAtMe(MyFX)
xMarkerSpell.placeAtMe(myFXShader)
Utility.Wait(Delay)
EnObj1.Enable()
MySND.Play(SNDHere)
endif
If SelfDel == True
Self.Disable(0)
Utility.Wait(0.5)
Self.Delete()
EndIf
ENDEVENT
Link to comment
Share on other sites

It does explain it if you used the same save to test. Not saying that you did, but changing properties in any script invalidates a save.

 

I learned this the hard way. If you're testing on a clean save after altering script properties, then forget this.

Link to comment
Share on other sites

Using a save to test a mod is... well it doesn't make any sense. I never make a save in a mod, it would make debugging a script/quest impossible. Looking back at the script I posted I think the part in yellow should be moved up. Consequence of copying and pasting parts of one script to another. Again... I may be wrong... again.

Link to comment
Share on other sites

In the end I went with this...

 

auto state waiting

 

Event OnTriggerEnter(ObjectReference akActionRef)

if akActionRef == PlayerRef

GotoState("Busy")

xMarkerSpell.placeAtMe(MyMagFX)

xMarkerSpell.placeAtMe(MyFX)

xMarkerSpell.placeAtMe(myFXShader)

Utility.Wait(Delay)

EnObj1.Enable()

MySND.Play(SNDHere)

GoToState("Done")

 

EndIf

ENDEVENT

ENDSTATE

 

Thanks for your help guys.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...