playMaker

Author Topic: Add Explosion Force Falloff Question  (Read 2864 times)

crush

  • Playmaker Newbie
  • *
  • Posts: 24
Add Explosion Force Falloff Question
« on: June 24, 2015, 01:40:43 PM »
Hi,
I have a 3rd person character run towards a ball, using mouse button down to go to the next state to then add explosion force to "kick" the ball.
It works perfectly the first time. Then I chase after the ball,
The second time it works only slightly and then the 3rd time and after that no reaction at all. Not sure why this is happening?

I have tested with all different settings, different physics materials also for all surfaces and meshes, used add force, explosion, add explosion force etc.. still same result with each combination. A gradual decrease in the power of the force.

Maybe there is another way to do this also?
Thanks for any help.

phannDOTde

  • Full Member
  • ***
  • Posts: 237
    • Peter Hann .de
Re: Add Explosion Force Falloff Question
« Reply #1 on: June 24, 2015, 01:52:00 PM »
Maybe you are adding the force from the scenes Centerpoint and as the ball moves away from that point it doesn't get affected anymore? Just a wild guess :-)

crush

  • Playmaker Newbie
  • *
  • Posts: 24
Re: Add Explosion Force Falloff Question
« Reply #2 on: June 24, 2015, 02:04:49 PM »
Hey, yes I was thinking the same thing also. I couldn't find a way / option to set the ball as the center point, use it's transform. also tried adding the force on the player and also on the ball and combinations of both etc all with the same results.
« Last Edit: June 24, 2015, 02:39:00 PM by crush »

phannDOTde

  • Full Member
  • ***
  • Posts: 237
    • Peter Hann .de
Re: Add Explosion Force Falloff Question
« Reply #3 on: June 25, 2015, 06:15:12 AM »
You can use the contactpoint or the position of an "dummy" gameobject you could put at the foot as an reference for "Add Force". Using "position AND dir Vector

terri

  • Sr. Member
  • ****
  • Posts: 386
    • terrivellmann.tumblr.com
Re: Add Explosion Force Falloff Question
« Reply #4 on: June 25, 2015, 09:13:20 AM »
Set a GameObject variable as the ball and add force to that?

Like this (I guess you'd have the 150 at the Z so it goes forward)

phannDOTde

  • Full Member
  • ***
  • Posts: 237
    • Peter Hann .de
Re: Add Explosion Force Falloff Question
« Reply #5 on: June 25, 2015, 02:02:57 PM »
try position 0,0,0 because now the force is applied from the worlds center if I'm not mistaken - or use "get position" first to figure out where the balls position in the world is
« Last Edit: June 25, 2015, 02:20:11 PM by phannDOTde »

crush

  • Playmaker Newbie
  • *
  • Posts: 24
Re: Add Explosion Force Falloff Question
« Reply #6 on: June 30, 2015, 07:55:04 PM »
Hey, thank you guys for the help, this worked perfectly for some things I was trying to do.