Raised This Month: $ Target: $400
 0% 

[HELP]Weapon Buying times restrict


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
claudiuhks
Yam Inside®™℠
Join Date: Jan 2010
Location: Living Randomly
Old 04-20-2012 , 14:18   Re: [HELP]Weapon Buying times restrict
Reply With Quote #2

Your theory is forging the server performance.

PHP Code:
new g_iBoughtTimes33 ];

public 
plugin_init( )
  
register_logevent"RoundStart"2"1=Round_Start" );

public 
client_putinserveriPlayer )
{
  
g_iBoughtTimesiPlayer ] = 0;
}

public 
client_bought_what_we_wantiPlayer )
{
  if( 
g_iBoughtTimesiPlayer ] > )
  {
    
client_printiPlayerprint_chat"This item was bought three times this round!" );

    
/* If you want to restore ammo packs */
    
zp_set_user_ammo_packsiPlayerzp_get_user_ammo_packsiPlayer ) + THIS_ITEM_PRICE );

    return 
PLUGIN_HANDLED;
  }

  
g_iBoughtTimesiPlayer ] += 1;

  return 
PLUGIN_HANDLED;
}

public 
RoundStart( )
{
  static 
i;
  for( 
1get_maxplayers( ) + 1i++ )
    
g_iBoughtTimes] = 0;


Last edited by claudiuhks; 04-20-2012 at 16:11.
claudiuhks is offline
Send a message via MSN to claudiuhks Send a message via Yahoo to claudiuhks Send a message via Skype™ to claudiuhks
 



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 07:53.


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