Elevator (6)

All currently available hooks that are found in Carbon. Most hooks would be ones compatible with Oxide, although there are Carbon-only ones as well.

CanElevatorLiftMove

  • Returning a non-null value cancels default behavior.

  • This hook is compatible within Carbon and Oxide.

  • Patches ElevatorLift.CanMove of Assembly-CSharp.dll.

Example
object CanElevatorLiftMove(ElevatorLift ElevatorLift )
{
    Puts("CanElevatorLiftMove was called!");
    return (bool) null;
}

OnElevatorButtonPress

  • Called when a player presses a button on an elevator lift.

  • Returning a non-null value cancels default behavior.

  • This hook is compatible within Carbon and Oxide.

  • Patches ElevatorLift.Server_RaiseLowerFloor of Assembly-CSharp.dll.

Example
object OnElevatorButtonPress(ElevatorLift ElevatorLift , BasePlayer BasePlayer , Elevator.Direction Direction , bool Boolean )
{
    Puts("OnElevatorButtonPress was called!");
    return (object) null;
}

OnElevatorCall

  • Called when an elevator lift is called to a specific floor by electricity.

  • Returning a non-null value cancels default behavior.

  • This hook is compatible within Carbon and Oxide.

  • Patches Elevator.b__26_0 of Assembly-CSharp.dll.

Example
object OnElevatorCall(Elevator Elevator , Elevator Elevator )
{
    Puts("OnElevatorCall was called!");
    return (object) null;
}
  • Called right before an elevator starts moving to the target floor.

  • Returning a non-null value cancels default behavior.

  • This hook is compatible within Carbon and Oxide.

  • Patches Elevator.RequestMoveLiftTo of Assembly-CSharp.dll.

Example
void OnElevatorMove()
{
    Puts("OnElevatorMove was called!");
}
  • Called when a player calls a lift or procedural lift.

  • Returning a non-null value cancels default behavior.

  • This hook is compatible within Carbon and Oxide.

  • Patches Lift.RPC_UseLift of Assembly-CSharp.dll.

Example
object OnLiftUse(Lift Lift , BasePlayer BasePlayer )
{
    Puts("OnLiftUse was called!");
    return (object) null;
}
  • Called when a player calls a lift or procedural lift.

  • Returning a non-null value cancels default behavior.

  • This hook is compatible within Carbon and Oxide.

  • Patches ProceduralLift.RPC_UseLift of Assembly-CSharp.dll.

Example
object OnLiftUse(ProceduralLift ProceduralLift , BasePlayer BasePlayer )
{
    Puts("OnLiftUse was called!");
    return (object) null;
}

Last updated