Skip to content

OnFireworkDamage

Usage

  • Return a non-null value or bool to override default behavior

Example Autogenerated

csharp
private void OnFireworkDamage( BaseFirework instance, HitInfo info )
{
    Puts( "OnFireworkDamage works!" );
}

Location

  • BaseFirework::OnAttacked(HitInfo info)
csharp
//---
	base.OnAttacked(info);
	if (!base.isServer)
	{
		return;
	}
	if (Interface.CallHook("OnFireworkDamage", this, info) != null)
	{
		return;
	}
	if (info.damageTypes.Has(Rust.DamageType.Heat))
	{
//---

Released under the MIT License.