Skip to content

OnCupboardClearList

Usage

  • Return a non-null value to override default behavior

Example Autogenerated

csharp
private object OnCupboardClearList( VehiclePrivilege instance, BasePlayer player )
{
    Puts( "OnCupboardClearList works!" );
    return null;
}

Location

  • VehiclePrivilege::ClearList(BaseEntity.RPCMessage rpc)
csharp
[RPC_Server]
[RPC_Server.MaxDistance(3f)]
private void ClearList(RPCMessage rpc)
{
	if (rpc.player.CanInteract() && CanModifyAuth(rpc.player) && Interface.CallHook("OnCupboardClearList", this, rpc.player) == null)
	{
		authorizedPlayers.Clear();
		UpdateMaxAuthCapacity();
		UpdatePrivilegeReceivers();
		SendNetworkUpdate();
//---

Released under the MIT License.