Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: hide on March 08, 2014, 10:49:35 AM

Title: [SOLVED] Can't make trigger/collision working
Post by: hide on March 08, 2014, 10:49:35 AM
Hello there  :)
It's been like 2 years since i've stopped using unity+playmaker because of this problem, I hope you'll be able to help me.

I made a very simple shoot-em-up with a player that can shoot missiles, some enemies and enemies that drop bonuses. But I can't make collisions nor triggers working between the player and the bonuses. I tried everything but it never worked... It's never going in the secondary state.
Here's two options I tried, maybe someone can tell what's wrong :
- Trigger event in the player object :
(http://i.imgur.com/J79f8R2l.png) (http://i.imgur.com/J79f8R2.png)

- (currently disabled FSM) collision event in the bonus object (also tried with a trigger but disabled the event in case it had interfered with the first option):
(http://i.imgur.com/uRKQfRnl.png) (http://i.imgur.com/uRKQfRn.png)
(remove the l before .png for original size image)

Note i'm using the Playmaker student edition coming with the skillshare tutorial (http://www.skillshare.com/classes/technology/Play-Make-Your-First-Video-Game-in-4-Weeks-from-Scratch-with-Unity-no-coding/2085331358).
Thanks.
Title: Re: Can't make trigger/collision working
Post by: blackant on March 08, 2014, 02:03:35 PM
did you tried to use a child object for your player trigger?
Title: Re: Can't make trigger/collision working
Post by: jeanfabre on March 11, 2014, 07:41:56 AM
Hi,
 
can you make the screenshot of a higher resolution, I can't read any thing unfortunatly.

bye,

 Jean
Title: Re: Can't make trigger/collision working
Post by: hide on March 12, 2014, 09:36:22 AM
Sorry, the links are correct but it's still showing small screens :/
Here are the big screens :
screen1 (http://i.imgur.com/J79f8R2.png)
screen2 (http://i.imgur.com/uRKQfRn.png)
Title: Re: Can't make trigger/collision working
Post by: Bqlqzs on March 13, 2014, 12:30:55 PM
First, the second image is a correct usage for states, because you cant use FINISHED translate for trigger/collider event, cause it will be auto finish and jump for the next state and I think it will be loop fail..!

The second image is I think good setup, but:
the triggers and colliders, I think not work, if you manually move the object with editor arrows!, only work if the object move with translate or force, ect..

the second:
if you try this setup and dont move the object, you picked "ENTER" collision/trigger, but your object is in rigger/collider, so dont will be work, just if you selected STAY in collider/trigger...
Title: Re: Can't make trigger/collision working
Post by: hide on March 13, 2014, 01:35:33 PM
I assume you're referring to the first screen on your first paragraph, so i set the collision like this :
(http://i.imgur.com/XMsYlJf.png)

On the second image it was only a paused game using translate with keys for the player movement and no movement for the yellow ball.

Lastly I tried with a STAY collision, still no sucess.

It may have to do with the unity setup because I tried a lot of options and never got working collision with these two object.
Title: Re: Can't make trigger/collision working
Post by: jeanfabre on March 18, 2014, 10:05:27 AM
Hi,

 -- do they feature a rigidbody component?
 -- is the rigidbody component set to isKinematic?
-- does it really have the tag you expect ( bonus)
-- is it actually set to is trigger or not? a collision is NOT a trigger, and it's only down to a check box, so watch out here as well.

bye,

 Jean
Title: Re: Can't make trigger/collision working
Post by: hide on March 23, 2014, 07:02:47 AM
I've remade it from scratch with a rigidbody on each set to isKinematic with the collider set to trigger and it work.  :)

Thanks everybody.