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

Speed?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
sumguy14
Senior Member
Join Date: Apr 2006
Old 08-18-2007 , 14:25   Speed?
Reply With Quote #1

Anybody know how to set the maxspeed of a player?
I'm not talking about m_flLaggedPlayerMovemented (or w/e its called)
I'm talking about the maxspeed, like in ZombieMod, it sets their speed, but doesn't effect how fast the fall, or anything but the player's speed.
__________________
Don't think of them as bugs think of them as unexpected features
sumguy14 is offline
Peoples Army
SourceMod Donor
Join Date: Mar 2007
Old 08-18-2007 , 16:31   Re: Speed?
Reply With Quote #2

here you go

Code:
 
 
-Member: m_flMaxspeed (offset 3160)
Peoples Army is offline
sumguy14
Senior Member
Join Date: Apr 2006
Old 08-18-2007 , 17:17   Re: Speed?
Reply With Quote #3

Tried that. No luck
__________________
Don't think of them as bugs think of them as unexpected features
sumguy14 is offline
Peoples Army
SourceMod Donor
Join Date: Mar 2007
Old 08-18-2007 , 18:03   Re: Speed?
Reply With Quote #4

can i see your code ?
Peoples Army is offline
sumguy14
Senior Member
Join Date: Apr 2006
Old 08-18-2007 , 20:03   Re: Speed?
Reply With Quote #5

I erased it.

But I found the offset with FindSendOffsProp("CCSPlayer","m_flMaxSpeed")

And set it with

Code:
SetEntDataFloat(client,offsetvariable,400.0,true);
__________________
Don't think of them as bugs think of them as unexpected features
sumguy14 is offline
sumguy14
Senior Member
Join Date: Apr 2006
Old 08-18-2007 , 20:05   Re: Speed?
Reply With Quote #6

Maybe I didn't erase it:

Code:
MaxSpeedOffset=FindSendPropOffs("CCSPlayer","m_flMaxspeed");
  if(MaxSpeedOffset==-1)
    SetFailState("Error: Couldn't find the MaxSpeed offset, aborting");
Code:
SetSpeed(client,Float:speed)
{
  SetEntDataFloat(client,MaxSpeedOffset,speed,true);
}
Code:
SetSpeed(client,400.0);
__________________
Don't think of them as bugs think of them as unexpected features
sumguy14 is offline
Peoples Army
SourceMod Donor
Join Date: Mar 2007
Old 08-18-2007 , 21:59   Re: Speed?
Reply With Quote #7

i would try using

Code:
 
SetEntPropFloat(ent,Prop_Data,string,value);
if that doesnt work try it with Prop_Send
Peoples Army is offline
sumguy14
Senior Member
Join Date: Apr 2006
Old 08-18-2007 , 23:45   Re: Speed?
Reply With Quote #8

That native isn't made for offsets. That's for entity properties like m_iHealth, or m_flGravity.

Hence SetEntPropFloat
__________________
Don't think of them as bugs think of them as unexpected features
sumguy14 is offline
sumguy14
Senior Member
Join Date: Apr 2006
Old 08-19-2007 , 00:16   Re: Speed?
Reply With Quote #9

Well I found the problem.

It doesn't want to stay at the value I set it to.
A tick later it gets set back to somewhere in the range of 220.0-270.0 depening on your weapon.

Valve must use this property for setting speed in relation to what weapon you have out (awp makes you walk slow, knife, faster)

So this probably isn't the offset I'm looking for.
__________________
Don't think of them as bugs think of them as unexpected features
sumguy14 is offline
Shaman
Senior Member
Join Date: Dec 2006
Location: Istanbul, Turkey
Old 08-19-2007 , 07:29   Re: Speed?
Reply With Quote #10

Try these:
m_flMaxspeed
m_flStepSize
__________________
Shaman is offline
Send a message via ICQ to Shaman Send a message via AIM to Shaman Send a message via MSN to Shaman Send a message via Yahoo to Shaman
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 17:54.


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