Skip to content

CanWearItem

Usage

  • Return a non-null value to override default behavior

Example Autogenerated

csharp
private void CanWearItem( PlayerInventory instance, Item item, int targetSlot )
{
    Puts( "CanWearItem works!" );
}

Location

  • PlayerInventory::CanWearItem(Item item, int targetSlot)
csharp
private bool CanWearItem(Item item, int targetSlot)
{
	object returnvar = Interface.CallHook("CanWearItem", this, item, targetSlot);
	if (returnvar is bool)
	{
		return (bool)returnvar;
	}
	return this.CanWearItem(item, true, targetSlot);
//---

Released under the MIT License.