Raised This Month: $ Target: $400
 0% 

[FIX] Plugin box help me


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
fatalerror23
Member
Join Date: May 2011
Old 09-12-2012 , 18:54   [FIX] Plugin box help me
Reply With Quote #1

PHP Code:
#include <amxmodx> 
#include <cstrike> 
 
#define PLUGIN "EvL.G | Esconde [NEW]" 
#define VERSION "0.1" 
#define AUTHOR "Smurff Edited : FaTaL" 
 
new iFFiHandler
new time_s
 
public plugin_init() { 
register_plugin(PLUGINVERSIONAUTHOR
iFF get_cvar_pointer"sv_gravity" )
 
iHandler get_pcvar_numiFF 
 
register_clcmd"say /esconde""cmdBox""hudmensage" )

 
public 
cmdBoxid ) { 
if( !
is_user_connectedid ) || !is_user_aliveid ) || cs_get_user_teamid ) != CS_TEAM_CT ) { 
return 
PLUGIN_HANDLED 

 
switch( 
iHandler ) { 
case 
0: { 
server_cmd"sv_gravity 100" 
server_cmd"amx_lights b" )
set_hudmessage(02550, -1.00.2506.012.0
show_hudmessage(id"[ EvL.G ] Esconde Ativado"

case 
1: { 
server_cmd"sv_gravity 800" 
server_cmd"amx_lights off" )
set_hudmessage(25500, -1.00.2506.012.0
show_hudmessage(id"[ EvL.G ] Esconde Desativado"

}

public 
hudmensage()
{
    
set_task(1.0"test_countdown")
    
time_s 60
}

public 
test_countdown()

    
set_hudmessage(02550, -1.00.2820.021.00.010.110); 
    
show_hudmessage(0"[ EvL.G ] Segundos para Esconde %i"time_s); 
    --
time_s;

    if(
time_s >= 1)
    {
        
set_task(1.0"test_countdown")
}

iHandler = !iHandler 
 
return PLUGIN_CONTINUE 

have errors resolve please
fatalerror23 is offline
Liverwiz
Veteran Member
Join Date: Feb 2010
Location: Maryland
Old 09-12-2012 , 19:39   Re: [FIX] Plugin box help me
Reply With Quote #2

how many times are people going to post. "here's my code. It has errors. Fix it" while we respond "what are the errors"

Question: how the hell are we supposed to "fix" your code if you DON'T KNOW WHATS BROKEN!?
</rant>

1 error is you need to close your cmdBox's function brackets.
You might see this if you USED WHITESPACE!
__________________
What an elegant solution to a problem that doesn't need solving....

Last edited by Liverwiz; 09-12-2012 at 19:42.
Liverwiz 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:14.


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