edited January 2020 in ORK Scripting
Hi GIL,

Is it possible to stop an Ork Event (with Re-enable) that is currently running in a scene using a C# script?
Because I want to call this event later again in the same scene whenever I need it.

I tried deactivating and destroying the object containing the event but there was a gap that can't fit my need.
I want to stop an Ork Event (with reenable) and keep that object still in the scene and then later start that event again whenever I want.

Your help would be highly appreciated.

Thanks in advance.
Post edited by bomobee on
  • edited January 2020
    I think your best option is to use a variable condition in your Event Interaction to prevent the event from starting (again). Using Repeat Event will continue to check the conditions and start the event again when the condition's are valid.
    Post edited by gamingislove on
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • edited January 2020
    OK, I will try and see the result.

    Thanks.
    Post edited by bomobee on
  • I tried variable condition in the event interaction.

    If I untick the Auto Destroy then I also can't use the Repeat Check in the Variable condition too.
    This gives result of not restarting the event at all.

    However, to use repeat check I must firstly tick the box of Auto Destroy.
    Then if the variable is not true, the object will be destroyed.
    Then when the variable set back to True, how can I restart that event?
    Because the object already destroyed earlier.

    Please kindly advise.

    Thanks.
  • Disable Auto Destroy in the variable conditions, as that's not what you need.

    You should enable Repeat Event in the Event Settings of the event interaction to repeat the execution - checking the variable conditions happens automatically when the repeated execution tries to start the event.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Got it to work now.
    I accidentally ticked the box of Check Object Variables, now just unticked it works as per your advice.

    Thank you so much for your help.
  • That's what I'm here for :)
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.