Raised This Month: $ Target: $400
 0% 

Plugin Run Once and Stop(PLUGIN_) See 3rd post


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
stax
New Member
Join Date: Jul 2005
Location: Canada, Quebec
Old 04-17-2006 , 12:56  
Reply With Quote #4

Thanks a lot guys, I will test it
--------------------------------------------------------------------------------------
It don't work on AMXX V 1.01 !!!! Can someone please help me (again)
--------------------------------------------------------------------------------------

Fixed...But I still have a problem lol !

I need aName to be in quotes...eg : (in server console) amx_destroymoney "Player Name" 20

Anyway...this is the line :

Code:
server_cmd("amx_destroymoney %s %i",aName,CASHLOST)

--------------------------------------------------------------------------------------

NVM...Fixed...But, now, it only run once and stop !
This is my script :

Code:
#include <amxmodx>   #include <amxmisc>   #define CASHLOST 20    // How much cash player loses when he dies for the first time new gDeaths[32] public plugin_init() {     register_plugin("DieSetCash","0.1","Sandurr And Stax")     register_event("DeathMsg","death_event","a") } public client_putinserver(id)     gDeaths[id-1] = 0 public death_event() {     new id = read_data(2), aName[32]     if(gDeaths[id-1] == 0)     {         gDeaths[id-1]++         get_user_name(id,aName,sizeof(aName))         log_amx("Player %s Died and lost $%i Cash!",aName,CASHLOST)         server_cmd("amx_destroymoney ^"%s^" %i",aName,CASHLOST)         client_print(id,print_chat,"[AMXX] Oh Dear, You died and lost $%i to pay the city to bury your bones!^n",CASHLOST)     return PLUGIN_CONTINUE;     }     return PLUGIN_CONTINUE; }
__________________

§Ŧ@X
stax 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 04:59.


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