### Author Topic:  Script Command Documentation  (Read 32995 times)

0 Members and 2 Guests are viewing this topic.

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #10 on: July 12, 2014, 08:53:51 AM »
Hail: Hail: Creates a hail weather effect.

Hail [x,z] [radius] [duration] [intensity] [r,g,b]
Hail [x,z] [radius] [duration] [intensity] [r,g,b] [minsize,maxsize]
Hail [x,z] [delete]

[x,z] - The surface coordinate for the center of the hail storm.

[duration] - The duration of the hail storm in seconds.

[intensity] - The strength the hail storm. Valid values are 1 - 100, with 1 being the weakest and 100 the strongest.

[r,g,b] - The color of the hail stones in rgb format. r = red, g = green, b = blue. rgb are the 3 primary light colors and any color can be created with these 3 components. Possible values for each component are 0 - 255. This parameter may be omitted. If it is omitted, a random translucent whitish gray color is used.

[minsize,maxsize] - The size of the hail stones in centimeters. Valid values are 1 - 100, with 1 being 1cm and 100 being 1m (1 block). For each hail stone that falls, the game picks a random size between minsize and maxsize.

[delete] - Deletes the current Hail effect at [x,z]

Examples:

Hail [100,200] [100] [20] [50]
Creates a hail storm at surface coordinate 100,200, with a radius of 100 blocks. The storm lasts for 20 seconds and is half strength. A random whitish gray color is used.

Hail [300,800] [70] [120] [75] [200,200,200]
Creates a hail storm at surface coordinate 300,800, with a radius of 70 blocks. The effect lasts for 2 minutes and is 3/4 strength. The color of the hail stones is a light whitish gray.

Hail [800,100] [20] [300] [100] [20,20,20] [10,25]
Creates a hail storm at surface coordinate 800,100, with a radius of 20 blocks. The effect lasts for 5 minutes and is full strength. The color of the fog is dark almost black. The hail stones will range in size from 10 - 25 centimeters.

Hail [300,800] [delete]
Deletes the current Hail effect at [300,800]
« Last Edit: July 28, 2015, 08:44:01 PM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #11 on: July 12, 2014, 08:54:08 AM »
History: Manipulates historical records. Historical records can be queried by the HasHistory command to determine if a record exists.

History [name] [+/-count|delete]
History [name] [player|clan] [+/-count|delete]

[name] - The name or label of the record. History names support folders which allows you to match your history names with script names, where appropriate.
[count] - Specify either an absolute value to set the history to that value, or specify a relative value to add/subtract that value from the history.
[delete] - Deletes the history record.
[player] - Indicates the record is for the player.
[clan] - Indicates the record is for the players clan.

Records are actually counters. So if the History command adds a record for the same name more than once, then a new record is not created, but the counter for the initial record increased. This allows scripts to query how many times a record has occured.

Examples:

History [ActionX] - Creates a new system history record called ActionX with a value of 1, or if the history already exists, it increments it by 1.
History [ActionX] [+1] - Identical to above.
History [ActionX] [3] - Creates a new system history record called ActionX with a value of 3, or if the history already exists, it sets it's value to 3, regardless of what it was before.
History [ActionX] [delete] - Deletes the system history record called ActionX.
History [ActionX] [-5] - Subtracts 5 from the system history record.

History [ActionX] [player] - Creates a new player history record called ActionX with a value of 1, or if the history already exists, it increments it by 1.
History [ActionX] [player] [+1] - Identical to above.
History [ActionX] [player] [3] - Creates a new player history record called ActionX with a value of 3, or if the history already exists, it sets it's value to 3, regardless of what it was before.
History [ActionX] [player] [delete] - Deletes the player history record called ActionX.
History [ActionX] [player] [-5] - Subtracts 5 from the player history record.
*Note: The player is whichever player activated the script.

History [ActionX] [clan] - Creates a new clan history record called ActionX with a value of 1, or if the history already exists, it increments it by 1.
History [ActionX] [clan] [+1] - Identical to above.
History [ActionX] [clan] [3] - Creates a new clan history record called ActionX with a value of 3, or if the history already exists, it sets it's value to 3, regardless of what it was before.
History [ActionX] [clan] [delete] - Deletes the clan history record called ActionX.
History [ActionX] [clan] [-5] - Subtracts 5 from the clan history record.
*Note: The Clan is the clan of whichever player activated the script. If the player is not in a clan, the command does nothing.

