The making of "Mystery Island"

An add-on world for Dink Smallwood by Seth A. Robinson and Greg Smith. (V1.01)

(the following article should be considered a 'spoiler' - reading it may make this add-on less fun to play, as you'll know what is going to happen)

PREFACE

This file is a tutorial - intended for those interested in making their own add-ons for Dink Smallwood.

It not only details scripting and map design techniques, but includes general information on game making such as story design and using 3dsmax to create graphics.

This file was created 'on the fly' - we wrote a little here and there, so please excuse all the mistakes and using present and past tense statements everywhere.

- Seth A. Robinson

www.rtsoft.com

PHASE 1: DESIGN

Ok - we knew we wanted to create a great new add-on. Instead of jumping in and designing screens right away, we agreed to COMPLETELY script out the game before even TOUCHING it.

We bought some cookies and chips and things and had an 'idea session' - these are one of the fun parts of game making.

Shawn Teal (he's in Hawaii at the time of this writing) was also here for this meeting.

We agreed this would be the basic premise:

* The story is loosely set sometime in the future, after Dink had saved everyone in the original quest.

* The first half of the game will take place on a ship, the second half on 'mystery island'

* The ship area would use several views of the ship to represent different sections, it would consist of 3 or 4 arcade sequences that you must do correctly to advance your 'voyage'. Stills rendered in 3dsmax would be used before and after these arcade sequences as well as small digitized sound bytes.

* When you reach a certain point on your 'trip' you would be thrown overboard in a huge storm. This is when you wash ashore the island alone, and need to complete the quests there, which will finish the game as you and a robot leave in an airship. (I'll explain later.. <g> )

The three arcade sequences on the ship would be:

* Crew gets drunk, must clean up after them

* Ship goes into 'nightmare cave', you must help a crew member think of 'non violent' things or it will become a reality.

* Must navigate a small graphic of your boat around shark invested waters.

What happens on the island portion:

* Dink finds small town that is full of dead/rotting bodies. Who did this?

* He is pulled into safety by a stranger - she is a smart girl who helps Dink along the way.

* He is told the secret of the 'eyes' on the Island and must destroy all of them within 10 minutes. (the chick is able to deactivate them for that long)

* If he fails, a cutscene where a dragon comes out and eats him appears. You cannot save your game while a 'timed' event is happening.

* Turns out the dragon is a robot. Greg will do him in 3dsmax. (render him that is..)

* After this happens, Dink's next step is to open this special gate that has flashing lights. Three globes will play a 'simon' type game of memory with him, then and only then can he get in. (yay, a puzzle)

* To get to the inner cave hideout he'll fight stuff in a sort of mazelike place and find technical power ups along the way making it possible.

* There will be two endings.. how you trigger them will be secret.

* He'll bumble around in the cave hideout and meet some kind of friendly robot (small and cutish?) as well as some larger and 'not so friendly' ones. He'll eventually find the dead scientist/tinker and find out it was an experiment gone wrong.. the good robot tried to make a friend and it ended up killing the 'master' and whatnot.

* The robot will help them fly the airship out, the chick will magically show up and the end. ha ha, fun.

* The second ending will have you getting rescued by your shipmates. yay.

Ok, now that we had the story and premise set, we needed to start on the world!

 

PHASE 2: CREATING THE WORLD - 3-5-98

Here is what I did to start with a fresh world:

I made a dir called ISLAND off of my main dink dir. I copied the hard.dat from dink/dink into it. (this way I would start with the mountains and other tile graphics already 'harded' up correctly.) I can add to it, as long as I include the hard.dat with the add-on, which I will it looks like.

I installed The Search For Milli Vanilli and stole some things from it to use as a base. (they are simpler than Dink's.. so it is easier to modify)

I took:

dink.ini (where the graphics are loaded)

story\start.c (required, run when the game starts)

story\main.c (required, run when the game starts, usually do global var inits here)

story\start-1.c (start.c runs this when they click on start)

story\start-2.c (start.c runs this when they click on continue)

story\start-4.c (start.c runs this when they click on quit)

That was pretty easy - now I'm going to run it just for the heck of it.

I got a windows protection fault...didn't think it would do that but uh.. that was probably a bad idea for a few reasons. One is, the world doesn't exist yet, two, the .ini and .C files are calling things that don't exist graphically.

Let's go through and set the stuff up. First, I'm going to go through the dink.ini and remove any Milli specific graphics. Ok, I've realized the dink.ini is missing a lot of items that I may use - (Milli was designed to work with the unregistered version, so many creatures and items were not included)

I'm taking the Dink.ini from the dink/dink dir and using it as my base instead. I took a look at it, I really don't need to edit it at all.

Now I run "dinkedit.exe -game island" from a dos window. (you did copy this to your dink dir from the DEVELOP dir on the CD, right?!)

It created the world.dat file. I added two screens.

Next I edited the .C files I had stolen from the Milli world. I removed

make_global_int("&ot_stage", 0);
make_global_int("&ot_girl", 0);
make_global_int("&mill_follow", 0);
make_global_int("&dinklogo", 0);
make_global_int("&mill_rob", 0);
make_global_int("&mill_fab", 0);
make_global_int("&mill_girl", 0);
make_global_int("&mill_party", 0);
make_global_int("&mill_won", 0);
make_global_int("&manager", 0);

from the main.c and changed

debug("Dink started. Time to save Milli Vanilli.");

to

debug("Dink started. Time to check out Mystery Island.");

This line will only show up in the debug.txt file if run with -d.

Next I edited start.c.

I removed the Milli specific sound loading:

load_sound("LOOP.WAV", 35);
load_sound("SONG1.WAV", 36);
load_sound("SONG2.WAV", 37);
load_sound("TRUE.WAV", 38);

Playsound(38,22050,0,0,0);

I'll add my own sounds later, when I am ready to put them in.

The Milli title screen needs to go - I changed:

&dinklogo = create_sprite(250,220, 0, 453, 1);
sp_que(&dinklogo, 800);
sp_noclip(&dinklogo, 1);

to

//&dinklogo = create_sprite(250,220, 0, 453, 1);
//sp_que(&dinklogo, 800);
//sp_noclip(&dinklogo, 1);

By commenting it out, it will be easy to add the Dink logo when I'm ready.

I removed

wait(1000);
playmidi("dance.mid");

from near the bottom. This did wait a second then play a midi in Milli.

Whew! That was a lot of stuff to change.. but I'm not done yet.

Let's get into the start-1.c file.

Look at the 'click' procedure - this is run when they click on the start button.

void click ( void )
{

//lets start a new game
//Say_xy("`%Creating game...", 0, 390);
wait(1);
&player_map = 401;
sp_x(1, 327);
sp_y(1, 257);
sp_base_walk(1, 70);
sp_base_attack(1, 100);
set_mode(2); //turn game on
sp_dir(1, 4);
sp_brain(1, 1);
sp_que(1, 0);
sp_noclip(1, 0);
//lets give him fists to start out with
add_item("item-fst",438, 1);
&cur_weapon = 1;
//arm them for him too
arm_weapon();
//need this too
&update_status = 1;
draw_status();
spawn("begin");
kill_this_task();
}

The changes are pretty straightforward. The map I made (and want Dink to start on) is 67, so we need to change 401 to 67.

We'll also remove spawn("begin"); for now, although we'll probably add something like it back later for the intro cutscene.

Now let's play the game with "dink -game island" from a dos window and see what happens!

Ok, nothing happened - blank screen saying V1.03 on the bottom. What!?!?!

I then did it again with the CD in, and it worked fine. Note to self, check for the insert CD .bmp in proper directory in V1.04 and tweak it so it works right with add-on worlds. (V1.04 will be released soon.. before this add-on is)

I could walk around and such, great! We're now ready to start creating this adventure in earnest.

CREATING THE STARTING AREA 3-5-98

The boat - Greg modeled a fairly simple pirate-style boat in 3DSMAX2. We will render all boat graphics with it.

He outputted a .bmp of the boat with an 8 bit palette. Photoshop was having some trouble loading it, so he output it in .jpg and we converted it to Dink's palette from there.

 

 

 

The ship looked kind of crappy after the palette conversion. I contemplated adding 16 bit support (I've rewritten most of the routines for 8 and 16 bit support for new projects already), but it really didn't make sense for Dink, as all the other art would not benefit from it and the framerate would take a serious hit.

 

 

 

 

 

 

 

 

To remove banding in the sail, you can turn 'dithering' on in Photoshop when converting to Dink's 256 color palette. (You can get the pal by loading one of the .BMP pics from the tiles dir.. any .BMP in the game actually)

You should also clip it as close to the pic as possible, Dink's .bmp's are stored non-compressed, so they waste HUGE amounts of space even for pure white.

 

 

 

 

We used a white background and turned dithering off (while rendering in Max.. not converting), white is transparent by default when Dink loads graphics, so it would look good over the water.

Greg modeled 'medium' size ships in eight directions, these would be used in the 'avoid the shark' arcade sequence.

A tiny version of the ship would be used to mark your progress on the 'main map'. We would draw the map, it would actually not be based on any real place in the game, just a way to mark progress.

Greg suggested we render it in max and make it 'colorful and realistic' instead of go for a paper style parchment map. Sounds good to me.

 

COMPRESSING GRAPHICS 5-24-98

Ok - so I took a little break. :)

We decided to keep ALL the sprite graphics in one file, for quicker access.

Make a directory somewhere. We called it graphics.

Put all the .bmp's in it.

Put FFCREATE.EXE in it. Make sure you are using the newer one included with the V1.04 patch.

Run FFCREATE.EXE.

A file called DIR.FF will be created.

Copy it to the dink\addonname\graphics directory, it should be the ONLY file in it.

Your dink.ini will call the graphics the same. For instance, here was the part we added:

//now for MYSTERY ISLAND specific graphics:

load_sequence graphics\misc- 8 BLACK
load_sequence graphics\boat- 9 NOTANIM
load_sequence graphics\dbod- 844 NOTANIM
load_sequence graphics\ball- 845 NOTANIM
load_sequence graphics\door- 846

NOTE: Changing graphics now requires an additional step. After changing the .BMP, you need to run ffcreate.exe again and pop the new dir.ff into the dink/addonname/graphics dir.

Timing problems.

Greg noticed that save games reported that user had been playing 10 million hours.


We fixed it by adding the line

reset_timer();

to the start-1.c file. (we were using the Milli DMOD as a shell, which didn't have it, the time stuff was added in a later version of Dink)

New dinkc command added.

We needed the giant boat .BMP to move off the screen at one portion of the addon. The problem - because it was in a SEQ with other misc graphics, it would PLAY the entire sequence as it moved up.

I added a NEW script command that causes a SEQ NOT to play any animations, so I wouldn't have to give it its own SEQ each time I wanted to move a certain graphic.

sp_picfreeze(&ship, 1);