// Token: 0x06000259 RID: 601 RVA: 0x0001636C File Offset: 0x0001456C public static void incrementStatTrackerValue(ushort itemID, int newValue) { if (Player.player == null) { return; } SteamPlayer owner = Player.player.channel.owner; if (owner == null) { return; } int num; if (!owner.getItemSkinItemDefID(itemID, out num)) { return; } string tags; string dynamic_props; if (!owner.getTagsAndDynamicPropsForItem(num, out tags, out dynamic_props)) { return; } DynamicEconDetails dynamicEconDetails = new DynamicEconDetails(tags, dynamic_props); EStatTrackerType type; int num2; if (!dynamicEconDetails.getStatTrackerValue(out type, out num2)) { return; } if (!owner.modifiedItems.Contains(itemID)) { owner.modifiedItems.Add(itemID); } int i = 0; while (i < owner.skinItems.Length) { if (owner.skinItems[i] != num) { i++; } else { if (i < owner.skinDynamicProps.Length) { owner.skinDynamicProps[i] = dynamicEconDetails.getPredictedDynamicPropsJsonForStatTracker(type, newValue); return; } return; } } }
// Token: 0x060002CF RID: 719 RVA: 0x0001CE30 File Offset: 0x0001B030 public static void incrementStatTrackerValue(ushort itemID, int newValue) { bool flag = Player.player == null; if (!flag) { SteamPlayer owner = Player.player.channel.owner; bool flag2 = owner == null; if (!flag2) { int num; bool flag3 = !owner.getItemSkinItemDefID(itemID, out num); if (!flag3) { string tags; string dynamic_props; bool flag4 = !owner.getTagsAndDynamicPropsForItem(num, out tags, out dynamic_props); if (!flag4) { DynamicEconDetails dynamicEconDetails = new DynamicEconDetails(tags, dynamic_props); EStatTrackerType type; int num2; bool statTrackerValue = dynamicEconDetails.getStatTrackerValue(out type, out num2); if (statTrackerValue) { bool flag5 = !owner.modifiedItems.Contains(itemID); if (flag5) { owner.modifiedItems.Add(itemID); } int i = 0; while (i < owner.skinItems.Length) { bool flag6 = owner.skinItems[i] != num; if (flag6) { i++; } else { bool flag7 = i < owner.skinDynamicProps.Length; if (flag7) { owner.skinDynamicProps[i] = dynamicEconDetails.getPredictedDynamicPropsJsonForStatTracker(type, newValue); break; } break; } } } } } } } }