mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
AuotoAttack: add support for multiple interact modes (#2044)
* Adds support for multiple interact modes * Entity interaction: Implement enum Co-authored-by: ORelio <ORelio@users.noreply.github.com>
This commit is contained in:
parent
fd7f79402f
commit
613f52d3ae
8 changed files with 116 additions and 80 deletions
|
|
@ -1190,7 +1190,20 @@ namespace MinecraftClient
|
|||
/// <param name="type">0: interact, 1: attack, 2: interact at</param>
|
||||
/// <param name="hand">Hand.MainHand or Hand.OffHand</param>
|
||||
/// <returns>TRUE in case of success</returns>
|
||||
[Obsolete("Prefer using InteractType enum instead of int for interaction type")]
|
||||
protected bool InteractEntity(int EntityID, int type, Hand hand = Hand.MainHand)
|
||||
{
|
||||
return Handler.InteractEntity(EntityID, (InteractType)type, hand);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Interact with an entity
|
||||
/// </summary>
|
||||
/// <param name="EntityID"></param>
|
||||
/// <param name="type">Interaction type (InteractType.Interact, Attack or AttackAt)</param>
|
||||
/// <param name="hand">Hand.MainHand or Hand.OffHand</param>
|
||||
/// <returns>TRUE in case of success</returns>
|
||||
protected bool InteractEntity(int EntityID, InteractType type, Hand hand = Hand.MainHand)
|
||||
{
|
||||
return Handler.InteractEntity(EntityID, type, hand);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue