playMaker

Author Topic: Trigger still active after object is destroyed in it. [SOLVED]  (Read 2096 times)

bobbers

  • Playmaker Newbie
  • *
  • Posts: 3
Hello, I have been stuck on this for sometime now, and it's probably due to my newness to this sorta thing in general.  I have an object that falls into a trigger area occasionally, it does what it's suppose to and activates just fine and deactivates the trigger when it rolls out which is great.  In some cases though, the object will be destroyed by bombs and the trigger will still be active if destroyed in the trigger box. I get that since it doesn't leave the trigger area it has no way of understanding it's not there anymore my only question is, how to I setup the object itself or the trigger to see that it is indeed gone? Thanks in advance for any help on this.
« Last Edit: June 17, 2015, 11:16:56 AM by bobbers »

bobbers

  • Playmaker Newbie
  • *
  • Posts: 3
Re: Trigger still active after object is destroyed in it.
« Reply #1 on: June 15, 2015, 08:56:30 PM »
Small update to this, tried instead of destroying the object, hiding it instead when the blast hits in hopes it would still detect the object flying out and no luck on that, same effect.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: Trigger still active after object is destroyed in it.
« Reply #2 on: June 16, 2015, 05:43:47 AM »
not sure if this is the good way to go but try this :

on the state with "on trigger exit" add a bool true.

then make a global bool (name it ObjDestroyed or something)

then on the destroyed trigger box let is set that bool to true.

on the next state with "on trigger exit" set bool back to false

don't forget to set every frame :)

Greetings,

Dino

bobbers

  • Playmaker Newbie
  • *
  • Posts: 3
Re: Trigger still active after object is destroyed in it.
« Reply #3 on: June 16, 2015, 09:49:20 PM »
This is fantastic, thank you! worked beautifully =)

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: Trigger still active after object is destroyed in it.
« Reply #4 on: June 17, 2015, 05:41:33 AM »
Great to hear that!

Can you please add [SOLVED] to your topic :)