/// <summary> /// Draw the wing slots. /// </summary> /// <param name="spriteBatch">drawing SpriteBatch</param> public void Draw(SpriteBatch spriteBatch) { if (ShouldDrawSlots()) { int mapH = 0; int rX = 0; int rY = 0; float origScale = Main.inventoryScale; Main.inventoryScale = 0.85f; if (Main.mapEnabled) { if (!Main.mapFullscreen && Main.mapStyle == 1) { mapH = 256; } if ((mapH + 600) > Main.screenHeight) { mapH = Main.screenHeight - 600; } } rX = Main.screenWidth - 92 - (47 * 2); rY = mapH + 174; if (Main.netMode == 1) { rX -= 47; } EquipWingSlot.Position = new Vector2(rX, rY); VanityWingSlot.Position = new Vector2(rX -= 47, rY); WingDyeSlot.Position = new Vector2(rX -= 47, rY); VanityWingSlot.Draw(spriteBatch); EquipWingSlot.Draw(spriteBatch); WingDyeSlot.Draw(spriteBatch); Main.inventoryScale = origScale; EquipWingSlot.Update(); VanityWingSlot.Update(); WingDyeSlot.Update(); UIUtils.UpdateInput(); } }
/// <summary> /// Draw the wing slots. /// </summary> /// <param name="spriteBatch">drawing SpriteBatch</param> public void Draw(SpriteBatch spriteBatch) { int slotLocation; if (!ShouldDrawSlots(out slotLocation)) { return; } int mapH = 0; int rX; int rY; float origScale = Main.inventoryScale; Main.inventoryScale = 0.85f; if (Main.mapEnabled) { if (!Main.mapFullscreen && Main.mapStyle == 1) { mapH = 256; } } if (slotLocation == 2) { if (Main.mapEnabled) { if ((mapH + 600) > Main.screenHeight) { mapH = Main.screenHeight - 600; } } rX = Main.screenWidth - 92 - (47 * 2); rY = mapH + 174; if (Main.netMode == 1) { rX -= 47; } } else { if (Main.mapEnabled) { int adjustY = 600; if (Main.player[Main.myPlayer].ExtraAccessorySlotsShouldShow) { adjustY = 610 + PlayerInput.UsingGamepad.ToInt() * 30; } if ((mapH + adjustY) > Main.screenHeight) { mapH = Main.screenHeight - adjustY; } } int slotCount = 7 + Main.player[Main.myPlayer].extraAccessorySlots; if ((Main.screenHeight < 900) && (slotCount >= 8)) { slotCount = 7; } rX = Main.screenWidth - 92 - 14 - (47 * 3) - (int)(Main.extraTexture[58].Width * Main.inventoryScale); rY = (int)(mapH + 174 + 4 + slotCount * 56 * Main.inventoryScale); } EquipSlot.Position = new Vector2(rX, rY); VanitySlot.Position = new Vector2(rX -= 47, rY); DyeSlot.Position = new Vector2(rX - 47, rY); VanitySlot.Draw(spriteBatch); EquipSlot.Draw(spriteBatch); DyeSlot.Draw(spriteBatch); Main.inventoryScale = origScale; EquipSlot.Update(); VanitySlot.Update(); DyeSlot.Update(); }
/// <summary> /// Draw the shoe slots. /// </summary> /// <param name="spriteBatch">drawing SpriteBatch</param> public void Draw(SpriteBatch spriteBatch) { //int slotLocation; if (!ShouldDrawSlots())//(out slotLocation)) outdated { return; } int mapH = 0; int rX; int rY; float origScale = Main.inventoryScale; Main.inventoryScale = 0.85f; if (Main.mapEnabled) { if (!Main.mapFullscreen && Main.mapStyle == 1) { mapH = 256; } } if (MagicalThings.ShoeSlotlocation) //(slotLocation == 2) used new config function { if (Main.mapEnabled) { if ((mapH + 569) > Main.screenHeight) { mapH = Main.screenHeight - 569; } } rX = Main.screenWidth - 92 - (47 * 2); rY = mapH + 223; if (Main.netMode == NetmodeID.MultiplayerClient) { rX -= 47; } } else { if (Main.mapEnabled) { int adjustY = 600; if (Main.player[Main.myPlayer].ExtraAccessorySlotsShouldShow) { adjustY = 610 + PlayerInput.UsingGamepad.ToInt() * 30; } if ((mapH + adjustY) > Main.screenHeight) { mapH = Main.screenHeight - adjustY; } } int slotCount = 7 + Main.player[Main.myPlayer].extraAccessorySlots; if ((Main.screenHeight < 900) && (slotCount >= 8)) { slotCount = 7; } rX = Main.screenWidth - 92 - 14 - (47 * 3) - (int)(Main.extraTexture[58].Width * Main.inventoryScale); //58 rY = (int)(mapH + 127 + 4 + slotCount * 56 * Main.inventoryScale); } EquipShoeSlot.Position = new Vector2(rX, rY); VanityShoeSlot.Position = new Vector2(rX -= 47, rY); ShoeDyeSlot.Position = new Vector2(rX - 47, rY); VanityShoeSlot.Draw(spriteBatch); EquipShoeSlot.Draw(spriteBatch); ShoeDyeSlot.Draw(spriteBatch); Main.inventoryScale = origScale; EquipShoeSlot.Update(); VanityShoeSlot.Update(); ShoeDyeSlot.Update(); }