Actions - GoryMoon/CraftopiaStreamIntegration GitHub Wiki

Actions

The options for the actions and the defaults can be found below, if the fields aren't provided the values below will be used.

All actions that have numbers as a string support the use of calculation from the event data.

All actions have the "delay_min" and "delay_max" property that can be used to randomize the time in seconds to delay the action.

Heal Player

Heals the player with the amount specified, negative value removes health

{
	"type": "heal_player",
	"amount": "100"
}

Refill mana

Refills the player's mana with the amount specified, negative value removes mana

{
	"type": "refill_mana",
	"amount": "100"
}

Refill stamina

Refills the player's stamina with the amount specified, negative value removes stamina

{
	"type": "heal_player",
	"amount": "100"
}

Refill hunger

Refills the player's hunger with the amount specified, negative value removes hunger

{
	"type": "heal_player",
	"amount": "100"
}

Repair tool

Repair the currently equipped main tool

{
	"type": "repair_tool",
	"amount": "100"
}

Inventory Bomb

Drops all the items in front of the player

{
	"type": "inventory_bomb",
	"spread": 10,
	"drop_equipment": true
}

spread Is a range that it randomized around the player to drop items in

Move Player

{
	"type": "move_player",
	"amount": "25",
	"amount_vertical": "10",
	"no_fall_damage": 2
}

amount The distance horizontally it tries to move the player

amount_vertical Is the height it will try to move the player

no_fall_damage The time in seconds to negate fall damage

Give Item

Gives an item to the player, if it doesn't fit in the inventory it's dropped.

{
	"type": "give_item",
	"id": 2050,
	"level": 1,
	"enchantment_ids": [],
	"durability_value": 9999999,
	"durability_max": 9999999,
	"amount": "1",
	"drop": false,
	"spread": 2
}

id The id of the item to give to the player (currently working on getting all valid ids, for now it's some raw meat)

level The level to give the item

enchantment_ids A list of enchantment ids to give to the items (currently working on getting all valid ids)

durability_value The durability of the item, it can't be higher then the max below, this high value just makes sure it's as high as it can

durability_max The max durability of the item, it can't be higher then when what the item normaly have, this high value just makes sure it's as high as it can

amount The amount of items to give

drop If the item should be dropped or given into the inventory

spread Is a range that it randomized around the player to drop items in

Spawn Mob

{
	"type": "spawn_mob",
	"id": "Chicken",
	"level": "0",
	"amount": "1",
	"radius": 10,
	"despawn_time": 0,
	"add_player_level": false
}

id The id of the mob to spawn, a list of available items can be found here

level The level of the mob to spawn

amount The amount of mobs to spawn

radius The area in meters around the player to spawn the mob in

despawn_time The time in seconds until the mod is despawned or killed

add_player_level If true the current player level is added to the provided level

Change Mouse Sensitivity

Changes the player's mouse sensitivity for the specified time to the specifid amount

{
	"type": "change_mouse_sensitivity",
	"amount": 2.0,
	"time": 2.0
}

amount The amount to change it to, can be both lower and higer

time The time in seconds until it's changed back

Invert Controls

Inverts the movement controls for the specified time

{
	"type": "invert_controls",
	"time": 2
}

time The time in seconds until it's changed back

Invert Mouse

Inverts the mouse control for looking in the game

{
	"type": "invert_mouse",
	"time": 2
}

time The time in seconds until it's changed back

Ignite

Ignites the player

{
	"type": "ignite"
}

Drop Bombs

Dropb bombs around the player

{
	"type": "drop_bomb",
	"amount": "1",
	"radius": 10,
	"damage": "10",
	"damage_structure": 0,
	"speed": 4,
	"height": 10,
	"drop_delay": 0
}

amount The amount of bombs to drop

radius The radius around the player that bombs can spawn in

damage The amount of damage to deal, remember the defense of the player blocks some of this

damage_structure The amount of damage to deal to structures

speed The speed the bombs should drop with

height The height above the player to spawn the barrels

drop_delay An optional delay between each bomb drop in seconds