6 override bool CanBeShown(
SCR_EditableEntityComponent hoveredEntity, notnull set<SCR_EditableEntityComponent> selectedEntities, vector cursorWorldPosition,
int flags)
22 BaseActionsManagerComponent actionsManager = BaseActionsManagerComponent.Cast(hoveredEntity.GetOwnerScripted().FindComponent(BaseActionsManagerComponent));
23 if (!actionsManager || actionsManager.GetActionsCount() != 1)
33 info.SetName(action.GetActionName());
37 override bool CanBePerformed(
SCR_EditableEntityComponent hoveredEntity, notnull set<SCR_EditableEntityComponent> selectedEntities, vector cursorWorldPosition,
int flags)
39 return CanBeShown(hoveredEntity, selectedEntities, cursorWorldPosition, flags);
41 override void Perform(
SCR_EditableEntityComponent hoveredEntity, notnull set<SCR_EditableEntityComponent> selectedEntities, vector cursorWorldPosition,
int flags,
int param = -1)
47 if (!IsServer() && hoveredEntity)
56 IEntity owner = hoveredEntity.GetOwnerScripted();
60 BaseActionsManagerComponent actionsManager = BaseActionsManagerComponent.Cast(owner.FindComponent(BaseActionsManagerComponent));
61 if (!actionsManager || actionsManager.GetActionsCount() != 1)
70 manager.PerformFirstAction(owner);