var [foo] = [health] / [maxhealth] * [100]
History [HealthAsPercentage] [player] [foo]
Creates a variable that holds the value of the players current health as a percentage of it's max health, and assigns that variable to the players history 'HealthAsPercentage'.
« Last Edit: August 12, 2016, 04:36:14 AM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #12 on: July 12, 2014, 08:54:29 AM »
Inventory: Manipulates block and entity inventories.
Inventory [x,y,z] [clear]
Inventory [x,y,z] [clear] [item]
Inventory [player] [clear]
Inventory [player] [clear] [item]
Inventory [x,y,z] [player] [*move]
Inventory [x,y,z] [player] [*move] [item]
Inventory [x,y,z] [player] [*move] [item] [qty]
Inventory [player] [x,y,z] [*move]
Inventory [player] [x,y,z] [*move] [item]
Inventory [player] [x,y,z] [*move] [item] [qty]
Inventory [x,y,z] [x,y,z] [clear]
Inventory [x,y,z] [x,y,z] [clear] [item]
Inventory [x,y,z] [x,y,z] [*move] [item]
Inventory [x,y,z] [x,y,z] [copy] [item]
Inventory [x,y,z] [x,y,z] [add|take|copy|*move] [item] [qty]
Inventory [x,y,z] [x,y,z] [x,y,z] [copy|*move]
« Last Edit: February 16, 2015, 05:40:13 PM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #13 on: July 12, 2014, 08:54:44 AM »
Marker: Manipulates markers on the overhead map.

Marker [name] [x,z]
Marker [name] [delete]

[name] - The name of the marker (displayed on the map).
[x,z] - The surface coordinate for the marker.
[delete] - Use this instead of [x,z] to delete an existing marker from the map.

Examples:

Marker [Town Square] [500,550]
Sets a marker at surface location 500,550 with the name "Town Square"

Sets a marker at surface location 300,450 with the name "Admin HQ" which is only visible to admins.

Delete the marker named "Admin HQ" from the map.

Also see the Waypoint command for setting your waypoint on the overhead map.
« Last Edit: April 19, 2015, 07:55:18 AM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #14 on: July 12, 2014, 08:55:04 AM »
MoveBlock: Moves a block from one location to another. All data and settings attached to block is moved with it. The source location is replaced with air.

MoveBlock [x,y,z] [x,y,z]

[x,y,z] - The 1st coordinate is the source location.
[x,y,z] - The 2nd coordinate is the destination location.

Examples:

MoveBlock [10,20,30] [110,120,130]
Moves the block and all it's associated data at location 10,20.30 to location 110,120,130. After the move, location 10,20,30 will contain empty air.
« Last Edit: July 15, 2014, 08:21:27 AM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #15 on: July 12, 2014, 08:55:18 AM »
MoveRegion: Moves all the blocks from one region to another region. All data and settings attached to the blocks are moved to the new region. After a block is moved, it's original position is set to empty air.

MoveRegion [x,y,z] [x,y,z] [x,y,z]

[x,y,z] - The 1st coordinate is the minimum bound of the source region.
[x,y,z] - The 2nd coordinate is the maximum bound of the source region.
[x,y,z] - The 3rd coordinate is the minimum bound of the destination region.

Examples:

MoveRegion [100,200,300] [150,250,350] [10,20,30]
Moves all the blocks and all their associated data from 100,200,300 / 150,250,350 to the location starting at 10,20,30. The final block at 150,250,350 will be moved to 60,70,80.
« Last Edit: July 15, 2014, 08:31:40 AM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #16 on: July 12, 2014, 08:55:31 AM »
Notify: Creates a notification message (pink messages at top left of screen).

[local] - only players on the same xbox see the message.
[global] - all players on the session see the message.

Supported from version 2.22
[clan] - all clan members see the message.
« Last Edit: May 28, 2015, 05:53:12 AM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #17 on: July 12, 2014, 08:55:48 AM »
Paste: Pastes a component

Paste [pack:component] [x,y,z] [facing] [copytype]

Restrictions:
This command only works in Creative worlds.

« Last Edit: April 19, 2015, 08:01:23 AM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #18 on: July 12, 2014, 08:56:08 AM »
Permission: Manipulates player permissions. Only the permissions of the player who activated the script are affected.

Permission [permission] [on|off]

[permission] - The permission to set. adventure, edit, creative, fly, map, chat, grief, save, admin.

[on|off] - Determines if the permission is to be set on or off.

Examples:

Permission [chat] [off] - sets the chat permission off.
Permission  [on] - sets the edit permission on.
« Last Edit: July 13, 2014, 07:22:04 AM by Craig »

#### Craig

• Developer
• Extreme Member
• Posts: 6655
• Dig Deep
• Steam: tota1miner
##### Re: Script Command Documentation
« Reply #19 on: July 12, 2014, 08:56:24 AM »
ReplaceRegion: Replaces all occurrences of a block in a region with another block.

ReplaceRegion [x,y,z] [x,y,z] [block1] [block2]

[x,y,z] - The 1st coordinate is the minimum bound of the replace region.
[x,y,z] - The 2nd coordinate is the maximum bound of the replace region.

[block1] - The Block to be replaced.
[block2] - The Block to replace with.

Restrictions:
This command only works in Creative worlds.

Examples:

ReplaceRegion [100,200,300] [150,250,350] [Limestone] [Marble]
Replaces all Limestone blocks within the 100,200,300 / 150,250,350 bound with Marble.
« Last Edit: April 19, 2015, 08:01:44 AM by Craig »