The Source for Java Technology Collaboration

As the new Java.net infrastructure contains project-level wikis, this main wiki will be shut down in the near future. For wiki page export and general wiki questions please contact the site admin at communitymanager@java.net.
Home | Changes | Index | Search | Go

Building a Project Wonderland World from Scratch (tutorial)

by Nicole Yankelovich (nicoley@dev.java.net)

This material is distributed under the GNU General Public License Version 2. To obtain a copy of the original source code, make a request on the Wonderland Forum.

Purpose

This tutorial is for people who would like to create their own Wonderland worlds. To create a world from scratch, it is not necessary to be an artist or a programmer. You will, however, need to learn some basic Wonderland system administration skills.

The key ideas we'll focus on in this tutorial are setting up an empty Wonderland world, importing content into the world, arranging the content, and saving your work. Once you complete this tutorial, you should be able to start up a Wonderland server, add and arrange content, and save and restore different worlds.

Prerequisites

Here's what you will need to complete this tutorial:

  • Familiarity with the material covered in the Learning the Basics tutorial
  • Access to a computer that can run a Wonderland server
  • System administration access to the Wonderland server
  • Wonderland v0.5, Preview1 or later - download binaries
  • A computer that will run the Wonderland 0.5 client (can be the same machine that is running the server)
  • Access to the Google 3D Warehouse

Setting up Your Wonderland System

If you already have a Wonderland server up and running you can skip this section. If not, carefully follow the instructions on the binary downloads page to set up your environment:

Project Wonderland v0.5 Binary Downloads

To run the client, follow these instructions:

Launching Wonderland Clients using Java Web Start

Starting with an Empty World

Once you have determined that your server is working and you can launch a client, quit out of the client and return to the Wonderland launch page:

Click on the Server Admin button to access the Server Administration Console. If someone other than you set up the server, you may need a password to access this section of the web site. Next, click on the "Manage Worlds" (older versions may say "Manage Snapshots") link in the left navigation pane. You should now see the four default "Initial Worlds":

If you're using a shared server, you may also see some Snapshots, otherwise, this section will be empty.

Make sure there are no users currently connected to the Wonderland server before following the next instruction.

In the "Initial Worlds" table, click on the Empty World "restore" link in the Actions column. You should now see a message about restarting the Darkstar server:

Click "OK" to confirm the action, and then click on the "Manage Server" link in the navigation pane.

You will see in the "Status" column that it says the Darkstar server is "Starting Up." Wait until the status changes to "Running" and then click on the Home link in the navigation pane.

Start up the Wonderland client by clicking on the orange Launch button. You should now see a world with only a sky.

Adding the Essentials

Empty Wonderland worlds come with only a sky. To help you get started with the bare essentials, we have created some collections of models in the Google 3D Warehouse. These collections are constantly growing and changing, so you may find more models than described here. Start by opening up the Google 3D Warehouse home page in a new browser window:

Google 3D Warehouse home page

In the search box, type "Wonderland" and select "Collections" from the drop down menu. Then click "Search." You should see results similar to this.

Click on the collection called "Floors for Project Wonderland." Find the floor called "Stovepipe Sand Floor - 120m Circle" and click on it. On the Stovepipe page, click "Download Model" and click on the "Download 70 kb" link next to the "Google Earth 4 (.kmz")" entry.

Save the .kmz file on your computer in a place you can get to it easily, perhaps creating a "3D Models" folder. Now navigate back to your collection search results and click on "Skylines for Project Wonderland." Find the one called "Gnome Mountain Skyline - 250m" which coordinates with the floor you have just downloaded. Download the .kmz file for this skyline model and save it on your computer in the same place as the floor model.

Use your file manager to locate the two files you have just downloaded then activate your Wonderland window with the empty world. Use the Placemarks menu to navigate to the Starting Location. This ensures that you are going to load your models while standing in the exact center of your empty world.

Now drag and drop the "Stovepipe Sand Floor - 120m Circle" file from your file manager on to the Wonderland window with the empty world. You should now see your avatar standing on a sand floor.

Note: If you are on a Mac, you may get an error the first time you try to drag and drop. Just click ok and try again. Drag and drop should work fine after the error occurs.

To make sure that the floor is in exactly the correct position, right click on the sand floor and select "Edit" from the context menu. An edit palette will open. Since this model is so large, it is easiest to position it with the numerical controls. To view these, click on the "Details" button.

By using the arrows or by typing in values, set all the Position and Rotation values to 0.

Next, without moving your avatar, drag and drop the skyline you downloaded. You should now see a scene like this one:

