Skip to content

OnFuelAmountCheck

Usage

  • Return a int value to override default behavior

Example Autogenerated

csharp
private int? OnFuelAmountCheck( EntityFuelSystem instance, Item fuelItem )
{
    Puts( "OnFuelAmountCheck works!" );
    return null;
}

Location

  • EntityFuelSystem::GetFuelAmount()
csharp
public int GetFuelAmount()
{
	Item fuelItem = this.GetFuelItem();
	object returnvar = Interface.CallHook("OnFuelAmountCheck", this, fuelItem);
	if (returnvar is int)
	{
		return (int)returnvar;
	}
	if (fuelItem == null || fuelItem.amount < 1)
//---

Released under the MIT License.