OnSensorDetect
Usage
- No return behavior
Example Autogenerated
csharp
private void OnSensorDetect( )
{
Puts( "OnSensorDetect works!" );
}
Location
- HBHFSensor::UpdatePassthroughAmount()
csharp
//---
foreach (BaseEntity current in this.myTrigger.entityContents)
{
if (!(current == null) && current.IsVisible(base.transform.position + base.transform.forward * 0.1f, 10f))
{
BasePlayer component = current.GetComponent<BasePlayer>();
if (Interface.CallHook("OnSensorDetect", this, component) == null)
{
bool flag = component.CanBuild();
if ((!flag || this.ShouldIncludeAuthorized()) && (flag || this.ShouldIncludeOthers()) && component != null && component.IsAlive() && !component.IsSleeping() && component.isServer)
{
this.detectedPlayers++;
//---