Raised This Month: $ Target: $400
 0% 

Give Item Plugin [HELP]


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
XxAvalanchexX
Veteran Member
Join Date: Oct 2004
Location: abort73.com
Old 08-30-2005 , 17:02  
Reply With Quote #4

Hmm, let's try re-writing this a bit.

Code:
// GIVING CLIENT ITEMS PVK v1.2b by Dewd In The Newd //========================================================= #include <amxmodx> #include <amxmisc> #include <fun> public give_item_pvk(admin_index,victim_index,weapon_give[]) {    new name[32]    get_user_name(victim_index,name,31)      // Remove The slashes before the follow 2 lines of code to enable info messages    // set_hudmessage(200, 50, 0, -1.0, 0.30, 0, 6.0, 6.0, 0.5, 0.15, 1)    // show_hudmessage(0,"%s Has Been Given An Attack",name)      if (equali(weapon_give,"all")){       give_item(victim_index,"item_chainmail")       give_item(victim_index,"item_food")       give_item(victim_index,"item_leather")       give_item(victim_index,"item_platemail")       give_item(victim_index,"item_treasurechest")    } else {       new item[32]       format(item,31,"item_%s",weapon_give)       give_item(victim_index,item)    }        // client_print(admin_index,print_console,"[AMXX] Client ^"%s^" has been given an item",name) } public admin_item_pvk(id,level,cid) {    if(!cmd_access(id,level,cid,3)) {       return PLUGIN_HANDLED    }    new arg1[32]    new arg2[32]    read_argv(1,arg1,31)    read_argv(2,arg2,31)    new target = cmd_target(id,arg1,6)    if(!target) {       return PLUGIN_HANDLED    }    give_item_pvk(id,target,arg2)    return PLUGIN_HANDLED } public plugin_init() {    register_plugin("PVK Give Items","1.2b","Dewd In The Newd")    register_concmd("amx_item_pvk","admin_item_pvk",ADMIN_LEVEL_A,"<player> <item>") }
__________________
No longer around. Thanks your support, everyone! As always:
THIS ONES FOR YOU
3000 PTS
XxAvalanchexX 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 14:17.


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