playMaker

Author Topic: Collision issue when moving object with "Translate" action [SOLVED]  (Read 3957 times)

app_advisory

  • Junior Playmaker
  • **
  • Posts: 80
    • App Advisory
Hi,

I don't know why, but when I move my sphere continuously with a translation, the sphere enter a little bit inside a wall when there is a contact between the sphere and a wall..

I attached a little video, and my FSM and the inspector of my sphere.

Thank you very much for your help ...

Regards,

Anthony


my FSM : https://www.dropbox.com/s/nvohgkdvq5rd9pd/Capture%20d%E2%80%99%C3%A9cran%202014-06-12%20%C3%A0%2012.51.04.png

Inspector : https://www.dropbox.com/s/1ec3numdfx33lbp/Capture%20d%E2%80%99%C3%A9cran%202014-06-12%20%C3%A0%2012.52.15.png

Video :
https://www.dropbox.com/s/kq4nfu3t6j2mprz/tile%20collision.mp4
« Last Edit: July 04, 2014, 12:31:30 PM by Alex Chouls »

jayf

  • Playmaker Newbie
  • *
  • Posts: 40
Re: Collision issue when moving object with "Translate" action
« Reply #1 on: June 12, 2014, 10:46:56 AM »
Hi.

The first thought that came to my mind is maybe you should try increasing the radius of the Sphere's collider? Or try a cube collider? (Incase you haven't done so) Sorry I'm rather new to Playmaker myself and that's all I can think off.  ;)

app_advisory

  • Junior Playmaker
  • **
  • Posts: 80
    • App Advisory
Re: Collision issue when moving object with "Translate" action
« Reply #2 on: June 12, 2014, 10:48:14 AM »
I'm new too ;)

What's the consequence of the increase of the radius ?


app_advisory

  • Junior Playmaker
  • **
  • Posts: 80
    • App Advisory
Re: Collision issue when moving object with "Translate" action
« Reply #3 on: June 12, 2014, 10:49:27 AM »
I saw it change the "collision" surface but .. It didn't change anything

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3987
  • Official Playmaker Support
    • LinkedIn
Re: Collision issue when moving object with "Translate" action
« Reply #4 on: June 12, 2014, 07:08:04 PM »
In general you should move a Rigid Body using forces instead of Translate. Translate overrides the physics simulation causing weird behavior.

Or you could use Set Velocity to set the velocity directly.

Or use a Character Controller and Controller Move or Controller Simple Move actions.

There are pros and cons to each approach, so it would depend on the needs of your game...

jayf

  • Playmaker Newbie
  • *
  • Posts: 40
Re: Collision issue when moving object with "Translate" action
« Reply #5 on: June 12, 2014, 10:36:07 PM »
I saw it change the "collision" surface but .. It didn't change anything

Oh ok nevermind then. I keep thinking Collision has something to do with the objects physics, but Alex Chouls is right, I think you'd have to do something with the Rigid Body to solve this.

app_advisory

  • Junior Playmaker
  • **
  • Posts: 80
    • App Advisory
Re: Collision issue when moving object with "Translate" action
« Reply #6 on: June 13, 2014, 05:39:09 AM »
Hi,

You're right : set velocity is better ..

And it solves my issue thanks a lot !!