Raised This Month: $ Target: $400
 0% 

My second script. Need some help


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
XunTric
BANNED
Join Date: Jan 2005
Location: Norway/Norge
Old 02-04-2005 , 18:00  
Reply With Quote #4

Thanks guys it almost works! It compiles and the command work. But the command only make you llama and changes your name. It doesnt make you to a chicken. Any ideas how to fix it? Just as you know i used what XxAvalanchexX said. Its maybe because i get those warnings when i compile? When i compile i get this:

//// amx_mess.sma
// D:Spill/Steam/SteamApps/My@Mail(Secret )/detiacted server/cstrike/addons/amxmodx/scripting/amx_mess.sma <30> : warning 217: loose indentation
// D:Spill/Steam/SteamApps/My@Mail(Secret )/detiacted server/cstrike/addons/amxmodx/scripting/amx_mess.sma <52> : warning 217: loose indentation
//
// 2 warnings.
// Done.

And can somebody help me to make amx write "*Player* has been messed up by the admins. Have fun!" on the screen when the command is used?
Well, this is what i got now:
Code:
#include <amxmodx> #include <amxmisc> public plugin_init() { register_plugin("amx_mess", "1.0", "XunTric") register_concmd("amx_mess", "cmdmess", ADMIN_KICK, "<name or #userid>") register_concmd("amx_unmess", "cmdunmess", ADMIN_KICK, "<name or #userid>") } public cmdmess(id,level,cid) {     if (!cmd_access(id,level,cid,2))          return PLUGIN_HANDLED     new arg[32]     read_argv(1,arg,31)     new player = cmd_target(id,arg,1)     if(!player)          return PLUGIN_HANDLED     new name[64];     get_user_name(player,name,63);     server_cmd("amx_llama ^"%s^"", name)     server_cmd("amx_chicken ^"%s^"", name)     server_cmd("amx_name ^"%s^" ^"DONT MESS WITH THE ADMINS^"", name)          return PLUGIN_HANDLED } public cmdunmess(id,level,cid) {         if (!cmd_access(id,level,cid,2))          return PLUGIN_HANDLED     new arg[32]     read_argv(1,arg,31)     new player = cmd_target(id,arg,1)     if(!player)          return PLUGIN_HANDLED     new name[64];     get_user_name(player,name,63);     server_cmd("amx_unllama ^"%s^"", name)     server_cmd("amx_unchicken ^"%s^"", name)     server_cmd("amx_name ^"%s^" ^"I CAN CHANGE MY NAME BACK NOW^"", name)          return PLUGIN_HANDLED }
XunTric is offline
 



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 19:21.


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