I think it’s time we talked about one of the finer points of Wrack – its modding capabilities! As many of you know, my previous project was Skulltag – a Doom expansion which adds client/server multiplayer; new game modes (such as capture the flag); and a slew of new weapons, items, and monsters.
Skulltag, as well as Doom in general, continues to thrive years after its release largely thanks to all of the great maps and mods people have created over the years. My hope is for Wrack to be the same way.
I think most would agree that the ability to make new maps is the most important aspect of modding. To do that, you need a great map making tool. Wrack’s map editor, WrackEd, aims to be just that (and if it falls short, I’ll fix it, dammit!). It’s a powerful tool that aims to be fairly intuitive to use. It has three 2D views which allow you to create and manipulate your level geometry and placed items on any plane, and a 3D view which shows you exactly how your level is turning out in real time.
Maps are saved to a file called .map (makes sense, right?). These files can simply be dragged and dropped onto Wrack.exe (or opened with Wrack.exe) which brings up a menu asking if you’d like to play the map right away, play it after setting your skill level, or just going to the main menu (you can also set it to remember what you picked). This makes it ultra easy for people to play custom maps – something I hope people make a lot of!
The last thing I want to touch on is the straight up modding of Wrack – adding a new monster, editing an existing one, replacing a sound, etc. For starters, all of Wrack’s data is defined externally. What does this mean? Wrack has no idea what the hell a crawler, crusher, or even a DOOR is. All of these things have been defined through a series of text files, which can be manipulated by you. You can build your own monsters, weapons, face actions, etc. all using the same tools we’ve used to make Wrack. You can even build off of what we’ve got!
Not only can you define your own properties for objects (ex. how tall it is, or how much damage it does), but you can also define the behavior for most everything as well. For instance, all monster behavior is done through scripting. Here’s a (simplified) example of a section of the crawler’s script:
event( "struck wall" )
// If we hit a wall, try to turn and move towards our target.
// If we can't move towards it, first try to walk along the
FaceTarget8Way( true, false );
if ( CannotMoveForward( ))
changestate( WalkAlongObstruction );
event( "target died" )
// Play our movement sound.
PlaySound( "crawler_move.wav", 100, SFXF_LOOP );
// Set this state's animation.
SetAnimation( "chase", -1, ANIMF_LOOP );
iTicks = 0;
// Attack once we get into melee range.
if ( TargetWithinAttackRange( ))
ChangeState( Attack );
if ( iTicks == 0 )
// Change directions.
FaceTarget8Way( true, false );
iTicks = rand( 1, 2 ) * FPS / 4;
// Move forward.
I’ll explain how scripting works later, but you can probably figure out some of how this works already (for instance, PlaySound() probably… plays a sound!). This should give you an idea though of just how much flexibility you have when it comes to modding Wrack.
That’s it for right now! Do you have any questions? Do you plan on doing any Wrack modding? If so, what do you plan to do?