Raised This Month: $51 Target: $400
 12% 

How to get velocity by angles?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Leech_v2
Senior Member
Join Date: Mar 2011
Location: Chinese GuangDong
Old 04-28-2012 , 06:33   How to get velocity by angles?
Reply With Quote #1

↖↑↗
← →
↙↓↘

Direction ...
angle_vector can only ←→↑↓
Leech_v2 is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 04-28-2012 , 15:55   Re: How to get velocity by angles?
Reply With Quote #2

Code:
AnglesToVelocity(const Float:angles[3], Float:speed, Float:velocity[3]) {     engfunc(EngFunc_MakeVectors, angles);     global_get(glb_v_forward, velocity);         new Float:length = vector_length(velocity);         velocity[0] *= (speed / length);     velocity[1] *= (speed / length);     velocity[2] *= (speed / length); }
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
Old 04-28-2012, 16:57
ConnorMcLeod
This message has been deleted by ConnorMcLeod. Reason: meh
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 14:24.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode