mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-12-24 20:57:18 +01:00
Added Behaviors to the build.
This commit is contained in:
parent
693ec871e5
commit
967918fbe0
@ -19,6 +19,21 @@ sources = [
|
||||
|
||||
"proximities/gsai_radius_proximity.cpp",
|
||||
"proximities/gsai_infinite_proximity.cpp",
|
||||
|
||||
"behaviors/gsai_arrive.cpp",
|
||||
"behaviors/gsai_avoid_collisions.cpp",
|
||||
"behaviors/gsai_blend.cpp",
|
||||
"behaviors/gsai_cohesion.cpp",
|
||||
"behaviors/gsai_evade.cpp",
|
||||
"behaviors/gsai_face.cpp",
|
||||
"behaviors/gsai_flee.cpp",
|
||||
"behaviors/gsai_follow_path.cpp",
|
||||
"behaviors/gsai_look_where_you_go.cpp",
|
||||
"behaviors/gsai_match_orientation.cpp",
|
||||
"behaviors/gsai_priority.cpp",
|
||||
"behaviors/gsai_pursue.cpp",
|
||||
"behaviors/gsai_seek.cpp",
|
||||
"behaviors/gsai_separation.cpp",
|
||||
]
|
||||
|
||||
|
||||
|
@ -44,9 +44,7 @@ bool GSAIAvoidCollisions::_report_neighbor(Ref<GSAISteeringAgent> neighbor) {
|
||||
|
||||
if (relative_speed_squared == 0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
else {
|
||||
} else {
|
||||
float time_to_collision = -relative_position.dot(relative_velocity) / relative_speed_squared;
|
||||
|
||||
if (time_to_collision <= 0 || time_to_collision >= _shortest_time) {
|
||||
|
@ -18,6 +18,21 @@ def get_doc_classes():
|
||||
|
||||
"GSAIRadiusProximity",
|
||||
"GSAIInfiniteProximity",
|
||||
|
||||
"GSAIArrive",
|
||||
"GSAIAvoidCollisions",
|
||||
"GSAIBlend",
|
||||
"GSAICohesion",
|
||||
"GSAIEvade",
|
||||
"GSAIFace",
|
||||
"GSAIFlee",
|
||||
"GSAIFollowPath",
|
||||
"GSAILookWhereYouGo",
|
||||
"GSAIMatchOrientation",
|
||||
"GSAIPriority",
|
||||
"GSAIPursue",
|
||||
"GSAISeek",
|
||||
"GSAISeparation",
|
||||
]
|
||||
|
||||
def get_doc_path():
|
||||
|
@ -35,8 +35,23 @@ SOFTWARE.
|
||||
#include "gsai_target_acceleration.h"
|
||||
#include "proximities/gsai_proximity.h"
|
||||
|
||||
#include "proximities/gsai_radius_proximity.h"
|
||||
#include "proximities/gsai_infinite_proximity.h"
|
||||
#include "proximities/gsai_radius_proximity.h"
|
||||
|
||||
#include "behaviors/gsai_arrive.cpp"
|
||||
#include "behaviors/gsai_avoid_collisions.cpp"
|
||||
#include "behaviors/gsai_blend.cpp"
|
||||
#include "behaviors/gsai_cohesion.cpp"
|
||||
#include "behaviors/gsai_evade.cpp"
|
||||
#include "behaviors/gsai_face.cpp"
|
||||
#include "behaviors/gsai_flee.cpp"
|
||||
#include "behaviors/gsai_follow_path.cpp"
|
||||
#include "behaviors/gsai_look_where_you_go.cpp"
|
||||
#include "behaviors/gsai_match_orientation.cpp"
|
||||
#include "behaviors/gsai_priority.cpp"
|
||||
#include "behaviors/gsai_pursue.cpp"
|
||||
#include "behaviors/gsai_seek.cpp"
|
||||
#include "behaviors/gsai_separation.cpp"
|
||||
|
||||
static GSAIUtils *gs_ai_utils = NULL;
|
||||
|
||||
@ -55,6 +70,21 @@ void register_steering_ai_types() {
|
||||
|
||||
ClassDB::register_class<GSAIRadiusProximity>();
|
||||
ClassDB::register_class<GSAIInfiniteProximity>();
|
||||
|
||||
ClassDB::register_class<GSAIArrive>();
|
||||
ClassDB::register_class<GSAIAvoidCollisions>();
|
||||
ClassDB::register_class<GSAIBlend>();
|
||||
ClassDB::register_class<GSAICohesion>();
|
||||
ClassDB::register_class<GSAIEvade>();
|
||||
ClassDB::register_class<GSAIFace>();
|
||||
ClassDB::register_class<GSAIFlee>();
|
||||
ClassDB::register_class<GSAIFollowPath>();
|
||||
ClassDB::register_class<GSAILookWhereYouGo>();
|
||||
ClassDB::register_class<GSAIMatchOrientation>();
|
||||
ClassDB::register_class<GSAIPriority>();
|
||||
ClassDB::register_class<GSAIPursue>();
|
||||
ClassDB::register_class<GSAISeek>();
|
||||
ClassDB::register_class<GSAISeparation>();
|
||||
}
|
||||
|
||||
void unregister_steering_ai_types() {
|
||||
|
Loading…
Reference in New Issue
Block a user