Trigger Actions
BETAS adds 29 new Trigger Actions to the game for you to use. Not all of them will be useful without using the new Triggers or new Game State Queries added by BETAS, but just like other trigger actions, you can use them in dialogue, letters, etc. as you see fit. If a parameter is wrapped in < >
then it is a required parameter. If the parameter is wrapped in []
then it is an optional parameter. If the parameter has a +
after it, that means you can provide multiple of that parameter separated by spaces.
These trigger actions, unless otherwise stated, support the Tokenizable Strings added by BETAS. All of these trigger actions are also automatically registered as Map Actions, too.
ACTION | EFFECT |
---|---|
Spiderbuttons.BETAS_AddExperience
[<Amount]>+ [<Skill]>+ | Add Amount experience (default 1) to the current player. Skill can be any one of Farming , Fishing , Foraging , Mining , Combat , Luck , or a SpaceCore skill ID. If no Skill is provided, the player will gain Amount experience in all skills. |
Spiderbuttons.BETAS_EmoteFarmer
[<EmoteId]>+ | Cause an emote bubble for the given EmoteId to appear above the current player's head. |
Spiderbuttons.BETAS_EmoteNpc
[<NPC]>+ [<EmoteId]>+ | Cause an emote bubble for the given EmoteId to appear above the head of the given NPC . |
Spiderbuttons.BETAS_Lightning
[<X]>+ [<Y]>+ | Cause a lightning strike to happen at the given X and Y coordinates on the current map. This lightning is purely cosmetic and will not actually damage anything. If no coordinates are specified, the lightning will strike at the player's position. |
Spiderbuttons.BETAS_MakeMachineReady
[<MachineId]>+ [<OutputId]>+ [<Location]>+ [<Count]>+ | Cause one or more machines in one or more locations to instantly finish producing their output. MachineId should be the item ID of the machine you want to target if you only want to target specific ones (e.g. only furnaces)—set it to Any for any machine. OutputId should be the qualified item ID of the output item if you only want to finish specific items (e.g. only mayonaisse)—set it to Any for any output item. Location should be the name of the location you want to look for machines in—set it to All if you want to search everywhere. Count should be the number of machines you want to instantly finish—set it to -1 for unlimited. |
Spiderbuttons.BETAS_SetNewDialogue
[<NPC]>+ [<Dialogue]>+ [<Add?]>+ | Add a new line of dialogue to the given NPC . The Dialogue can be a literal string of dialogue text (dialogue commands and formatting are supported), a LocalizedText tokenizable string, or a translation key (e.g. Characters/Dialogue/Haley:Resort_Leaving ). Remember to wrap the dialogue in escaped quotes as necessary. The Add (default false) parameter is a boolean value that determines whether the currently existing dialogue for the given NPC will be overwritten (false) or if the new Dialogue will be added in front of the existing dialogue (true). Note that regardless of what you do, Conversation Topic dialogue and Scheduled Location dialogue will have priority over your added dialogue. |
Spiderbuttons.BETAS_TextAboveHead
[<NPC]>+ [<Dialogue]>+ [<Duration]>+ [<Delay]>+ [<Jitter?]>+ [<Colour]>+ | Cause a speech bubble to appear above the given NPC that contains the Dialogue . The Dialogue can be a literal string (dialogue commands and formatting are not supported) or a LocalizedText tokenizable string. Remember to wrap the dialogue in escaped quotes as necessary. The speech bubble will last for Duration milliseconds (default 3000) and wait Delay milliseconds (default 0) before appearing. If Jitter (default false) is set to true, the speech bubble will shake. The Colour parameter (default #56160C) controls the colour of the text. |
Spiderbuttons.BETAS_WarpFarmer
[<Location]>+ [<X]>+ [<Y]>+ [<FacingDirection]>+ | Warp the current player to the X and Y tile coordinates in the given Location . The FacingDirection (default 2) determines where the player will be facing after the warp. Warps leading inside the FarmHouse may not always work correctly. |
Spiderbuttons.BETAS_WarpNpc
[<NPC]>+ [<Location]>+ [<X]>+ [<Y]>+ [<FacingDirection]>+ | Warp the given NPC to the X and Y tile coordinates in the given Location . The FacingDirection (default 2) determines where the NPC will be facing after the warp. Warps leading inside the FarmHouse may not always work correctly. |
Spiderbuttons.BETAS_UpdateAppearance
[<NPC]>+ [<Id]>+ | Force the NPC to choose their appearance again from their list of Appearances in their Data/Characters data. If you provide the Id of a specific appearance in the list, the NPC will change to that appearance regardless of the conditions that appearance normally requires and regardless of any other appearances with higher precedence or weight. For FarmHands, this will only work if they are in the same location as theNPC . |
Spiderbuttons.BETAS_ChangeMusicTrack
[<Track]>+ | Change the currently playing music to the music with the given Track name. |
Spiderbuttons.BETAS_EatObject
[<ItemId]>+ [<From Inventory?]>+ | Make the player eat (or drink) an object with the given ItemId , which can be qualified or unqualified. This will only work for objects whose edibility is not -300 . If From Inventory (default true) is set to false, then the player will not need to have the object in their inventory to actually eat it. Otherwise, the action will do nothing if they don't have at least one of the object to eat. |
Spiderbuttons.BETAS_ReloadItemField
[<ItemId]>+ [<Field]>+ | Update the given Field of every item with a matching ItemId in the world to match the value that a newly spawned item would have. |
Spiderbuttons.BETAS_SetHealth
[<Value]>+ [<Override?]>+ | Set the current health of the current player to the given Value . If Override? (default false) is set to true , the players health will be allowed to go beyond their maximum health. |
Spiderbuttons.BETAS_SetStamina
[<Value]>+ [<Override?]>+ | Set the current stamina of the current player to the given Value . If Override? (default false) is set to true , the players stamina will be allowed to go beyond their maximum stamina. |
Spiderbuttons.BETAS_RandomAction
[<Action String]>+ | When given a list of quoted Action Strings , this will randomly choose one of the actions to execute. |
Spiderbuttons.BETAS_DelayedAction
[<Action String]>+ [<Delay]>+ | Execute the given Action String only after Delay milliseconds have passed. |
Spiderbuttons.BETAS_FadeToBlack
[<Duration]>+ | Fade the player's screen to black, keep it black for Duration milliseconds, and then fade to clear again. |
Spiderbuttons.BETAS_SetFriendshipPoints
[<NPC]>+ [<Points]>+ | Set the current number of friendship points that a player has with a given NPC to the number of Points provided. |
Spiderbuttons.BETAS_RegionalFriendship
[<HomeRegion]>+ [<Amount]>+ [<Set?]>+ | For the current player, add the given Amount of friendship points to every NPC who lives in the given HomeRegion . If Set (default false) is set to true , then the friendship level of those NPCs will be set to the exact Amount specified, rather than adding or subtracting it. |
Spiderbuttons.BETAS_WeatherForTomorrow
[<ContextID]>+ [<Weather]>+ | Force the specified location ContextID to have the given Weather on the following day. Weather can be one of GreenRain , Rain , Snow , Storm , Sun , Wind , or a custom weather ID. This action will not override days with hardcoded weather (festivals, weddings, etc). |
Spiderbuttons.BETAS_Message
[<Text]>+ | Display a simple dialogue box with the given Text on the screen, similar to using the Message map action. The Text can either be a raw string or a translation key (e.g. Characters/Dialogue/Haley:Resort_Leaving ). |
Spiderbuttons.BETAS_DialogueBox
[<NPC]>+ [<Message]>+ [<Portrait]>+ [<DisplayName]>+ | Display a dialogue box on the screen with the given Message in it, as if the player was talking to the given NPC . The Message can either be the quoted string message itself, a translation key like Characters/Dialogue/Haley:Resort_Leaving , or a LocalizedText tokenizable string. The given NPC does not actually need to exist for the dialogue box to appear, however if they do not exist there will be no portrait displayed without specifying an asset name (e.g. Portraits/Haley but any asset will work) for the Portrait (default Null ) parameter. You may also use the Portrait parameter to force a different portrait even if the given NPC does exist (i.e. you can open a Haley dialogue box but with Abigail's portrait), or write None if you want to omit the portrait entirely. If you write Null for the portrait, it will default to the portraits of the given NPC if they exist. Portrait dialogue commands in the Message will change the portrait if they are able to. If you specify a DisplayName , then that name will be used for the dialogue box regardless of the actual name of the NPC . These dialogue boxes do not count for actually talking to the NPC, and question-and-response dialogue will not work. |
Spiderbuttons.BETAS_ShakeNpc
[<NPC]>+ [<Duration]>+ | Make the given NPC (default All ) shake for Duration milliseconds (default 1000). If no NPC is specified or you write All instead of a name, every NPC in the current location will shake. |
Spiderbuttons.BETAS_AddQiCoins
[<Amount]>+ | Add the given Amount (default 1) of Qi Coins to the current player. |
Spiderbuttons.BETAS_AddFestivalScore
[<Amount]>+ | Add the given Amount (default 1) of festival score (fish caught, eggs found, star tokens, etc.) to the current player. |
Spiderbuttons.BETAS_PatchUpdate
[<UniqueID]>+ | Force Content Patcher to immediately refresh all of its tokens and reload patches as necessary. If a mod's UniqueID is provided, it will only refresh tokens for that mod. This action requires Content Patcher to be installed to function. |
Spiderbuttons.BETAS_WritePlayerModData
[<Key]>+ [<Value]>+ | Write the given Value to the mod data dictionary of the current player and assigns it the given Key . |
Spiderbuttons.BETAS_RemovePlayerModData
[<Key]>+ [<Value]>+ | Remove the mod data dictionary entry with the given Key from the current player. If no Value is provided, it will remove any mod data that exists for that Key . If a Value is provided, it will only remove the mod data if the already existing value in the dictionary matches the given Value . |
Spiderbuttons.BETAS_ClearTerrainFeatures
[<Location]>+ [<Type]>+ [<TopLeftX]>+ [<TopLeftY]>+ [<BottomRightX]>+ [<BottomRightY]>+ | Clear terrain features (bushes, trees, etc.) from the given Location (default Here ). If a Type (default All ) is specified and matches a C# class type (e.g. ResourceClump or Bush ), then only terrain features that match that type will be cleared. You can prefix the type with a ! to negate it. For example, writing !Bush for the type will clear every terrain feature that is not a bush. If TopLeftX and TopLeftY are specified without BottomRightX and BottomRightY , then the terrain feature at that specific tile will be cleared. If BottomRightX and BottomRightY are both specified, then every terrain feature within that rectangle will be cleared. |
Spiderbuttons.BETAS_ClearObjects
[<Location]>+ [<Type]>+ [<TopLeftX]>+ [<TopLeftY]>+ [<BottomRightX]>+ [<BottomRightY]>+ | Clear objects (weeds, chests, etc.) from the given Location (default Here ). If a Type (default All ) is specified and matches a C# class type (e.g. Chest or Furniture ), then only objects that match that type will be cleared. You can prefix the type with a ! to negate it. For example, writing !Fence for the type will clear every object that is not a fence. If TopLeftX and TopLeftY are specified without BottomRightX and BottomRightY , then the object at that specific tile will be cleared. If BottomRightX and BottomRightY are both specified, then every object within that rectangle will be cleared. |