Raised This Month: $ Target: $400
 0% 

adding speed to player


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
rufee
Junior Member
Join Date: Aug 2008
Location: Lithuania
Old 03-03-2009 , 08:08   adding speed to player
Reply With Quote #1

How to add speed to player and remove it on the next round?
rufee is offline
padilha007
Senior Member
Join Date: Jul 2008
Old 03-03-2009 , 10:21   Re: adding speed to player
Reply With Quote #2

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>

public plugin_init()
{
    
register_plugin("Speed Mananger""0.0.1""ProjetoCs | Yokil SpyWare")
    
    
register_concmd"amx_speed""speed"ADMIN_SLAY"- <target>" );
    
    
register_event"DeathMsg",    "eDeath",    "a");
}

public 
speedidlevelcid )
{
    if( !
cmd_accessidlevelcid) )
        return 
PLUGIN_HANDLED;
    
    new 
arg32 ];
    
read_argv1arg31 );
    
    new 
target cmd_targetidarg);
    if( !
target )
        return 
PLUGIN_HANDLED;

    
set_pev(targetpev_maxspeed320.0)
    
    return 
PLUGIN_HANDLED;
}

public 
eDeath()
{
    new 
iVictim read_data)
    
set_pev(iVictimpev_maxspeed250.0)

__________________

padilha007 is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 03-03-2009 , 12:02   Re: adding speed to player
Reply With Quote #3

Maxspeed is reset on spawn so there is no need to change it.

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>

public plugin_init()
{
    
register_plugin("Speed Mananger""0.0.1""ProjetoCs | Yokil SpyWare")
    
    
register_concmd"amx_speed""speed"ADMIN_SLAY"- <target>" );
}

public 
speedidlevelcid )
{
    if( !
cmd_accessidlevelcid) )
        return 
PLUGIN_HANDLED;
    
    new 
arg32 ];
    
read_argv1arg31 );
    
    new 
target cmd_targetidarg);
    if( !
target )
        return 
PLUGIN_HANDLED;

    
set_pev(targetpev_maxspeed320.0)
    
    return 
PLUGIN_HANDLED;

__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
padilha007
Senior Member
Join Date: Jul 2008
Old 03-03-2009 , 12:22   Re: adding speed to player
Reply With Quote #4

Tnx Exolent
__________________

padilha007 is offline
AntiBots
Veteran Member
Join Date: May 2008
Location: Brazil
Old 03-03-2009 , 13:17   Re: adding speed to player
Reply With Quote #5

The MaxSpeed dont is change when change your weapon?

Example: Scout 260 change to Usp 250. ??
__________________
AntiBots is offline
Send a message via ICQ to AntiBots Send a message via MSN to AntiBots Send a message via Skype™ to AntiBots
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-03-2009 , 13:55   Re: adding speed to player
Reply With Quote #6

Quote:
Originally Posted by AntiBots View Post
The MaxSpeed dont is change when change your weapon?

Example: Scout 260 change to Usp 250. ??
Yes, maxspeed changes if you change your weapon.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
xbatista
Veteran Member
Join Date: Mar 2008
Location: Lithuania
Old 03-04-2009 , 02:45   Re: adding speed to player
Reply With Quote #7

Hmmm I've tryied it to do with Prethink and curweapon.Curweapon is buggy with speed :/ In Prethink it's normal ,but I don't wanna use Prethink,maybe someone can give good code to set speed without bugs?
xbatista is offline
Send a message via Skype™ to xbatista
anakin_cstrike
Veteran Member
Join Date: Nov 2007
Location: Romania
Old 03-04-2009 , 08:38   Re: adding speed to player
Reply With Quote #8

In my virus smoke nade i'm setting maxspeed in curweapon and it works well.
__________________

anakin_cstrike is offline
AntiBots
Veteran Member
Join Date: May 2008
Location: Brazil
Old 03-04-2009 , 08:40   Re: adding speed to player
Reply With Quote #9

show the part of your code. So we can see what do you do wrong.
__________________
AntiBots is offline
Send a message via ICQ to AntiBots Send a message via MSN to AntiBots Send a message via Skype™ to AntiBots
xbatista
Veteran Member
Join Date: Mar 2008
Location: Lithuania
Old 03-04-2009 , 08:43   Re: adding speed to player
Reply With Quote #10

When I'm shooting Speed sets to incredible speed maybe 5000.0 in cur weapon.
xbatista is offline
Send a message via Skype™ to xbatista
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:06.


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