Raised This Month: $ Target: $400
 0% 

[HELP] native error (native "get_pdata_int")


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Old.School
Senior Member
Join Date: Sep 2015
Location: France
Old 03-06-2016 , 09:39   [HELP] native error (native "get_pdata_int")
Reply With Quote #1

03/06/2016 - 15:21:13: [AMXX] [0] dinfinity.sma::fw_CmdStart (line 10)
L 03/06/2016 - 15:21:13: [FAKEMETA] Invalid entity
L 03/06/2016 - 15:21:13: [AMXX] Displaying debug trace (plugin "dinfinity.amxx")
L 03/06/2016 - 15:21:13: [AMXX] Run time error 10: native error (native "get_pdata_int")


PHP Code:
public fw_CmdStart(iduc_handleseed)
{        
         if(!
g_has_infi[id])
              return

        if(!
is_user_alive(id))
                return
 
        new 
pItem get_pdata_cbase(idOFFSET_ACTIVE_ITEM)
 
        if(
get_pdata_int(pItemm_iId4) != CSW_ELITE)
                return
 
        if(
get_pdata_float(idm_flNextAttack) > 0.0)
                return
 
    new 
szClipszAmmo
    get_user_weapon
(idszClipszAmmo)

        new 
iButtons get_uc(uc_handleUC_Buttons)
 
        if(!(
iButtons IN_ATTACK) && (iButtons IN_ATTACK2))
        {
                if(
get_pdata_float(pItemm_flNextSecondaryAttack4) <= 0.0)
                {
                        if(
get_pdata_int(pItemm_iClip) <= 0)
                                return
 
             
g_mode[id] = 1
                        ExecuteHamB
(Ham_Weapon_PrimaryAttackfind_ent_by_owner(-1"weapon_elite"id))
            new 
num
            num 
random_num(1,2)
            if(
num == 1)UTIL_PlayWeaponAnimation(idszClip infi_SP_SHOOT_LAST random_num(infi_SP_SHOOT_LEFT1infi_SP_SHOOT_RIGHT1))
            if(
num == 2)UTIL_PlayWeaponAnimation(idszClip infi_SP_SHOOT_LAST random_num(infi_SP_SHOOT_LEFT2infi_SP_SHOOT_RIGHT2))
                }
        }
    else if(!(
iButtons IN_ATTACK2) && (iButtons IN_ATTACK))
        {
                if(
get_pdata_float(pItemm_flNextSecondaryAttack4) <= 0.0)
                {
                        if(
get_pdata_int(pItemm_iClip) <= 0)
                                return

             
g_mode[id] = 0
                
}
        }

__________________
You keep bringing B.R down .. He will rise again and kick Enemies asses !
Old.School is offline
klippy
AlliedModders Donor
Join Date: May 2013
Location: Serbia
Old 03-06-2016 , 10:06   Re: [HELP] native error (native "get_pdata_int")
Reply With Quote #2

Add
PHP Code:
if(pev_valid(pItem) != 2)
    return; 
before the erroring if clause.

pev_valid()
klippy is offline
Old.School
Senior Member
Join Date: Sep 2015
Location: France
Old 03-06-2016 , 10:57   Re: [HELP] native error (native "get_pdata_int")
Reply With Quote #3

thnx
__________________
You keep bringing B.R down .. He will rise again and kick Enemies asses !
Old.School 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 09:17.


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