11 [
RplProp(onRplName:
"OnPreWaypointIdRpl")]
12 protected RplId m_PrevWaypointId;
15 protected bool m_bIsCurrent;
18 protected int m_iIndex;
26 [
RplProp(onRplName:
"OnAttachedToId")]
44 m_AIWaypoint.GetParent().RemoveChild(m_AIWaypoint,
true);
50 if (
m_AttachedTo.GetAttachedEntities().Count() >= EditorConstants.MAX_ATTACHED_ENTITIES)
56 m_AIWaypoint.SetOrigin(
vector.Zero);
69 entityWaypoint.SetEntity(null);
91 m_bIsCurrent = isCurrent;
92 m_PrevWaypoint = prevWaypoint;
93 m_PrevWaypointId =
Replication.FindItemId(prevWaypoint);
119 return m_PrevWaypoint;
131 override bool CanDuplicate(out notnull set<SCR_EditableEntityComponent> outRecipients)
135 outRecipients.Insert(groupComponent);
165 AttachTo(parentEntity);
170 super.OnParentEntityChanged(parentEntityPrev, parentEntityPrev, changedByUser);
195 return super.SetTransform(transform, changedByUser);
202 super.SetTransformBroadcast(transform);
217 return super.GetPos(pos);
238 return super.CanSetParent(parentEntity);
246 AIGroup group = AIGroup.Cast(recipient.GetOwner());
252 if (editableGroup && !editableGroup.AreCycledWaypointsEnabled())
253 editableGroup.ClearWaypoints();
256 group.AddWaypoint(AIWaypoint.Cast(
GetOwner()));
270 AIGroup aiGroup = AIGroup.Cast(
m_Group.GetOwner());
272 aiGroup.RemoveWaypoint(AIWaypoint.Cast(owner));
SCR_EAIThreatSectorFlags flags
SCR_AIGroupSettingsComponentClass m_Group
enum EAIGroupCombatMode ComponentEditorProps(category:"GameScripted/AI", description:"Component for utility AI system for groups")
SCR_CacheNoteComponentClass ScriptComponentClass RplProp()] protected ref array< string > m_aLines
SCR_DestructionSynchronizationComponentClass ScriptComponentClass int index
void SCR_EditableGroupComponent(IEntityComponentSource src, IEntity ent, IEntity parent)
void OnAttachedToId()
Runs when an ID is attached.
SCR_EditableEntityComponent m_AttachedTo
SCR_EditableEntityComponent GetPrevWaypoint()
SCR_AIWaypoint GetAIWaypoint()
void SCR_EditableWaypointComponent(IEntityComponentSource src, IEntity ent, IEntity parent)
void OnPreWaypointIdRpl()
void DetachFromTarget()
Detach the waypoint from the target, runs both in client and server.
void SetWaypointIndex(int index, bool isCurrent, SCR_EditableEntityComponent prevWaypoint)
Replication item identifier.
void SetTransformBroadcast(vector transform[4])
override void OnDelete(IEntity owner)
bool SetTransform(vector transform[4], bool changedByUser=false)
SCR_EditableEntityComponent EOnEditorPlace(out SCR_EditableEntityComponent parent, SCR_EditableEntityComponent recipient, EEditorPlacingFlags flags, bool isQueue, int playerID=0)
SCR_EditableEntityComponent GetAttachedTo()
void OnParentEntityChanged(SCR_EditableEntityComponent parentEntity, SCR_EditableEntityComponent parentEntityPrev, bool changedByUser)
bool GetPos(out vector pos)
EEditableEntityType GetEntityType(IEntity owner=null)
bool CanSetParent(SCR_EditableEntityComponent parentEntity)
bool CanDuplicate(out notnull set< SCR_EditableEntityComponent > outRecipients)
SCR_EditableEntityComponent GetAIGroup()
static int GetLocalPlayerId()
Returns either a valid ID of local player or 0.
proto external GenericEntity GetOwner()
Get owner entity.
IEntity GetOwner()
Owner entity of the fuel tank.
EEditableEntityType
Defines type of SCR_EditableEntityComponent. Assigned automatically based on IEntity inheritance.