Jump to content

What are the Position objects x y z readout in?


DoctorNo

Recommended Posts

Project: I'm looking to create fire effect from dropping napalm. (teaser sample below)
I cannot figure out what the the values are in.
what is unitpos.x.z  and unitpos.x.x mean? is this the x value in accordance to x plane?
As far as the negative value ... should I just assume velocity and some others should just be absolute value?
What is the x, y, z values associated to? I assumed environment grid coords that we routinely convert lat, long to x,y.
Problem is it doesn't seem to change much when I change it's location so I'm not sure what it's correlated to.
What does get unit:getPosition() then?
So i have time t, position (x, y, z) ... where z is height, heading in -pi to pi radians?, pitch in angle for x.y
quadratic equation, y = -9.81x^2 + height

position_hoggit.png

High Alt.png

Mid Alt.png

Low Alt.png

drop_diagram.png

fireball.png


Edited by DoctorNo
Adding in more detail
Link to comment
Share on other sites

 
Here are my final equations that I'll try, just posting this in case someone wants to chime in that it should be different. I'll test it anyway.
---------------------------------------------------------------------- (edited)
 
Napalm Bomb Impact Calculation: Math Complexity: Quadratic Function, Basic Algebra, Geometry
Main Problem:
Known:
drop_position x1, y1, z1, t1
drop_height = z1
drop_time = t1
drop_velocity x1, y1, z1

Desired: impact_position = x2, y2, z2
 
Final Calculated: (broken into x, y, z components)
x2 = x1pos + x1vel(t2-t1)
y2 = y1pos + y1vel(t2-t1)
z2 = (-9.81)(t2-t1)^2 + z1vel*(t2-t1) + z1

Note: -9.81 is gravity m/s^2 ... we need grid units...
- due to this, we need to conduct a true experiment with only 1 unknown variable ... gravity in grid units.
- let's setup an experiment, drop smallest bomb possible and accurately hit a target.
With this we will get drop event (x1, y1, z1) and additional hit event for the ground unit (x2, y2, z2).
- let's deal with wind and other factors later

Side Problem:
Known: Solve for g --> gravity in grid units
z2 = (g)t^2 + z1vel(t2-t1) + z1
g = ((z2 - z1) - z1vel(t2-t1)) / ((t2-t1)^2)
Now plug g back in to Final Calculated above and solve for x2, y2, z2
------------------------------------------------------------------------
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...