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

maxspeed + weapons


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
knekter
Senior Member
Join Date: Mar 2004
Location: PA
Old 03-21-2004 , 13:08   maxspeed + weapons
Reply With Quote #1

Right now I have a simple plugin that sets the users maxspeed to 1000, and makes him run alot faster. But the minute I change to another weapon, the speed goes away, and the user has to say /speedme again. Im not sure why, but its very annoying. Also im running cs 1.5 if that makes a difference. Why does it do this?

heres the code:

Code:
////////////////////// #include <amxmodx> #include <amxmisc> #include <fun> ///////////////////// public plugin_init() {     register_plugin("test","0.1","ashade")     register_clcmd("say /speed","speed_me",0,": gives client speed")     register_cvar("sv_speedme","1") } public speed_me(id) {     if(get_cvar_num("sv_speedme")==1)     {         set_user_maxspeed(id,float(1000))         client_cmd(id,"cl_forwardspeed 1000")         client_cmd(id,"cl_sidespeed 1000")         client_cmd(id,"cl_backspeed 1000")     }     return PLUGIN_HANDLED }
__________________
More updates for Matrix Mod!
knekter is offline
Send a message via AIM to knekter Send a message via MSN to knekter
PM
hello, i am pm
Join Date: Jan 2004
Location: Canalization
Old 03-21-2004 , 13:23  
Reply With Quote #2

in CS, the speed changes when you change weapon (because you run slower with a para than with a mp5navy). You have to change it again in the CurWeapon event (check other plugins how they do it)..
__________________
hello, i am pm
PM is offline
knekter
Senior Member
Join Date: Mar 2004
Location: PA
Old 03-21-2004 , 15:44   alright, one thing
Reply With Quote #3

register_event("CurWeapon","weapon_switch","b e","?")

what do I put in where I have a ? mark....
__________________
More updates for Matrix Mod!
knekter is offline
Send a message via AIM to knekter Send a message via MSN to knekter
QwertyAccess
Veteran Member
Join Date: Feb 2004
Location: Enjiru Layer
Old 03-21-2004 , 22:50  
Reply With Quote #4

in cs and any other mod (most mods) if you change weapons or shoot a single bullet your speed changes.
__________________
QwertyAccess 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 00:34.


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