/* * Player data that needs to be called by an external function and doesn't need to keep track of this data * every second. */ public GameStructs.Gear GetPlayerGear() { Int64 PlayerGearBase = Scanner.READ_MULTILEVEL_PTR(Address.BASE + Address.EQUIPMENT_OFFSET, Address.Offsets.PlayerGearOffsets); // Helm GameStructs.Armor Helm = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase), Decorations = GetDecorationsFromGear(PlayerGearBase, 0) }; // Chest GameStructs.Armor Chest = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase + 0x4), Decorations = GetDecorationsFromGear(PlayerGearBase + 0x4, 1) }; // Arms GameStructs.Armor Arms = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase + 0x8), Decorations = GetDecorationsFromGear(PlayerGearBase + 0x8, 2) }; // Waist GameStructs.Armor Waist = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase + 0xC), Decorations = GetDecorationsFromGear(PlayerGearBase + 0xC, 3) }; // Waist GameStructs.Armor Legs = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase + 0x10), Decorations = GetDecorationsFromGear(PlayerGearBase + 0x10, 4) }; // Gets player weapon info GameStructs.Weapon WeaponInfo = new GameStructs.Weapon() { ID = Scanner.READ_INT(PlayerGearBase) }; GameStructs.Gear PlayerGear = new GameStructs.Gear(); return(PlayerGear); }
/* * Player data that needs to be called by an external function and doesn't need to keep track of this data * every second. */ public GameStructs.Gear GetPlayerGear() { Int64 PlayerGearBase = Scanner.READ_MULTILEVEL_PTR(Address.BASE + Address.EQUIPMENT_OFFSET, Address.Offsets.PlayerGearOffsets); // Helm GameStructs.Armor Helm = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase), Decorations = GetDecorationsFromGear(PlayerGearBase, 0) }; // Chest GameStructs.Armor Chest = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase + 0x4), Decorations = GetDecorationsFromGear(PlayerGearBase, 1) }; // Arms GameStructs.Armor Arms = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase + 0x8), Decorations = GetDecorationsFromGear(PlayerGearBase, 2) }; // Waist GameStructs.Armor Waist = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase + 0xC), Decorations = GetDecorationsFromGear(PlayerGearBase, 3) }; // Waist GameStructs.Armor Legs = new GameStructs.Armor() { ID = Scanner.READ_INT(PlayerGearBase + 0x10), Decorations = GetDecorationsFromGear(PlayerGearBase, 4) }; // Charm GameStructs.Charm Charm = new GameStructs.Charm() { ID = Scanner.READ_INT(PlayerGearBase + 0x14) }; // Weapon GameStructs.Weapon Weapon = new GameStructs.Weapon() { Type = Scanner.READ_INT(PlayerGearBase + 0x124), ID = Scanner.READ_INT(PlayerGearBase + 0x128), Decorations = GetWeaponDecorations(PlayerGearBase + 0x128), NewAugments = GetWeaponNewAugments(PlayerGearBase + 0x128), Awakenings = GetWeaponAwakenedSkills(PlayerGearBase + 0x128), CustomAugments = GetCustomAugments(PlayerGearBase + 0x128), BowgunMods = GetBowgunMods(PlayerGearBase + 0x128) }; // Primary Tool GameStructs.SpecializedTool PrimaryTool = new GameStructs.SpecializedTool() { ID = Scanner.READ_INT(PlayerGearBase + 0x158), Decorations = GetMantleDecorations(PlayerGearBase + 0x164) }; // Secondary Tool GameStructs.SpecializedTool SecondaryTool = new GameStructs.SpecializedTool() { ID = Scanner.READ_INT(PlayerGearBase + 0x15C), Decorations = GetMantleDecorations(PlayerGearBase + 0x170) }; // Now we put all the data in the player gear struct GameStructs.Gear PlayerGear = new GameStructs.Gear() { Helmet = Helm, Chest = Chest, Hands = Arms, Waist = Waist, Legs = Legs, Charm = Charm, Weapon = Weapon, SpecializedTools = new GameStructs.SpecializedTool[2] { PrimaryTool, SecondaryTool } }; return(PlayerGear); }