public override void EntityInteraction(Entity player, Entity target, ItemUseOnEntityAction action, int hand, int slot) { switch (action) { case ItemUseOnEntityAction.Interact: { var packet = new InteractEntityPacket(); packet.EntityId = (int)target.EntityId; packet.Type = 0; packet.Hand = hand; packet.Sneaking = player.IsSneaking; Client.SendPacket(packet); } break; case ItemUseOnEntityAction.Attack: { var packet = new InteractEntityPacket(); packet.EntityId = (int)target.EntityId; packet.Type = 1; packet.Hand = hand; packet.Sneaking = player.IsSneaking; Client.SendPacket(packet); } break; case ItemUseOnEntityAction.ItemInteract: break; } }
public override void EntityInteraction(Entity player, Entity target, ItemUseOnEntityAction action, int hand, int slot) { }
public abstract void EntityInteraction(Entity player, Entity target, ItemUseOnEntityAction action);
public abstract void EntityInteraction(Entity player, Entity target, ItemUseOnEntityAction action, int hand, int slot);
public override void EntityInteraction(Entity player, Entity target, ItemUseOnEntityAction action) { }