Click here to Skip to main content
13,895,584 members
Click here to Skip to main content
Add your own
alternative version

Tagged as


5 bookmarked
Posted 20 Feb 2015
Licenced CPOL

Build Giant Ravine in Minecraft using ScriptCraft (With Other Examples)

, 20 Feb 2015
Rate this:
Please Sign up or sign in to vote.
Build Giant Ravine in Minecraft using ScriptCraft (With Other Examples)

Minecraft is a huge game. The full PC version is especially great because it is customizable with lots of mods available all over the internet. One great new mod is ScriptCraft by Walter Higgins ( ScriptCraft runs on a bukkit version of the minecraft server. Installation is covered on the ServerCraft site.

ScriptCraft adds JavaScript control of minecraft. Buildings and other objects can be created instantly through the Minecraft command line. Also, this can be a great way to introduce someone into programming for the first time.

Try these samples below. Copy these JavaScript sources to your server and restart it to try them out.

Save as igloo.js and put in your js-plugins\drone folder.

load(__folder + "drone.js")
// constructs an igloo
Drone.extend('igloo', function () {
//make basic structure
this.hemisphere0(blocks.snow, 7, 'north');
//clear door
this.up(2);, 2, 3, 2);
return this.move('igloo');

Run this by typing in the Minecraft command line:

/js igloo()

Save as enchant_table.js and put in your js-plugins\drone folder.

load(__folder + "drone.js")
// constructs an enchantment table surrounded with books for max enchanting
Drone.extend('enchant_table', function () {
this.up(); //set to just above floor level.
this.box0(blocks.bookshelf, 5, 5, 4);
//open side
this.box0(0, 3, 3, 1);
//add enchantment table
//add floor
this.move('enchant_table');, 5, 1, 4);
//add roof
this.up(4);, 5, 1, 4);
return this; });

Run this by typing in the Minecraft command line:

/js enchant_table()

Now, you'll have an enchantment table that is fully maxed out.

One of my favorite things to do with this is to use the command to explore and reveal to the world underneath. So to clear out large areas in this snow covered forest, issue a command like down(height/2).box(blocktype, width, height, depth) with 0 for the block type.

/js down(40).box(0, 20, 70, 120)

Now just look at the giant ravine we've created. This method reveals all sorts of neat areas to explore and is great for mining.

The box(...) part of the function is what actually clears the area out since we are using air (block 0) as the block. Since box() always goes up, we need to send the command down with the down(40) command first. Since we are using JavaScript, we can chain the commands together as shown above.

What kind of cool things are you doing? Please send me a note if you've enjoyed this page.

Some of the ScriptCraft built in samples to try:

/js castle()
				/js chessboard()
				/js cottage()
				/js cottage_road()
				/js dancefloor()
				/js fort()
				/js rainbow()
				/js temple()

To create with other block types, use the (dec) values from the official Minecraft list:


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Right Handed Monkey
Chief Technology Officer WorxForUs
United States United States
I am a programmer who posts rambling on about java, Android, PHP, or whatever I am motivated to type on my charcoal colored Kinesis Freestyle2 keyboard. Please send +1's, shared links, warm thoughts of encouragement, or emasculating flames of internet fury to my blog. Thanks for reading!

You may also be interested in...


Comments and Discussions

-- There are no messages in this forum --
Permalink | Advertise | Privacy | Cookies | Terms of Use | Mobile
Web06 | 2.8.190306.1 | Last Updated 20 Feb 2015
Article Copyright 2015 by Right Handed Monkey
Everything else Copyright © CodeProject, 1999-2019
Layout: fixed | fluid