Skip to content

OnFireBallSpread

Usage

  • No return behavior

Example Autogenerated

csharp
private void OnFireBallSpread( FireBall instance, BaseEntity baseEntity )
{
    Puts( "OnFireBallSpread works!" );
}

Location

  • FireBall::TryToSpread()
csharp
//---
		{
			baseEntity.transform.position = base.transform.position + Vector3.up * 0.25f;
			baseEntity.Spawn();
			Vector3 modifiedAimConeDirection = AimConeUtil.GetModifiedAimConeDirection(45f, Vector3.up, true);
			baseEntity.creatorEntity = ((this.creatorEntity == null) ? baseEntity : this.creatorEntity);
			Interface.CallHook("OnFireBallSpread", this, baseEntity);
			baseEntity.SetVelocity(modifiedAimConeDirection * UnityEngine.Random.Range(5f, 8f));
			baseEntity.SendMessage("SetGeneration", this.generation + 1f);
		}
	}
}

Released under the MIT License.