Raised This Month: $ Target: $400
 0% 

Help with awpme script!


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Kitami
Senior Member
Join Date: Jun 2006
Location: Toronto
Old 07-26-2008 , 18:18   Help with awpme script!
Reply With Quote #1

There is a glitch where if you type in amx_awpme and you have the bomb it will take away your bomb. Or if you have a kit it will take away your kit.

Is someone could please excempt those two items from being removed when checking for guns.

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <cstrike>

#define PLUGIN "give awp"
#define VERSION "1.0"
#define AUTHOR "Reaper2331"

#define AMX_ADMIN_FLAG ADMIN_VOTE

public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_concmd("amx_awpme","checkGuns",AMX_ADMIN_FLAG,"- Gives Admins with Flag J an Awp")
    
}
public 
checkGuns(idlevelcid)
{
    if( !
cmd_accessidlevelcid) )
        return 
PLUGIN_HANDLED

    
if (is_user_alive(id) )
   {
    
strip_user_weapons(id)
    
    
give_item(id,"weapon_knife")
    
give_item(id,"weapon_awp")
    
give_item(id,"ammo_338magnum")
    
give_item(id,"ammo_338magnum")
    
give_item(id,"ammo_338magnum")
    
give_item(id,"weapon_deagle")
    
give_item(id,"ammo_50ae")
    
give_item(id,"ammo_50ae")
    
give_item(id,"ammo_50ae")
    
give_item(id,"ammo_50ae")
    
give_item(id,"ammo_50ae")
    
give_item(id,"ammo_50ae")
    
give_item(id,"ammo_50ae")
    
give_item(id,"weapon_hegrenade")
    
give_item(id,"weapon_smokegrenade")
    
give_item(id,"weapon_flashbang")
    
give_item(id,"weapon_flashbang")
    
    
client_print(idprint_chat"[AMXX] You Now Have An Awp Enjoy")
    }
    return 
PLUGIN_CONTINUE

__________________
You know what I'd like to be? I mean if I had my goddamn choice, I'd just be the catcher in the rye and all.
Kitami is offline
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 07-26-2008 , 18:25   Re: Help with awpme script!
Reply With Quote #2

Use below one.
__________________

Last edited by hleV; 07-26-2008 at 18:35.
hleV is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 07-26-2008 , 18:31   Re: Help with awpme script!
Reply With Quote #3

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <cstrike>

#define PLUGIN "give awp"
#define VERSION "1.0"
#define AUTHOR "Reaper2331"

#define AMX_ADMIN_FLAG ADMIN_VOTE

