NoMansSky:Reference Guides/Actions and Triggers

From Step Mods | Change The Game

TriggerAction[edit | edit source]

<Data template="GcTriggerActionComponentData">

Inside this environment we can have Actions and Triggers. If this environment has an ID, the TriggerAction can be called from a SimpleInteraction as well as a normal Interaction.

If you want the set of ActionTriggers to only be called upon interaction, the game has a reserved ID that is loaded when the object in created. This ID is BOOT. If you create an ActionTrigger with the ID BOOT it will be run when the object is created, but it will also block other actions from happening. Once you interact, the ActionTrigger specified will be run, and you can chain/branch ActionTriggers from there.

For example usages see this list.

Triggers[edit | edit source]

Trigger Description
GcStateTimeEvent Triggered after the specified number of seconds has passed. Use this with a time of 0s as a default trigger if the actual trigger is the StateID only.
GcBeenShotEvent Damage threshold can be set, and you can set whether the trigger occurs when the entity is shot by the ShotBy Types "Player" or "Anything".
GcPlayerNearbyEvent Triggered when the player is nearby. This has a number of different options. You can define trigger conditions as well: "None", "Fire", "InShip", "OnFoot", "OnFootOutside", "Upload". Has an inverse option so it can trigger when a player is not near and leaves.
GcCreatureNearbyEvent Triggered when a creature is nearby where the ENTITY is located. Can have a table with GcCreatureAlertData. Has an inverse option so it can trigger when a creature is not near or leaves.
GcAnimFrameEvent Triggered when a certain frame is reached in an Anim (TkAnimationData object)
GcStormEvent Triggered when a storm appears during game where the entity is located.

Actions[edit | edit source]

Action Description
GcPlayAudioAction Plays an audio file. Need to figure out whether it is just the name or what.
GcPlayAnimAction Plays an animation that is defined within the ~.ENTITY.mbin
GcGoToStateAction This seems to jump to another ActionTrigger by activating the defined StateID, so you can chain and activate multiple ActionTriggers from one. You can broadcast the StateID to other entities which are also part of the scene even as children of another node. Broadcast level can be "Scene", "LocalModel" or "Local".
You can also create action loops if you trigger a state that retriggers the primary trigger again. A GcRewardTrigger in the REWaRDTABLE can also trigger a StateID.
GcCameraShakeAction Shakes the camera. Has a couple of options.
GcPainAction Does damage to the player (not only). The value of Damage needs to be in the METADATA/REALITY/TABLES/DAMAGETABLE.mbin
You can also use damage types that only have a push effect and no damage like "JUSTPUSH".
GcNodeActivationAction You can use this to deactivate or activate components (nodes) of the object. The Name is the name of a TkSceneNodeData child in the entities parent ~.SCENE.mbin. You might be able to do lots of cool stuff with this by allowing triggered events to toggle components of the entity, which can also have attached .ENTITY.mbin’s.
Options for NodeActiveState: "Activate", "Deactivate", "Toggle", "Add", "Remove", "RemoveChildren"
By using "Activate", "Deactivate" and "Toggle" state options you can enable a ENTITY and it's components on demand. That implies a lot of usage possibilities.
GcPainAction Does damage to the player (not only). The value of Damage needs to be in the METADATA/REALITY/TABLES/DAMAGETABLE.mbin
You can also use damage types that only have a push effect and no damage like "JUSTPUSH".

Template:NMSPageClose