Raised This Month: $ Target: $400
 0% 

[ZP] Extra item: Thunder Knife


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
abdul-rehman
Veteran Member
Join Date: Jan 2010
Location: Khi, Pakistan
Old 09-12-2010 , 02:46   Re: [HELP] [ZP] Extra item: Thunder Knife
Reply With Quote #7

You need to change this
Code:
public event_round_start() {     for(new i = 0; i < 32; i++)         havetk[i] = 0 }
To this:
Code:
public event_round_start() {     static i, max_players     if (!max_players) max_players = get_maxplayers()     for(i = 1; i <= max_players; i++)         if (is_user_connected(i)) havetk[i] = 0 }

Or for setting havetk[i] to 0 you can use arrayset( ... ) native to achieve your goal

And change this:
Code:
public zp_extra_item_selected(id, itemid) {     if (itemid == g_tknife)     havetk[id] = 1     client_print(id, print_chat, "[ZP] You got Thunder Knife! Slash a Zombie to kill him with thunder")     return PLUGIN_CONTINUE;     }
To this:
Code:
public zp_extra_item_selected(id, itemid) {     if (itemid == g_tknife)     {         havetk[id] = 1         client_print(id, print_chat, "[ZP] You got Thunder Knife! Slash a Zombie to kill him with thunder")     } }
Or else the if statement wouldnt be properly read by the compiler
__________________

My Plugins For ZP

Inactive due to College and Studies

Last edited by abdul-rehman; 09-12-2010 at 02:48.
abdul-rehman is offline
Send a message via Yahoo to abdul-rehman Send a message via Skype™ to abdul-rehman
 



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 16:26.


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