Java-Gaming.org
 Featured games (81) games approved by the League of Dukes Games in Showcase (497) Games in Android Showcase (114) games submitted by our members Games in WIP (563) games currently in development
 News: Read the Java Gaming Resources, or peek at the official Java tutorials
Pages: [1]
 ignore  |  Print
 How to calculate a missles flight path? Splines?  (Read 4117 times) 0 Members and 1 Guest are viewing this topic.

Innocent Bystander

 « Posted 2010-04-08 15:14:10 »

Hallo

I am currently making a Java3D game. In this game thera are missles from which I know the start point, the endpoint and the angle at the start point. In a physics book I found a fromula to calculate the flight path. But in some Java3D tutorials I read something about splines which should be more efficient than calculating the current position of the missile with the physic formula.

Currently I am confused about this splines. For what I understand I need some points and a spline interpolates the points between the points I know. Can I just calculate some points of the flight path with the formula and then interpolate the flight path with a spline function?
Riven
« League of Dukes »

JGO Overlord

Medals: 799
Projects: 4
Exp: 16 years

 « Reply #1 - Posted 2010-04-08 16:37:22 »

Splines can only be used in very few cases.
They are almost unusable for any simulation.

Just use your physically correct formulas, I doubt it will hurt performance, unless you launch thousands of missiles.

Hi, appreciate more people! Σ ♥ = ¾
Learn how to award medals... and work your way up the social rankings
moogie

JGO Knight

Medals: 12
Projects: 6
Exp: 10 years

Java games rock!

 « Reply #2 - Posted 2010-04-08 21:05:45 »

perhaps pursuit steering behavior would be sufficient?

http://www.red3d.com/cwr/papers/1999/gdc99steer.html

just extend it to 3d
Ranger
 « Reply #3 - Posted 2010-04-10 21:22:00 »

Easiest way I found was to give the missile thrust, and then steer it left and right.  To work out the path, just iterate forward in time.
Pages: [1]
 ignore  |  Print

You cannot reply to this message, because it is very, very old.

 Add your game by posting it in the WIP section, or publish it in Showcase. The first screenshot will be displayed as a thumbnail.
 BurntPizza (24 views) 2014-09-19 03:14:18 Dwinin (39 views) 2014-09-12 09:08:26 Norakomi (67 views) 2014-09-10 13:57:51 TehJavaDev (93 views) 2014-09-10 06:39:09 Tekkerue (47 views) 2014-09-09 02:24:56 mitcheeb (68 views) 2014-09-08 06:06:29 BurntPizza (51 views) 2014-09-07 01:13:42 Longarmx (38 views) 2014-09-07 01:12:14 Longarmx (44 views) 2014-09-07 01:11:22 Longarmx (40 views) 2014-09-07 01:10:19
 BurntPizza 37x Riven 18x Rayvolution 18x ags1 16x princec 16x basil_ 16x KevinWorkman 15x LiquidNitrogen 12x kevglass 12x theagentd 11x nsigma 11x deathpat 10x HeroesGraveDev 9x The Lion King 7x Gibbo3771 6x cylab 6x
 List of Learning Resources2014-08-16 10:40:00List of Learning Resources2014-08-05 19:33:27Resources for WIP games2014-08-01 16:20:17Resources for WIP games2014-08-01 16:19:50List of Learning Resources2014-07-31 16:29:50List of Learning Resources2014-07-31 16:26:06List of Learning Resources2014-07-31 11:54:12HotSpot Optionsby dleskov2014-07-08 01:59:08
 java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org