[solved] velocity to a direction
I searched for this in some dodge plugins but I don't understand anything... floatabs() and all that, can anyone explain how can I set a velocity in a direction relative to player's view ?
like... I am looking forward and I want the velocity to be to my left, right, back or just forward |
Re: velocity to a direction
|
Re: velocity to a direction
Using your code I was able to make forward and backward, but left & right doesn't work right, and also with forward & backward, when I look up or down doesn't give the full throttle, is there another way ?
I could get the straight line direction PHP Code:
edit: I tried to look into velocity_by_aim's function but I don't understand anything PHP Code:
|
Re: velocity to a direction
Code:
For your situation you can do: Code:
|
Re: velocity to a direction
PHP Code:
|
Re: velocity to a direction
http://forums.alliedmods.net/showthread.php?p=88618
PHP Code:
|
Re: velocity to a direction
yep, I managed to do it just perfectly using that code connor, thanks :P
|
| All times are GMT -4. The time now is 01:37. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.