Creating CTF Maps
From Skulltag
Wondering how to make a Capture the Flag map? It's very simple. with the new map standard, introduced in Skulltag 0.96b. A CTF map is created just like a Deathmatch map, except for the design. If you're looking for map designing tips, see Deathz0r's guide. You also use a different kind of player start, and have flags.
First, design your map. Then place the Blue Starts [TID: 5080] where you want Blue Team players to spawn (normally they're clumped together in a base). Do the same for Red Starts [TID: 5081]. Do not place any Single Player starts or Skulltag will think your map is a singleplayer map.
Next you need to add your flags (again, normally in bases). Add the Blue Flag [TID: 5130] and the Red Flag [TID: 5031] to your map. You also should put the White Flag [TID: 5132] in as well. This allows people to play 1 Flag CTF on your map.
Now when anybody join the game he or she will use the 'Select Team' menu. Using the keyboard and the Space button they select their team (Red, Blue, or Random). You can switch teams under the Multiplayer Menu / Player Setup / Change Team option.
A much nicer option is to make a team selection room. This is a physical room where brand new players run to the team of their choice. You also have more control as a designer then with the default menu.
To make a team selection room, create some sort of new room that doesn't connect to the playing area. You need to choose a way that players will select a team. The most common practice (which we use here) involves a hallway. This room should have at least two halls: one for the player to select blue, and one for the player to select red. It's also recommended that you have a third hall, so that the player can select a random team. Now, let's look at how to create the red and blue hallways.
First, have a line across the blue hall that runs a script that does two things: print a message that says "This hall selects the blue team", and puts the player on the blue team, using the ACS function Player_SetTeam( TEAM_BLUE );. Now, do the same thing for the red team. Finally, have the teleports inside each hallway teleport the player to the appropriate base. Should be simple enough.
The random hallway, is a little bit more complicated. First, create a line across the hallway, similarly to what you did for the red/blue hallways. The only main difference here is to NOT set a team for the player. Setting a team would give a player advance knowledge of the random team he's been put on, before he's committed to choosing a random team by walking into the teleporter. This would give the player the option to change his mind, by simply walking over the line again... and then, really what would the point of the random hallway be? Anyway, have the teleport in this hallway run a script that does two things: choose a random team for the player, and also teleport him to the appropriate base. That should look something like this:
Code:
int iTeam;
iTeam = rand( TEAM_BLUE, TEAM_RED ); if ( iTeam == TEAM_BLUE ) {
Player_SetTeam( TEAM_BLUE ); Teleport( <blue base tid> );
} else {
Player_SetTeam( TEAM_RED ); Teleport( <red base tid> );
}
And that pretty much wraps it up! If you have any questions, just feel free to post in this thread.
Thanks everyone for reading! Big grin