If there is a gap between the sand floor and the skyline, right click on the skyline and select "Edit" from the context menu. Then open the Details pane and decrease the Y position until the floor and the skyline are touching.

Adjusting the Lighting

When models such as this floor and skyline are created using Google SketchUp, they often come into Wonderland looking dark. This is because Wonderland uses a different lighting scheme than SketchUp. For most SketchUp models, you will want to turn off the Wonderland lighting and use the native lighting. To do this for the floor, right click on the sand and select "Properties..." from the context menu.

When the Properties dialog opens, click on the "Model Component" item in the Capabilities pane. Then uncheck "Lighting Enabled" and click "Apply and then close the Properties dialog"

Adjust the skyline lighting in the same manner. Your scene should now be considerably brighter.

You may, of course, have a personal preference for a darker floor or darker skyline. In this case, simply check the box again in the property sheet.

Populating the Space Using Drag and Drop

Now that you have the bare bones of your world, you can begin to add content. You can search the Google 3D Warehouse for models to add. For example, You might like this environmental house model:

http://sketchup.google.com/3dwarehouse/details?mid=b8a84f00924ab2313b3aa556448a966&prevstart=0

It looks in keeping with the sand dunes. To use it in your Wonderland scene, download the Google Earth (.kmz) version, save it on your desktop, and drag and drop it into the Wonderland window. As you begin to add models to your world, it might be advantageous to allow your avatar to avoid collision detection (eg with the models). You can do this by unchecking the collision detection feature under the Tools menu.

Notice that there is a rug under the entry canopy that was not part of the model. This is a 2D image dragged and dropped into the scene from the web. You can add any 2D image in .png, .jpg, or .gif format. Be sure to check that images you use are appropriately licensed for reuse. FullSail's ShareCG collection of textures includes many "unrestricted use" images that were designed to be used in games and virtual worlds (a free login is required to access the images). For example, I found this collection of Southwestern Ceramic Tiles that go well with our desert sand dune scene.

http://www.sharecg.com/v/20737/Texture/Southwestern-Ceramic-Tiles

You can download the collection of tiles onto your desktop and uncompress the folder. Now move your avatar to an open space and drag and drop one of the tile images into the Wonderland window. The tile will appear directly in front of you, oriented vertically. Right click on the upright tile and select "Edit" from the context menu. Then click on "Details" and change the X rotation to 90 degrees.

Now the tile is horizontal. Place your mouse over the green arrow and use it to drag the tile down onto the floor.

Don't worry if the image goes through the floor. Just drag it back up until you can see it again. When you are finished making adjustments, use the "X" in the edit palette to hide the tools.

Adding 2D and 3D Applications

You can also add content by inserting 2D or 3D applications installed on your sever. To see the selection available to you, which will vary with every Wonderland installation, select "Object" from the Insert menu. A window similar to this one will open.

Move your avatar onto the tile near the far edge. In the Insert Object window, select "Whiteboard (SVG)" and click Insert. A whiteboard will appear in front of you. Right click on it and select "Take Control."

When you have control, the window border turns green and a tool palette appears that allows you to draw on the whiteboard. After you add some text or a drawing, click on the "Release App Control" button in upper right corner of the Wonderland window.

Use a combination of drag and drop and the Object window to populate the rest of your scene.

Saving Your Work

When you quit out of Wonderland, the world you have built will be saved automatically and will continue to persist as long as the server is not restarted. To ensure that your world can be restored after a server restart, you need to create a "snapshot." To do this, go back to your browser and click on Manage Worlds in the navigation pane of the Server Admin web page we used at the beginning of this tutorial.

Scroll to the bottom of the page and click "Create Snapshot." Click "OK" to confirm restarting the Darkstar server. Restarting the server disconnects you from your world briefly.

A new snapshot named with the current date and time will appear at the top of the snapshots list. To keep track of the snapshots, it's a good idea to name them. Do this by clicking on the "edit" link.

Then add a name and a description. I like to leave the date in the name so it's clear how old each snapshot is.

At any point in the future, you can restore your snapshot by clicking on the "make current" link. This will also require a Darkstar server restart. Be sure that there is no one using the server and no important unsaved work when you do this operation. Restarting the server will cause unsaved changes to be lost. If you are unsure if anything needs to be saved, simply create a new snapshot before restoring an existing one.

This will restore the state of the world as it was when you created the snapshot.

Topic ProjectWonderlandWorldFromScratch05 . { Edit | Ref-By | Printable | Diffs r7 < r6 < r5 < r4 < r3 | More }
 XML java.net RSS

  

Revision r7 - 2010-02-26 - 20:13:20 - nicoley
Parents: WebHome > ProjectWonderland