2023-01-13 21:13:57 +01:00
|
|
|
|
2023-01-13 21:29:17 +01:00
|
|
|
#include "gsai_agent_location.h"
|
2023-01-13 21:13:57 +01:00
|
|
|
|
|
|
|
Vector3 GSAIAgentLocation::get_position() {
|
2023-01-13 21:35:07 +01:00
|
|
|
return position;
|
2023-01-13 21:13:57 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
void GSAIAgentLocation::set_position(const Vector3 &val) {
|
2023-01-13 21:35:07 +01:00
|
|
|
position = val;
|
2023-01-13 21:13:57 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
float GSAIAgentLocation::get_orientation() const {
|
2023-01-13 21:35:07 +01:00
|
|
|
return orientation;
|
2023-01-13 21:13:57 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
void GSAIAgentLocation::set_orientation(const float val) {
|
2023-01-13 21:35:07 +01:00
|
|
|
orientation = val;
|
2023-01-13 21:13:57 +01:00
|
|
|
}
|
|
|
|
|
2023-01-13 21:35:07 +01:00
|
|
|
GSAIAgentLocation::GSAIAgentLocation() {
|
|
|
|
orientation = 0.0;
|
|
|
|
}
|
2023-01-13 21:13:57 +01:00
|
|
|
|
2023-01-13 21:35:07 +01:00
|
|
|
GSAIAgentLocation::~GSAIAgentLocation() {
|
|
|
|
}
|
2023-01-13 21:13:57 +01:00
|
|
|
|
2023-01-13 23:01:38 +01:00
|
|
|
void GSAIAgentLocation::_bind_methods() {
|
2023-01-13 21:35:07 +01:00
|
|
|
ClassDB::bind_method(D_METHOD("get_position"), &GSAIAgentLocation::get_position);
|
|
|
|
ClassDB::bind_method(D_METHOD("set_position", "value"), &GSAIAgentLocation::set_position);
|
|
|
|
ADD_PROPERTY(PropertyInfo(Variant::VECTOR3, "position"), "set_position", "get_position");
|
2023-01-13 21:13:57 +01:00
|
|
|
|
2023-01-13 21:35:07 +01:00
|
|
|
ClassDB::bind_method(D_METHOD("get_orientation"), &GSAIAgentLocation::get_orientation);
|
|
|
|
ClassDB::bind_method(D_METHOD("set_orientation", "value"), &GSAIAgentLocation::set_orientation);
|
|
|
|
ADD_PROPERTY(PropertyInfo(Variant::REAL, "orientation"), "set_orientation", "get_orientation");
|
|
|
|
}
|