TModLoader v1.4.4.9
TModLoader source code documentation
Loading...
Searching...
No Matches

◆ UpdateVisibleAccessory()

void Terraria.Player.UpdateVisibleAccessory ( int itemSlot,
Item item,
bool modded = false )
inline

Definition at line 35805 of file Player.cs.

35806 {
35807 if (item.stringColor > 0)
35808 {
35809 stringColor = item.stringColor;
35810 }
35811 if (item.handOnSlot > 0)
35812 {
35813 handon = item.handOnSlot;
35814 }
35815 if (item.handOffSlot > 0)
35816 {
35817 handoff = item.handOffSlot;
35818 }
35819 if (item.backSlot > 0)
35820 {
35821 if (ArmorIDs.Back.Sets.DrawInBackpackLayer[item.backSlot])
35822 {
35823 backpack = item.backSlot;
35824 }
35825 else if (ArmorIDs.Back.Sets.DrawInTailLayer[item.backSlot])
35826 {
35827 tail = item.backSlot;
35828 }
35829 else
35830 {
35831 back = item.backSlot;
35832 front = -1;
35833 }
35834 }
35835 if (item.frontSlot > 0)
35836 {
35837 front = item.frontSlot;
35838 }
35839 if (sitting.isSitting)
35840 {
35841 back = -1;
35842 }
35843 if (item.shoeSlot > 0)
35844 {
35845 shoe = item.shoeSlot;
35847 {
35849 }
35850 }
35851 if (item.waistSlot > 0)
35852 {
35853 waist = item.waistSlot;
35854 }
35855 if (item.shieldSlot > 0)
35856 {
35857 shield = item.shieldSlot;
35858 }
35859 if (item.neckSlot > 0)
35860 {
35861 neck = item.neckSlot;
35862 }
35863 if (item.faceSlot > 0)
35864 {
35865 if (ArmorIDs.Face.Sets.DrawInFaceHeadLayer[item.faceSlot])
35866 {
35867 faceHead = item.faceSlot;
35868 }
35869 else if (ArmorIDs.Face.Sets.DrawInFaceFlowerLayer[item.faceSlot])
35870 {
35871 faceFlower = item.faceSlot;
35872 }
35873 else
35874 {
35875 face = item.faceSlot;
35876 }
35877 }
35878 if (item.balloonSlot > 0)
35879 {
35880 if (ArmorIDs.Balloon.Sets.DrawInFrontOfBackArmLayer[item.balloonSlot])
35881 {
35882 balloonFront = item.balloonSlot;
35883 }
35884 else
35885 {
35886 balloon = item.balloonSlot;
35887 }
35888 }
35889 if (item.beardSlot > 0)
35890 {
35891 beard = item.beardSlot;
35892 }
35893 if (item.wingSlot > 0)
35894 {
35895 wings = item.wingSlot;
35896 }
35897 if (item.type == 3580)
35898 {
35899 yoraiz0rEye = itemSlot - 2;
35900 if (modded)
35901 {
35902 yoraiz0rEye += 5;
35903 }
35904 }
35905 if (item.type == 3581)
35906 {
35907 yoraiz0rDarkness = true;
35908 }
35909 if (item.type == 3929)
35910 {
35911 leinforsHair = true;
35912 }
35913 if (item.type == 4404)
35914 {
35915 hasFloatingTube = true;
35916 }
35917 if (item.type == 4563)
35918 {
35919 hasUnicornHorn = true;
35920 }
35921 if (item.type == 1987)
35922 {
35923 hasAngelHalo = true;
35924 }
35925 if (item.type == 5075)
35926 {
35927 hasRainbowCursor = true;
35928 }
35929 }
static bool[] DrawInTailLayer
If true for a given T:Terraria.ID.ArmorIDs.Back, then that equip will draw in the player's tail layer...
Definition ArmorIDs.cs:1790
static bool[] DrawInBackpackLayer
If true for a given T:Terraria.ID.ArmorIDs.Back, then that equip will draw in the player's backpack l...
Definition ArmorIDs.cs:1784
static bool[] DrawInFrontOfBackArmLayer
If true for a given T:Terraria.ID.ArmorIDs.Balloon, then that equip will draw in the player's front b...
Definition ArmorIDs.cs:2301
static bool[] DrawInFaceFlowerLayer
If true for a given T:Terraria.ID.ArmorIDs.Face, then that equip will draw in the face flower layer (...
Definition ArmorIDs.cs:2229
static bool[] DrawInFaceHeadLayer
If true for a given T:Terraria.ID.ArmorIDs.Face, then that equip will draw in the face head layer (F:...
Definition ArmorIDs.cs:2236
static int[] MaleToFemaleID
If != -1 for a given T:Terraria.ID.ArmorIDs.Shoe, then that equip will use the retrieved T:Terraria....
Definition ArmorIDs.cs:1921
PlayerSittingHelper sitting
Definition Player.cs:3009
bool hasFloatingTube
Definition Player.cs:2830
bool hasUnicornHorn
Definition Player.cs:2217
bool leinforsHair
Definition Player.cs:2223
bool hasAngelHalo
Definition Player.cs:2219
bool yoraiz0rDarkness
Definition Player.cs:2215
bool hasRainbowCursor
Definition Player.cs:2221

References Terraria.Player.back, Terraria.Player.backpack, Terraria.Item.backSlot, Terraria.Player.balloon, Terraria.Player.balloonFront, Terraria.Item.balloonSlot, Terraria.Player.beard, Terraria.Item.beardSlot, Terraria.ID.ArmorIDs.Back.Sets.DrawInBackpackLayer, Terraria.ID.ArmorIDs.Face.Sets.DrawInFaceFlowerLayer, Terraria.ID.ArmorIDs.Face.Sets.DrawInFaceHeadLayer, Terraria.ID.ArmorIDs.Balloon.Sets.DrawInFrontOfBackArmLayer, Terraria.ID.ArmorIDs.Back.Sets.DrawInTailLayer, Terraria.Player.face, Terraria.Player.faceFlower, Terraria.Player.faceHead, Terraria.Item.faceSlot, Terraria.Player.front, Terraria.Item.frontSlot, Terraria.Player.handoff, Terraria.Item.handOffSlot, Terraria.Player.handon, Terraria.Item.handOnSlot, Terraria.Player.hasAngelHalo, Terraria.Player.hasFloatingTube, Terraria.Player.hasRainbowCursor, Terraria.Player.hasUnicornHorn, Terraria.GameContent.PlayerSittingHelper.isSitting, Terraria.Player.leinforsHair, Terraria.Player.Male, Terraria.ID.ArmorIDs.Shoe.Sets.MaleToFemaleID, Terraria.Player.neck, Terraria.Item.neckSlot, Terraria.Player.shield, Terraria.Item.shieldSlot, Terraria.Player.shoe, Terraria.Item.shoeSlot, Terraria.Player.sitting, Terraria.Item.stringColor, Terraria.Player.stringColor, Terraria.Player.tail, Terraria.Item.type, Terraria.Player.waist, Terraria.Item.waistSlot, Terraria.Player.wings, Terraria.Item.wingSlot, Terraria.Player.yoraiz0rDarkness, and Terraria.Player.yoraiz0rEye.

Referenced by Terraria.Player.UpdateVisibleAccessories(), and Terraria.Player.UpdateVisibleAccessories().

+ Here is the caller graph for this function: