OnItemRecycleAmount
Usage
- Return type int to prevent default behavior
Example Autogenerated
csharp
private int? OnItemRecycleAmount( Item slot, int num3, Recycler instance )
{
Puts( "OnItemRecycleAmount works!" );
return null;
}Location
- Recycler::RecycleThink()
csharp
//---
int num3 = 1;
if (slot.amount > 1)
{
num3 = Mathf.CeilToInt(Mathf.Min(slot.amount, (float)slot.MaxStackable() * 0.1f));
}
object obj = Interface.CallHook("OnItemRecycleAmount", slot, num3, this);
if (obj is int)
{
num3 = (int)obj;
}
if (slot.info.Blueprint.scrapFromRecycle > 0)
//---