Forum

Jump to targetted point

Discuss programming in the QuakeC language.

Moderator: InsideQC Admins

Jump to targetted point

Postby gastrop0d » Mon Feb 15, 2010 5:48 am

Okay, this is really melting my brain...

I've got a player position and a target location. I want to have it so you can trigger a jump from the player to the target that has a maximum speed S, and a minimum angle O.

Target location is a simple raytrace of where ever the player is aiming.

If the target is too far away, the result jump will just be a jump at speed S and angle 45 (ie the maximum possible jump distance).

The jump must always at least be at angle O.

I basically failed projectile-motion in physics class... any idea how to implement something like this? :shock:
gastrop0d
 
Posts: 5
Joined: Thu Feb 11, 2010 9:13 am

Postby frag.machine » Mon Feb 15, 2010 4:17 pm

Check the code for ogre firing grenades. It can give you some clue about how to do this jump.
I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
User avatar
frag.machine
 
Posts: 2090
Joined: Sat Nov 25, 2006 1:49 pm


Return to QuakeC Programming

Who is online

Users browsing this forum: No registered users and 1 guest