Raised This Month: $ Target: $400
 0% 

is Attribute broken?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
SkyeOfGrey
New Member
Join Date: Jul 2013
Old 07-12-2013 , 09:40   is Attribute broken?
Reply With Quote #1

I'm using TF2Items_CreateItem in my plugin. i removed Eyelander's attributes with OVERRIDE_ALL flag. but sometimes it doesn't change.

Here is my code:
PHP Code:
new Handle:hWeaponSword INVALID_HANDLE;

...

// Demoman's Eyelander
hWeaponSword TF2Items_CreateItem(OVERRIDE_ALL);
TF2Items_SetClassname(hWeaponSword"tf_weapon_sword");
TF2Items_SetItemIndex(hWeaponSword132);
TF2Items_SetQuality(hWeaponSword6);
TF2Items_SetLevel(hWeaponSword0);
TF2Items_SetNumAttributes(hWeaponSword0);

...

new 
iEntityiIndex;

if (
TF2_GetPlayerClass(iClient) == TFClass_DemoMan)
{
    
iEntity GetPlayerWeaponSlot(iClient2);
    if (
IsGoodEntity(iEntity))
    {
        
iIndex GetEntProp(iEntityProp_Send"m_iItemDefinitionIndex");
        if (
hWeaponSword != INVALID_HANDLE)
        {
            if (
iIndex == 132)
            {
                
TF2_RemoveWeaponSlot(iClient2);
                
iEntity TF2Items_GiveNamedItem(iClienthWeaponSword);
                
EquipPlayerWeapon(iClientiEntity);
            }
        }
    }

in this code, Eyelander's attribute has been removed. but in game, it displays like this:

Quote:
The Eyelander
Level 0 Sword
No random critical hits
-25 max health on wearer
This weapon has a large melee range.
Gives increased speed and health with every head you take.
those attributes should be removed. but it doesn't removed.
please help!

sorry for poor english skill

edit) and i'm using tf2items_release-4624dbfba23d for Windows.

Last edited by SkyeOfGrey; 07-12-2013 at 09:43. Reason: Added TF2Items Version.
SkyeOfGrey is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 07-12-2013 , 09:45   Re: is Attribute broken?
Reply With Quote #2

https://forums.alliedmods.net/showthread.php?t=220449, particularly page 2 of that thread.
__________________
Not currently working on SourceMod plugin development.
Powerlord is offline
eminemxw88
Senior Member
Join Date: Dec 2009
Old 07-13-2013 , 10:38   Re: is Attribute broken?
Reply With Quote #3

me too,guy.
i need some help too.
eminemxw88 is offline
Send a message via MSN to eminemxw88
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 21:00.


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