playMaker

Author Topic: Get Rigidbody Projectile Trajectory Prediction Points. Line Renderer Positions  (Read 3229 times)

Digitom

  • Junior Playmaker
  • **
  • Posts: 61
Hello,

I made a custom action to predict rigidbody projectiles into a Vector3 FSMArray.
Also made a custom action to set line renderer points based on a vector3 FSMArray.

Useful for angry bird type games or previewing grenade throws and stuff like that. Feel free to add this to the ecosystem!



cel

  • Full Member
  • ***
  • Posts: 132
this look awesome... I'll be away from my computer for a few days, so can't test it right now, but will this be able to work in a pool game? Like detect where the white ball will go? and also would it work with ramps (i was thinking of golf games) ?

Any way looks super!!

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Nice!

Digitom

  • Junior Playmaker
  • **
  • Posts: 61
this look awesome... I'll be away from my computer for a few days, so can't test it right now, but will this be able to work in a pool game? Like detect where the white ball will go? and also would it work with ramps (i was thinking of golf games) ?

Any way looks super!!

It won't detect deflections/bounces atm...or resistance of surfaces...I mayyyy add that but it introduces more room for error.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Hi.
Nice action.

At this moment i am actually trying something reversed.

Having a certain target point and set its velocity or force to reach that point (with a curve)

i will definitely have a look into the action :)

cel

  • Full Member
  • ***
  • Posts: 132
Quote
It won't detect deflections/bounces atm...or resistance of surfaces...I mayyyy add that but it introduces more room for error.

Oh, pity... I've tried the physics scene approach to simulate trajectories (collisions included) but can't wrap my head around it... maybe you could consider having a look at this,. Keep up the good work
« Last Edit: February 26, 2020, 01:20:02 PM by djaydino »

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Hi,

 check out PhysicsShoot custom action, it's very likely possible to reverse the math so that based on a position and angle of shooting, you deduce the velocity required for the projectile to hit that point.

Bye,

 Jean

pixelmator

  • Playmaker Newbie
  • *
  • Posts: 8
Does anyone have a scene/example because I'm having trouble getting this action to work. So most likely I'm not understanding this properly. Any help is appreciated.