Skip to content

CanHackCrate

Usage

  • Return a non-null value to override default behavior

Example Autogenerated

csharp
private void CanHackCrate( BasePlayer player, HackableLockedCrate instance )
{
    Puts( "CanHackCrate works!" );
}

Location

  • HackableLockedCrate::RPC_Hack(BaseEntity/RPCMessage msg)
csharp
//---
{
	if (this.IsBeingHacked())
	{
		return;
	}
	if (Interface.CallHook("CanHackCrate", msg.player, this) != null)
	{
		return;
	}
	Facepunch.Rust.Analytics.Azure.OnLockedCrateStarted(msg.player, this);
	this.originalHackerPlayerId = msg.player.userID;
//---

Released under the MIT License.