public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_concmd("amx_awpme","checkGuns",AMX_ADMIN_FLAG,"- Gives Admins with Flag J an Awp")
    
}
public 
checkGuns(idlevelcid)
{
    if( !
cmd_access(idlevelcid1) )
        return 
PLUGIN_HANDLED

    
if ( is_user_alive(id) )
    {
        new 
kit cs_get_user_defuse(id)
        new 
bomb user_has_weapon(idCSW_C4)
        
        
strip_user_weapons(id)
        
        if( 
kit cs_set_user_defuse(id1)
        if( 
bomb give_item(id"weapon_c4")
        
        
give_item(id,"weapon_knife")
        
give_item(id,"weapon_awp")
        
give_item(id,"ammo_338magnum")
        
give_item(id,"ammo_338magnum")
        
give_item(id,"ammo_338magnum")
        
give_item(id,"weapon_deagle")
        
give_item(id,"ammo_50ae")
        
give_item(id,"ammo_50ae")
        
give_item(id,"ammo_50ae")
        
give_item(id,"ammo_50ae")
        
give_item(id,"ammo_50ae")
        
give_item(id,"ammo_50ae")
        
give_item(id,"ammo_50ae")
        
give_item(id,"weapon_hegrenade")
        
give_item(id,"weapon_smokegrenade")
        
give_item(id,"weapon_flashbang")
        
give_item(id,"weapon_flashbang")
        
        
client_print(idprint_chat"[AMXX] You Now Have An Awp Enjoy")
    }
    return 
PLUGIN_CONTINUE

Note: hleV's will not work for defuse kits, and will only work if player is holding the bomb when the awp is given.
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
Kitami
Senior Member
Join Date: Jun 2006
Location: Toronto
Old 07-26-2008 , 19:34   Re: Help with awpme script!
Reply With Quote #4

Thanks alot Baby
__________________
You know what I'd like to be? I mean if I had my goddamn choice, I'd just be the catcher in the rye and all.
Kitami is offline
Kitami
Senior Member
Join Date: Jun 2006
Location: Toronto
Old 07-27-2008 , 02:39   Re: Help with awpme script!
Reply With Quote #5

Is there anyway to have it just strip the main gun from the person? not all the weapons.
__________________
You know what I'd like to be? I mean if I had my goddamn choice, I'd just be the catcher in the rye and all.
Kitami is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 07-27-2008 , 03:20   Re: Help with awpme script!
Reply With Quote #6

Well, it gives them a deagle and an awp.
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
{PHILMAGROIN}
Senior Member
Join Date: Aug 2007
Location: In the middle of the des
Old 07-27-2008 , 03:38   Re: Help with awpme script!
Reply With Quote #7

Code:
#include <amxmodx>
#include <amxmisc>
#include <fun>
#include <cstrike>

#define PLUGIN "give awp"
#define VERSION "1.0"
#define AUTHOR "Reaper2331"

#define AMX_ADMIN_FLAG ADMIN_VOTE
Code:
public plugin_init() {
    register_plugin(PLUGIN, VERSION, AUTHOR)
    register_concmd("amx_awpme","checkGuns",AMX_ADMIN_FLAG,"- Gives Admins with Flag J an Awp")
    
}

Code:
public dropcurweapon(id){
    engclient_cmd(id, "drop", "weapon_shield")
    engclient_cmd(id, "drop", "weapon_m3")
    engclient_cmd(id, "drop", "weapon_xm1014")
    engclient_cmd(id, "drop", "weapon_mp5navy")    
    engclient_cmd(id, "drop", "weapon_p90")
    engclient_cmd(id, "drop", "weapon_mac10")
    engclient_cmd(id, "drop", "weapon_tmp")
    engclient_cmd(id, "drop", "weapon_ump45")
    engclient_cmd(id, "drop", "weapon_galil")
    engclient_cmd(id, "drop", "weapon_famas")    
    engclient_cmd(id, "drop", "weapon_m4a1")
    engclient_cmd(id, "drop", "weapon_aug")
    engclient_cmd(id, "drop", "weapon_ak47")
    engclient_cmd(id, "drop", "weapon_sg552")
    engclient_cmd(id, "drop", "weapon_scout")
    engclient_cmd(id, "drop", "weapon_awp")
    engclient_cmd(id, "drop", "weapon_sg550")
    engclient_cmd(id, "drop", "weapon_g3sg1")
    engclient_cmd(id, "drop", "weapon_m249")
}

public checkGuns(id, level, cid)
{
    if( !cmd_access(id, level, cid, 1) )
        return PLUGIN_HANDLED

    if ( is_user_alive(id) )
    {
        dropcurweapon(id)
        give_item(id,"weapon_knife")
        give_item(id,"weapon_awp")
        give_item(id,"ammo_338magnum")
        give_item(id,"ammo_338magnum")
        give_item(id,"ammo_338magnum")
        give_item(id,"weapon_deagle")
        give_item(id,"ammo_50ae")
        give_item(id,"ammo_50ae")
        give_item(id,"ammo_50ae")
        give_item(id,"ammo_50ae")
        give_item(id,"ammo_50ae")
        give_item(id,"ammo_50ae")
        give_item(id,"ammo_50ae")
        give_item(id,"weapon_hegrenade")
        give_item(id,"weapon_smokegrenade")
        give_item(id,"weapon_flashbang")
        give_item(id,"weapon_flashbang")
        
        client_print(id, print_chat, "[AMXX] You Now Have An Awp Enjoy")
    }
    return PLUGIN_HANDLED
}


dont know why they are split up but i think this works

__________________
[B]
{PHILMAGROIN} is offline
Kitami
Senior Member
Join Date: Jun 2006
Location: Toronto
Old 07-27-2008 , 17:31   Re: Help with awpme script!
Reply With Quote #8

You have to change the tags to [PHP] so I can copy it and compile it, but thanks alot.
__________________
You know what I'd like to be? I mean if I had my goddamn choice, I'd just be the catcher in the rye and all.
Kitami is offline
{PHILMAGROIN}
Senior Member
Join Date: Aug 2007
Location: In the middle of the des
Old 07-29-2008 , 14:33   Re: Help with awpme script!
Reply With Quote #9

Here you go. havent tested it.
Attached Files
File Type: sma Get Plugin or Get Source (awpme.sma - 715 views - 2.2 KB)
__________________
[B]
{PHILMAGROIN} is offline
Kitami
Senior Member
Join Date: Jun 2006
Location: Toronto
Old 08-01-2008 , 20:59   Re: Help with awpme script!
Reply With Quote #10

It works great, can you please just make it just give you an awp with ammo, no deagle or nades etc. I would do it but I cant copy your code from here
__________________
You know what I'd like to be? I mean if I had my goddamn choice, I'd just be the catcher in the rye and all.
Kitami 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 05:40.


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