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

◆ AccCheck()

static bool Terraria.UI.ItemSlot.AccCheck ( Item[] itemCollection,
Item item,
int slot )
inlinestatic

Definition at line 3036 of file ItemSlot.cs.

3037 {
3038 if (isEquipLocked(item.type))
3039 {
3040 return true;
3041 }
3042 if (slot != -1)
3043 {
3044 if (itemCollection[slot].IsTheSameAs(item))
3045 {
3046 return false;
3047 }
3048 if (itemCollection[slot].wingSlot > 0 && item.wingSlot > 0)
3049 {
3050 return false;
3051 }
3052 }
3053 for (int i = 0; i < itemCollection.Length; i++)
3054 {
3055 if (slot < 10 && i < 10)
3056 {
3057 if (item.wingSlot > 0 && itemCollection[i].wingSlot > 0)
3058 {
3059 return true;
3060 }
3061 if (slot >= 10 && i >= 10 && item.wingSlot > 0 && itemCollection[i].wingSlot > 0)
3062 {
3063 return true;
3064 }
3065 }
3066 if (item.IsTheSameAs(itemCollection[i]))
3067 {
3068 return true;
3069 }
3070 }
3071 return false;
3072 }
static bool isEquipLocked(int type)
Definition ItemSlot.cs:358

References Terraria.UI.ItemSlot.isEquipLocked(), Terraria.Item.IsTheSameAs(), Terraria.Item.type, and Terraria.Item.wingSlot.

Referenced by Terraria.UI.ItemSlot.PickItemMovementAction(), and Terraria.GameContent.Tile_Entities.TEDisplayDoll.TryFitting().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: