-
Active Member
how read item affixes
i have few question about reading items stats over the IItem interface
i need to know :
-if item is ring or amulet
-if item has socket
-if item has CDR/CHC/CHD
is that possible?
-
Savvy ? 🐒
PHP Code:
item.Perfections.FirstOrDefault(p => p.Attribute.Code == attributeCode);
Where attributeCode is a string :
CHC : "Crit_Percent_Bonus_Capped"
CHD : "Crit_Damage_Percent"
CDR : "Power_Cooldown_Reduction_Percent_All"
Socket : "Sockets"
To check item type, use the possible locations :
Neck :
PHP Code:
if (item.SnoItem.UsedLocation1 == ItemLocation.Neck)
Rings :
PHP Code:
if (item.SnoItem.UsedLocation1 == ItemLocation.RightRing || item.SnoItem.UsedLocation1 == ItemLocation.LeftRing)
-
Post Thanks / Like - 4 Thanks
-
Active Member
the items are unidentified and not equipped on player. i need something like a help plugin which highlight good items.
how i can read the value of the CDR/CHD/CHC ?
currently i have no idea how to debug the plugin i want to develop. can i print debug messages on screen or to a logfile?
Last edited by d2k2; 09-03-2017 at 11:36 AM.
-
Savvy ? 🐒
You can use
PHP Code:
Hud.Debug("AnyString");
This will write a line in /logs/plugins_debug.txt
Or you can use one of my dev tools : Says.zip
Usage :
PHP Code:
Jack.Says.Debug(string,object,collection,almost anything);
-
Post Thanks / Like - 3 Thanks
-
Active Member
Thx a lot Jack. Is it also possible to read the value of the item stats from unidentified items?
-
Savvy ? 🐒
From the dump of a unid Leoric's crown :
334197453 Unique_Helm_002_p1 Leoric's Crown 3:0 loot
attr Gizmo_Has_Been_Operated -1 1
attr Gem_Attributes_Multiplier -1 0,76953125
attr Requirement 57 70
attr Unidentified -1 1
proc unidentified 1
attr Post_2_5_0_Drop -1 1
attr Post_2_1_2_Drop -1 1
attr Loot_2_0_Drop -1 1
attr Seed -1 782474131
proc seed 782474131
attr IdentifyCost -1 306
attr Item_LegendaryItem_Level_Override -1 70
attr Item_Binding_Level_Override -1 2
proc bound_mode 2
attr Item_Bound_To_ACD -1 2018640021
proc bound_to_account 1
attr Item_Quality_Level -1 9
proc quality 9
attr Durability_Max -1 307
proc dura 30
attr Durability_Cur -1 307
attr Picked_Up_Time -1 4191
proc picked_up_time 4191
attr Item_Assigned_Hero_Low -1 0
attr Item_Legendary_Item_Base_Item -1 1565456767
attr Season -1 11
attr Armor_Item_Total -1 664
proc t_armor 664
attr Armor_Item_SubTotal -1 664
attr Armor_Item -1 664
proc b_armor 664
perf 722 Gem_Attributes_Multiplier -1 0,75-1 0
Only visible one is the legendary power (and value is defaulted to 0)
-
Post Thanks / Like - 1 Thanks
d2k2 (1 members gave Thanks to JackCeparou for this useful post)