The New World Times: About Our World

The New World Times
ABOUT OUR WORLD

Teleporting Without a Web Browser

March 28, 1996

As you probably know, version .68 introduced the capability to teleport anywhere in AlphaWorld using web pages. With a little ingenuity, we can use the same method to teleport without web pages, using just disk files.

To understand this method better, let's go over the technique used in teleporting using web pages. You can see this sample usage on this page. The idea is to call a cgi-bin program ont he AlphaWorld server which sends files to your browser. These files are of type "application/x-alphaworld" and any browser that supports "helper applications" or "external viewers" can be made to call the AlphaWorld client to handle the file. For more in-depth handling of this subject, take a look at Sopwith's most excellent Teleport page (linked from Sopwith's main AlphaWorld page, and while you're at it, take a moment to register your home, business, or whatever with Sopwith's AlphaWorld Atlas!)

When you call the cgi-bin routine, you're just requesting that it sends a file to the machine of the person who clicks on the web-page link. The browser which receives the file needs to be "trained" to call AWORLD.EXE when it gets a file of this type. So what really happens? Your browser starts up AWORLD.EXE with a command-line parameter like this:

AWORLD filename

...where "filename" is the name of a temporary disk file. The cgi-bin syntax looks something like this:

<a href="http://www.worlds.net/cgi-bin/teleport?74S_30W_18A_180">Legacy Palace</a><p>

Of course, it comes out looking like this on the web page:

Legacy Palace

This sample teleports you to Legacy Palace at 74S, 30W, 180 meters in the air (18 * 10 meters altitude) with a skew of 180 degrees from North (counterclockwise, although it doesn't matter in this case.) We can accomplish the same thing without using a browser at all. If you are the inquisitive type you may have already done this...if you don't "train" your browser to handle file-type application/x-alphaworld, or if you turn off the handling temporarily, when you click on a web-page link like the one above, the browser should prompt you asking how to handle the file. If you elect to save it to disk, and then open the file using Notepad or another text editor, you'll see this:

TELEPORT 74S 30W 18A 180

Now let's create a file like this to test methods of disk-based teleport. We'll make a file that will teleport us to the new "construction yard" LittleBull is building at 599S 763E. (Warning: ALL "non-Z" objects available to builders are displayed in this yard. If you are using version .68 or lower, you won't be able to see some of these. If you have a more recent version and stick around here for long enough to download all objects to your disk you will use significant amounts of disk space to store all the models!)

We want to arrive at ground level so no altitude parameter is necessary, but we do want to arrive facing south, which is a 180 degree angle from North, so we create a disk file that contains only:

TELEPORT 599S 763E 180

(If you had wanted to arrive 10 meters high the syntax would be TELEPORT 599S 763E 1A 180.)

This file should probably go in the \AWORLD directory or wherever you have AlphaWorld's client program file, AWORLD.EXE. Let's call it CONSYARD.AW. Now, there are several ways to execute this program from Windows. Under Windows 95 you can start graphical programs from the DOS prompt, so you can open a DOS window, change directory to \AWORLD, and just type AWORLD CONSYARD.AW.

If the client isn't loaded yet, this will start it up, and before you parachute to the ground, you'll teleport to the construction yard. If the client is already loaded, a second copy will start, then check and find out that it's a second copy and terminate...but first it will send the command-line parameter to the original copy in memory, which teleports you anyway.

If you get any parameter even just a little bit wrong, nothing will happen. So if you don't teleport pretty quickly, open up the file you used with Notepad or another text editor such as DOS's EDIT program. Check each parameter and find the one that is incorrect and try again.

If you're not the DOS command-line type, or you don't have Windows 95, you can create any number of .AW files in your AlphaWorld directory and tell Windows File Manager or Explorer to associate extension .AW with AWORLD.EXE, just as it associates .TXT files with Notepad and .WRI files with Write or Wordpad. Then when you doubleclick one of your teleport files from File Manager or Explorer or similar programs, you will automatically teleport to the desired location whether AlphaWorld is loaded yet or not!


Contents