Raised This Month: $ Target: $400
 0% 

Set_user_bpammo


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
One
Veteran Member
Join Date: Oct 2008
Location: Hardstyle-eSports.de
Old 12-31-2009 , 14:04   Set_user_bpammo
Reply With Quote #1

hi,

i tried to give bpammo but i have a problem by compiling.

PHP Code:
set_user_bpammo(id,CSW_M4A1,90)

native set_user_bpammo(indexweaponamount); 
i dont like to user cstrike for only 1 thing in my code.

the already uses modules :

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#include <fun>
#include <engine> 
where am i wrong?

PHP Code:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c1997-2006 ITB CompuPhaseAMX Mod X Team

Error
Number of arguments does not match definition on line 4060

1 Error
.
Could not locate output file C:\Programme\°°Steam°°\steamapps\cpl_one\counter-strike\cstrike\addons\amxmodx\plugins\Untitled.amx (compile failed). 
__________________
One is offline
Send a message via ICQ to One Send a message via AIM to One Send a message via MSN to One Send a message via Yahoo to One Send a message via Skype™ to One
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 12-31-2009 , 14:11   Re: Set_user_bpammo
Reply With Quote #2

set_user_bpammo doesn't exists..
__________________
xPaw is offline
One
Veteran Member
Join Date: Oct 2008
Location: Hardstyle-eSports.de
Old 12-31-2009 , 14:11   Re: Set_user_bpammo
Reply With Quote #3

u know other ways to set bpammo without using cstrike?
__________________
One is offline
Send a message via ICQ to One Send a message via AIM to One Send a message via MSN to One Send a message via Yahoo to One Send a message via Skype™ to One
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 12-31-2009 , 14:12   Re: Set_user_bpammo
Reply With Quote #4

include cstrike module and use cs_set_user_bpammo native.
Where have you found set_user_bpammo ?

-edit-
Just read your post.
Why don't you want to use cstrike ?
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 12-31-2009 , 14:12   Re: Set_user_bpammo
Reply With Quote #5

There is nothing wrong in using cstrike module.
__________________
xPaw is offline
One
Veteran Member
Join Date: Oct 2008
Location: Hardstyle-eSports.de
Old 12-31-2009 , 14:13   Re: Set_user_bpammo
Reply With Quote #6

hihi, i tried to do it by my self. because i dont want to use cstrike ( i think its better for cpu usage then i need it only for this 1 function )

edit: xpaw u was faster ok ill use cstrike. ty
__________________
One is offline
Send a message via ICQ to One Send a message via AIM to One Send a message via MSN to One Send a message via Yahoo to One Send a message via Skype™ to One
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 12-31-2009 , 14:18   Re: Set_user_bpammo
Reply With Quote #7

cstrike is safe you use.

In case you really don't want to use it you can use this (not recommended)

PHP Code:
enum _:AmmoIds {
    
ammo_338magnum 1,
    
ammo_762nato,
    
ammo_556natobox,
    
ammo_556nato,
    
ammo_buckshot,
    
ammo_45acp,
    
ammo_57mm,
    
ammo_50ae,
    
ammo_357sig,
    
ammo_9mm,
    
ammo_flashbang,
    
ammo_hegrenade,
    
ammo_smokegrenade,
    
ammo_c4
}

const 
EXTRA_OFFSET_PLAYER 5
const m_rgAmmo_Slot0 376

get_user_bpammo
(idiWeapon)
{
    if( !
is_user_alive(id) )
    {
        return 
0
    
}
    new 
iOffset
    
switch(iWeapon)
    {
        case 
CSW_AWPiOffset ammo_338magnum
        
case CSW_SCOUTCSW_AK47CSW_G3SG1iOffset ammo_762nato
        
case CSW_M249iOffset ammo_556natobox
        
case CSW_FAMASCSW_M4A1CSW_AUGCSW_SG550CSW_GALICSW_SG552iOffset ammo_556nato
        
case CSW_M3CSW_XM1014iOffset ammo_buckshot
        
case CSW_USPCSW_UMP45CSW_MAC10iOffset ammo_45acp
        
case CSW_FIVESEVENCSW_P90iOffset ammo_57mm
        
case CSW_DEAGLEiOffset ammo_50ae
        
case CSW_P228iOffset ammo_357sig
        
case CSW_GLOCK18CSW_MP5NAVYCSW_TMPCSW_ELITEiOffset ammo_9mm
        
case CSW_FLASHBANGiOffset ammo_flashbang
        
case CSW_HEGRENADEiOffset ammo_hegrenade
        
case CSW_SMOKEGRENADEiOffset ammo_smokegrenade
        
case CSW_C4iOffset ammo_c4
        
default:return 0
    
}
    return 
get_pdata_int(idm_rgAmmo_Slot0+iOffsetEXTRA_OFFSET_PLAYER)
}

set_user_bpammo(idiWeaponiAmount)
{
    if( !
is_user_alive(id) )
    {
        return 
0
    
}
    new 
iOffset
    
switch(iWeapon)
    {
        case 
CSW_AWPiOffset ammo_338magnum
        
case CSW_SCOUTCSW_AK47CSW_G3SG1iOffset ammo_762nato
        
case CSW_M249iOffset ammo_556natobox
        
case CSW_FAMASCSW_M4A1CSW_AUGCSW_SG550CSW_GALICSW_SG552iOffset ammo_556nato
        
case CSW_M3CSW_XM1014iOffset ammo_buckshot
        
case CSW_USPCSW_UMP45CSW_MAC10iOffset ammo_45acp
        
case CSW_FIVESEVENCSW_P90iOffset ammo_57mm
        
case CSW_DEAGLEiOffset ammo_50ae
        
case CSW_P228iOffset ammo_357sig
        
case CSW_GLOCK18CSW_MP5NAVYCSW_TMPCSW_ELITEiOffset ammo_9mm
        
case CSW_FLASHBANGiOffset ammo_flashbang
        
case CSW_HEGRENADEiOffset ammo_hegrenade
        
case CSW_SMOKEGRENADEiOffset ammo_smokegrenade
        
case CSW_C4iOffset ammo_c4
        
default:return 0
    
}
    
set_pdata_int(idm_rgAmmo_Slot0+iOffsetiAmountEXTRA_OFFSET_PLAYER)
    return 
1

__________________
- tired and retired -

- my plugins -

Last edited by ConnorMcLeod; 12-31-2009 at 14:20.
ConnorMcLeod is offline
One
Veteran Member
Join Date: Oct 2008
Location: Hardstyle-eSports.de
Old 12-31-2009 , 14:21   Re: Set_user_bpammo
Reply With Quote #8

wow oO this is nice. thanks. ill try it 1000000%
__________________
One is offline
Send a message via ICQ to One Send a message via AIM to One Send a message via MSN to One Send a message via Yahoo to One Send a message via Skype™ to One
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 12-31-2009 , 14:22   Re: Set_user_bpammo
Reply With Quote #9

Have you read what we wrote ?
cstrike will be more efficient.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
One
Veteran Member
Join Date: Oct 2008
Location: Hardstyle-eSports.de
Old 12-31-2009 , 14:23   Re: Set_user_bpammo
Reply With Quote #10

yop. i did. i want to experiment anything thats why i'll try your code
__________________
One is offline
Send a message via ICQ to One Send a message via AIM to One Send a message via MSN to One Send a message via Yahoo to One Send a message via Skype™ to One
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 04:15.


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