Raised This Month: $ Target: $400
 0% 

Set player speed through weapon (money involved)


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Greyscale
SourceMod Plugin Approver
Join Date: Dec 2007
Location: strYoMommasHouse[you];
Old 01-31-2010 , 16:11   Set player speed through weapon (money involved)
Reply With Quote #1

I've been waiting for this to be possible with SM for a longgg time. I'd really love to be able to do this, because right now the only way to set speed is through m_flLaggedMovement. That speeds up the client but it speeds up everything else too, acceleration, fall speed, footsteps.

An extension is required to do this, there is an unofficial extension that can do it, but it's unofficial, unsupported (AFAIK), and has more than I need.

I'll toss $15-20 to whoever can make a simple, straight-forward extension that can change a client's speed through GetMaxSpeed.

I need it to use in a plugin, and to learn how it works, the other extension is clouded with other code for other features, so I can't tell whats what.

PM me if you're interested.

P.S. You'd be doing a good thing for Zombie:Reloaded
__________________
Greyscale is offline
Greyscale
SourceMod Plugin Approver
Join Date: Dec 2007
Location: strYoMommasHouse[you];
Old 01-31-2010 , 22:58   Re: Set player speed through weapon (money involved)
Reply With Quote #2

Well for anyone who needs this, I guess it's possible by setting m_flMaxSpeed on PreThink with SDKHooks.
__________________
Greyscale is offline
zond33
Member
Join Date: Mar 2008
Old 01-31-2010 , 23:34   Re: Set player speed through weapon (money involved)
Reply With Quote #3

It is possible to do this kind of plugin as a similar has been already done. The plugin that has been done changes the speed of knife.
zond33 is offline
Cooltad
Veteran Member
Join Date: Apr 2008
Old 01-31-2010 , 23:53   Re: Set player speed through weapon (money involved)
Reply With Quote #4

Yes, just use m_flmaxspeed, and a timer of 0.1, and per tick detect the weapon currently held, and then modify m_flmaxspeed based on which weapon.
__________________
Please, give me some rep if you found what I posted useful. :]
Cooltad is offline
Greyscale
SourceMod Plugin Approver
Join Date: Dec 2007
Location: strYoMommasHouse[you];
Old 02-01-2010 , 00:15   Re: Set player speed through weapon (money involved)
Reply With Quote #5

Cooltad: So the m_flMaxspeed property is on the weapon? I see

EDIT: Nope, no m_flMaxspeed property on weapons.

Setting it on clients on PreThink didn't work.

zond33: What plugin?
__________________

Last edited by Greyscale; 02-01-2010 at 00:25.
Greyscale is offline
Greyscale
SourceMod Plugin Approver
Join Date: Dec 2007
Location: strYoMommasHouse[you];
Old 02-01-2010 , 01:25   Re: Set player speed through weapon (money involved)
Reply With Quote #6

It looks like this method works for every other source game BUT CS:S. =/

Going to need that extension, again.
__________________
Greyscale is offline
psychonic

BAFFLED
Join Date: May 2008
Old 02-01-2010 , 07:41   Re: Set player speed through weapon (money involved)
Reply With Quote #7

You need to do it after PreThink, like in a post-hook on PreThink according to Sammy-ROCK! in the SDK Hooks thread. The next release of SDK Hooks will have this hooktype available.
psychonic is offline
Greyscale
SourceMod Plugin Approver
Join Date: Dec 2007
Location: strYoMommasHouse[you];
Old 02-01-2010 , 19:18   Re: Set player speed through weapon (money involved)
Reply With Quote #8

Oh, alright sounds good. Thanks
__________________
Greyscale is offline
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 08:59.


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