14 protected static const string ANIM_EVENT_NAME_FIRE =
"Character_RefreshIK";
15 protected static const string VAR_CAN_BE_HELD_NAME =
"m_bCanBeHeld";
26 if (slot.GetAttachedEntity())
38 SCR_GadgetComponent gadget = SCR_GadgetComponent.Cast(item.
FindComponent(SCR_GadgetComponent));
39 if (!gadget || !gadget.CanBeHeld())
52 if (!entityResource.IsValid())
64 for (
int i, componentsCount = entitySrc.GetComponentCount(); i < componentsCount; i++)
66 componentSrc = entitySrc.GetComponent(i);
70 if (!componentSrc.GetClassName().ToType().IsInherited(SCR_GadgetComponent))
74 return componentSrc.Get(VAR_CAN_BE_HELD_NAME, canBeHeld) && canBeHeld &&
GetEmptySlotForItem(null);
98 super.OnAddedToSlot(item, slotID);
142 CharacterControllerComponent controller = character.GetCharacterController();
146 SCR_InventoryStorageManagerComponent storageManager = SCR_InventoryStorageManagerComponent.Cast(controller.GetInventoryStorageManager());
232 super.OnRemovedFromSlot(item, slotID);
238 super.OnManagerChanged(manager);
240 SCR_InventoryStorageManagerComponent scrMgr = SCR_InventoryStorageManagerComponent.Cast(manager);
ResourceName resourceName
enum EAIGroupCombatMode ComponentEditorProps(category:"GameScripted/AI", description:"Component for utility AI system for groups")
override bool CanStoreItem(IEntity item, int slotID)
RplComponent m_RplComponent
IEntity GetSlot(IEntity occupant)
void SkipAnimation_S()
Authority method used to inform others that this entity should skip the wait for the pick up animatio...
SCR_CharacterInventoryStorageComponent m_CharacterInventory
void SkipAnimation()
When animation is not used then this will remove itself from animation event script invoker and conti...
AnimationEventID m_iGestureAnimationEndEvent
IEntity GetHandSlotItem()
SCR_HandSlotStorageComponentClass m_bSkipNextWaitForAnimation
void DelayedOnAddedToSlot(IEntity item)
void RPC_DoSkipAnimation()
void SCR_UniversalInventoryStorageComponent(IEntityComponentSource src, IEntity ent, IEntity parent)
proto external Managed FindComponent(typename typeName)
Object holding reference to resource. In destructor release the resource.
ScriptInvoker GetOnAnimationEvent()
static RplComponent GetEntityRplComponent(notnull IEntity entity)
IEntity GetOwner()
Owner entity of the fuel tank.
event void OnAnimationEvent(AnimationEventID animEventType, AnimationEventID animUserString, int intParam, float timeFromStart, float timeToEnd)
void OnRemovedFromSlot(IEntity item, int slotID)
event bool CanStoreResource(ResourceName resourceName, int slotID)
Implemented logics for can insert here, Manager will provide slotID of -1 in case slot is irrelevant.
proto external int GetSlotsCount()
Returns the number of slots in this storage.
event bool CanReplaceItem(IEntity nextItem, int slotID)
Implemented logics for can replace to nextItem at slotID,.
void OnAddedToSlot(IEntity item, int slotID)
void OnManagerChanged(InventoryStorageManagerComponent manager)
InventoryStorageSlot GetEmptySlotForItem(IEntity item)
Usually any slot that item can be inserted to.
void RplRpc(RplChannel channel, RplRcver rcver, RplCondition condition=RplCondition.None, string customConditionName="")
RplChannel
Communication channel. Reliable is guaranteed to be delivered. Unreliable not.