AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Weapon Prestrafe (https://forums.alliedmods.net/showthread.php?t=132248)

Ex3cuTioN 07-13-2010 07:21

Weapon Prestrafe
 
How can i calculate the max prestrafe for a weapon?

Knife's max prestrafe is 299.999 (usp,deagle) maxspeed 250.

ot_207 07-13-2010 07:39

Re: Weapon Prestrafe
 
By prestrafe you mean when you keep the W key pressed and tap fast on the D or A key?
Or the velocity that a user can get when holding W with A or D keys pressed?
I do not think that there is a formula you just need to measure the speed and compare it with the maxspeed of that weapon.

Ex3cuTioN 07-13-2010 07:41

Re: Weapon Prestrafe
 
What can you understand from this...

if((pev( id, pev_maxspeed ) * 1.2)>prestrafe[id])

EDIT :

I know now :d

try this shit 300/250=1.2

scout: 260*1.2=312

ConnorMcLeod 07-13-2010 15:35

Re: Weapon Prestrafe
 
I think it's rather an engine limitation, that when you are >= 300 consider that your speed is 250 to calculate how you gonna jump.
Let xolent answer to this because he should be documented about it :)


All times are GMT -4. The time now is 07:06.

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