Raised This Month: $ Target: $400
 0% 

Killing Money


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
elpouletorange
Senior Member
Join Date: Oct 2007
Old 10-14-2007 , 00:26   Killing Money
Reply With Quote #1

Hi, I only want to know how can I change the money give when somebody kill someone, and too the money give after the round (if win == 3600) (if lose == 1500).

Thanks.

elpouletorange
elpouletorange is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 10-14-2007 , 07:35   Re: Killing Money
Reply With Quote #2

Try this.

Change the values '600', '2000', '1000' to what you want.

Code:
    #include <amxmodx>     #include <cstrike>     #define MAX_CLIENTS 32         new g_iOldMoney_k[ MAX_CLIENTS + 1 ];         public plugin_init()     {         register_plugin( "", "1.0", "Amxx Community" );                 register_event( "SendAudio", "eTeam_win", "a", "2=%!MRAD_terwin", "2=%!MRAD_ctwin" );         register_event( "DeathMsg" , "eDeath_Msg", "a" );         register_message( get_user_msgid( "Money" ), "message_money" );     }         public message_money( msg_id, msg_dest, msg_entity )     {         switch( get_msg_arg_int( 1 ) - g_iOldMoney_k[ msg_entity ] )         {             case 300  : // kill money             {                   cs_set_user_money( msg_entity, g_iOldMoney_k[ msg_entity ] + 600 );                 return PLUGIN_HANDLED;             }             case 3250 : // Team win money             {                 cs_set_user_money( msg_entity, g_iOldMoney_k[ msg_entity ] + 2000 );                 return PLUGIN_HANDLED;             }             case 1500 : // Team lost money             {                 cs_set_user_money( msg_entity, g_iOldMoney_k[ msg_entity ] + 1000 );                 return PLUGIN_HANDLED;             }         }         return PLUGIN_CONTINUE;     }     public eDeath_Msg()     {         new iKiller = read_data( 1 );                 if( !iKiller )             return;                 g_iOldMoney_k[ iKiller ] = cs_get_user_money( iKiller );     }         public eNew_round()     {         save_old_money();     }         public eTeam_win()     {         save_old_money();     }     save_old_money()     {         new iPlayers[32], iNum, iPid;         get_players( iPlayers, iNum );                 for( new i; i < iNum; i++ )         {             iPid = iPlayers[i];             g_iOldMoney_k[ iPid ] = cs_get_user_money( iPid );         }     }
__________________
Arkshine is offline
purple_pixie
Veteran Member
Join Date: Jun 2007
Location: Winchester, England
Old 10-15-2007 , 09:12   Re: Killing Money
Reply With Quote #3

Doesn't team lose/win money depend on how many rounds you have won/lost consecutively?

And whether hostages were rescued / bomb planted?
purple_pixie is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 10-15-2007 , 10:43   Re: Killing Money
Reply With Quote #4

I don't know purple_pixie.

I have just played few rounds and money stay the same.

I have not tested more thoroughly but I'm pretty sure that you're right.


EDIT : connor found that from cs1.5 manual. I don't know if it's the same for cs1.6.
Attached Thumbnails
Click image for larger version

Name:	cs15manual.png
Views:	240
Size:	29.7 KB
ID:	20857  
__________________

Last edited by Arkshine; 10-15-2007 at 11:18.
Arkshine is offline
elpouletorange
Senior Member
Join Date: Oct 2007
Old 10-16-2007 , 11:39   Re: Killing Money
Reply With Quote #5

Thx ill try this when i will be back at home
elpouletorange 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 01:14.


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