Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //note: file test.txt (%appdata%\.minecraft\saves\<world>\test.txt
- //note: A line starting with '//' won't be executed as code
- //note: this must be in every script
- function main(func){
- //note: the following command executes a minecraft-command
- func.sendCommand(func.var1, "/say example");
- //note: you don't have to know what "func.var" is, but you need to type it :D
- //note: the '"' are required arround the command you want to execute!
- // the command (/say example) can be replaced with every minecraft-command you want, as long as it doesn't include '"'
- // If you want to execute a command, that includes '"' just read on, it will be explained later (no it won't didn't have time to // write a tutorial yet :( )
- //note: the following command places a Block in the minecraft world
- func.setBlock("diamond_block", 1, 2, 3);
- //note: "diamond_block" can be replaced with any block you like
- //note: 1, 2, 3 are the x, y and z coordinates where the block should be placed
- //note: you can replace the coordinates with func.getX(), func.getY(), func.getZ() to place the block inside the player / command-
- // block that is executeing this script. You can also use mathematic expressions such as '+2' or '/20' or '-200' and so on.
- // for example 'func.setBlock("diamond_block", func.getX(), func.getY() + 2, func.getZ());' would place a diamond block 2 blocks
- // abov the player's / command-block's location
- //note: of corse you can also use normal javascript commands and syntaxes, which i won't explain here, because it would take ways too
- // long. Just google: "javascript beginner tutorial" or something like that, and it will be fine :)
- }
Add Comment
Please, Sign In to add comment