Botcraft
1.21.4
Loading...
Searching...
No Matches
EntitiesTasks.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include "
botcraft/AI/Status.hpp
"
4
#include "
botcraft/Game/Enums.hpp
"
5
6
namespace
Botcraft
7
{
8
class
BehaviourClient;
9
10
/// @brief Interact with a given entity. If too far, will try to pathfind to it.
11
/// @param client The client performing the action
12
/// @param entity_id The ID of the entity we want to interact with
13
/// @param hand The hand we want to use
14
/// @param swing If true, a swing packet will be sent too
15
/// @return Success if the entity is right clicked (does not mean the server accepted it though). Failure otherwise.
16
Status
InteractEntity
(BehaviourClient& client,
const
int
entity_id,
const
Hand
hand =
Hand::Main
,
const
bool
swing =
false
);
17
18
/// @brief Same thing as InteractEntity, but reads its parameters from the blackboard
19
/// @param client The client performing the action
20
/// @return Success if the entity is right clicked (does not mean the server accepted it though). Failure otherwise.
21
Status
InteractEntityBlackboard
(BehaviourClient& client);
22
}
Enums.hpp
Status.hpp
Botcraft
Definition
BaseNode.hpp:6
Botcraft::Status
Status
Definition
Status.hpp:6
Botcraft::InteractEntity
Status InteractEntity(BehaviourClient &client, const int entity_id, const Hand hand=Hand::Main, const bool swing=false)
Interact with a given entity.
Definition
EntitiesTasks.cpp:74
Botcraft::InteractEntityBlackboard
Status InteractEntityBlackboard(BehaviourClient &client)
Same thing as InteractEntity, but reads its parameters from the blackboard.
Definition
EntitiesTasks.cpp:91
Botcraft::Hand
Hand
Definition
Enums.hpp:150
Botcraft::Hand::Main
@ Main
botcraft
include
botcraft
AI
Tasks
EntitiesTasks.hpp
Generated by
1.9.8