Game modes
This article gives an overview of the game modes, gametypes, and level types that are available in SRB2. The three concepts are closely related, as they all define ways of playing the game. However, there are subtle differences:
A gametype defines the fundamental rules for how the game is played. For example, in the Match gametype, players score points by shooting rings at each other, and the objective is to score the most points, while in the Single Player gametype, the player must overcome obstacles to reach a goal. A level type defines the gameplay rules for a specific level. There are two groups of level types: The first group specifies which gametypes the level supports. The second group consists of supplementary level types that add further gameplay rules or modify existing ones specifically for the level. An example of a supplementary gametype is 2D mode, which adds the gameplay rule that the player's controls are restricted to two dimensions.
A game mode is any option that the player chooses in the main menu to start a game. It can also define gameplay rules, but primarily it specifies the context and presentation of the game. For example, two-player splitscreen games and netgames both rely on the same gametypes with the same gameplay rules, but one is played by two people on the same computer, while the other is played over the internet.
Game modes
SRB2's game modes are divided into two fundamental categories: single player and multiplayer, both of which have their own entry in the main menu. In each sub-menu, there are several subordinate game modes. Choosing one of these will start a new game.
Single Player
- The campaign is the standard way in which players experience the game. They choose the "Start Game" menu entry, pick a save slot, and play the Single Player maps sequentially. The save slots allow players to restart at the first level of the current zone. Once the last level has been completed, the credits roll and the save slot turns into a level select.
- Ultimate mode is an easter egg in which the player must beat the entire campaign in one run without getting hit once. All power-ups except invincibility and speed shoes are removed and the player has only one life. It is unlocked by typing
ULTIMATE
on the title screen, which will turn the "Play without saving" option into an "Ultimate mode" option. - Marathon Run is a marathon and speedrunner-friendly game mode which is the same as a normal campaign run, but with a global timer at the bottom of the screen.
- Ultimate mode is an easter egg in which the player must beat the entire campaign in one run without getting hit once. All power-ups except invincibility and speed shoes are removed and the player has only one life. It is unlocked by typing
- Record Attack is a game mode in which players replay the maps from the campaign and attempt to establish records for fastest time, highest score, and most collected rings. Replays are recorded in this mode. which the player can play back and watch, or compete against. Levels are unlocked for this mode once they have been visited in the regular campaign or, in the case of secret maps, unlocked.
- NiGHTS Mode is a game mode in which players replay the NiGHTS maps (which include the Special Stages and Spring Hill Zone) and attempt to achieve an A rank or establish records for fastest time and highest score. Each map becomes available in NiGHTS Mode once it has been visited in the regular campaign or, in the case of secret maps, unlocked.
Multiplayer
- Two-player games, also called splitscreen games, are played by two people on the same computer. The screen is split vertically to provide a separate display for each player.
- Netgames are played over the internet. One player hosts a server on their computer and other people join the game by connecting to the server from their own computers. The server can either be advertised publicly on the SRB2 Master Server or, if the netgame is intended to be private, the other players can join by specifying the IP address of the host.
Gametypes
Since the Single Player game mode only features one gametype (also called Single Player), most of the gametypes that come with SRB2 are multiplayer gametypes.
- Single Player and Coop are functionally identical and the game internally considers them to be the same gametype. The difference is that Single Player is played in the Single Player game mode, while Coop (which is short for Cooperative mode) allows players to play the Single Player maps together in multiplayer.
- Competition is similar to Sonic 2's two-player mode. Players run through the Single Player stages, trying to collect as many items and earn as many points as possible. When one player has completed the stage, the other players have 60 seconds to complete the stage or they will die and the round will end. At the end of the round, players will be ranked in several categories, such as score, time, and collected rings.
- Race is also played on the Single Player stages. The objective is to reach the goal as fast as possible. The player with the fastest time wins.
- Match is a gametype akin to traditional deathmatch first-person shooters, played on its own roster of maps. Players toss rings at each other to score points. Hitting a player will make them lose all their items and rewards the scorer with 50 points (or 100 if the opponent is hit without any items and dies). 50 points penalty are subtracted when a player dies. There are six special weapon rings that exhibit a different behavior from regular rings, but the players need to collect weapon tiles and ammunition to use them. Additionally, the seven Chaos Emeralds spawn in random locations in the map, which grants the player Invincibility and Super Sneakers for 20 seconds when collected.
- Team Match works exactly like Match, but the players are divided into a blue and red team. The team with the most cumulative points wins.
- Tag and Hide & Seek are two closely related gametypes that are typically played on Match maps. In both cases, one player is selected to be "it" and then has the objective to find and shoot the other players. The score of the hiding players increases with time until they are shot, while the player who is "it" receives points for every found opponent. In Tag mode, all players can move freely, and shot players become "it" as well, while in Hide & Seek, movement is disabled for the hiding players after a set amount of time, and shot players do not become "it".
- Capture the Flag is similar to Team Match, but each team controls a base containing a flag. The objective of each team is to steal the opposing team's flag and bring it to their own base, while still being in possession of their own flag. If this is achieved, the team scores a point. The game ends when one team has scored five points. Capture the Flag is played on a roster of maps designed specifically for the gametype.
Level types
The level types for a map are defined with the TypeOfLevel
parameter in the level header. There are two groups of level types: gametype-specifying and supplementary.
Gametype-specifying level types
These level types specify which gametypes a level supports. Therefore, they generally correspond to the existing gametypes, except for gametypes that always share the same maps, which are merged into one level type. At least one gametype-specifying level type must be given to each level, otherwise it would not be playable. A level can support multiple gametypes, but it can only be played in one gametype at a time.
The following gametype-specifying level types exist: Single Player, Coop, Competition, Race, Match (includes Team Match), Tag (includes Hide & Seek), and Capture the Flag.
Supplementary level types
These level types modify certain gameplay aspects regardless of the gametype that the map is played in. While they technically take effect in any gametype, it generally only makes sense to combine them with certain gametypes.
- 2D mode restricts the player's movement to two dimensions. It is normally used in conjunction with Single Player, although it is theoretically possible to use it with any gametype.
- Mario mode emulates Super Mario-like gameplay in SRB2. On its own, it mainly exchanges some sounds to fit the Mario theme. It is used in conjunction with special graphics and level elements to create Mario-themed levels.
- NiGHTS emulates the SEGA game NiGHTS Into Dreams in SRB2. The player flies along a curved 2D track as a character's NiGHTS form, flying through hoops and collecting items to destroy an Ideya Capture. SRB2 uses this mode for its Special Stages. NiGHTS should be used in conjunction with either Single Player or Race.
- ERZ3 mode was used for Egg Rock Zone Act 3 in v2.0 to make Brak Eggman appear larger. In this mode, all Objects besides the old Brak Eggman are scaled down to 50% of their normal size.
- Christmas NiGHTS exchanges a few NiGHTS-related graphics and sounds to be Christmas-themed. It is unused by SRB2 itself. Note that NiGHTS maps that have this level type still need to have the NiGHTS level type as well.
- Custom is an option that does nothing by itself, but can be used by Lua scripts to create a custom level type. The simplest way to do this is by using the
MapLoad
hook to check if the current map supports the Custom level type and then applying the desired changes. However, keep in mind that it is generally a better idea to use the freeslot system to define a new level type constant, to ensure cross-mod compatibility.
Other level types
These level types are not technically considered as such by the game, in the sense that they are not specified via the TypeOfLevel
parameter, but they nonetheless serve the same purpose. They are specified by other means, such as putting the level in a special map slot or placing a special Thing on the map.
- Special Stages are levels where the player tries to obtain a Chaos Emerald. They are stored in specially designated map slots and are automatically warped to when the player finishes a level after having collected a Special Stage Token. SRB2 supports two types of Special Stages: NiGHTS stages like the ones that are used in SRB2 itself, and levels where the player must collect a certain number of blue spheres in a certain time, like the Special Stages in old versions of SRB2 and which are used for the Multiplayer Special Stages.
- Emerald Hunt is a level type where the player's objective is not to get to the goal, but to collect three emeralds that are hidden in the map, similar to Knuckles's stages in Sonic Adventure. Emerald Hunt maps are normal Single Player levels, but instead of an exit sector, emerald spawn points are placed on the map. If such spawn points are present in a map, the game will automatically end the level once the player has obtained three emeralds.
- Circuit is an alternative type of Race level in which the maps have a circular layout, and in which the players must complete a certain number of laps through the finish line (marked by the Circuit Finish Line sector type) to finish the stage.
Custom gametypes
Since v2.2.1, modders have the option to create custom gametypes with their own rules and gamelogic, allowing for more flexible game modes. All custom gametypes are Multiplayer-exclusive options.
Attributes
These are the necessary attributes to define a gametype. If not specified, most of them will default to 0.
TypeOfLevel
: The level types this gametype is allowed to use. It is also possible to declare custom TypeOfLevel constants via freeslots.Identifier
: This generates the constant to which the gametype will be referred to in code.Identifier = "hangout"
will create a corresponding gametype constantGT_HANGOUT
.Rules
: The gametype's rules, which govern the most basic aspects of how the gametype is supposed to play. The bitwise OR|
operator should be used on these values to combine them, e.g.GTR_SPECTATORS|GTR_RINGSLINGER|GTR_TEAMS
.
Keyword | Explanation |
---|---|
GTR_CAMPAIGN
|
This gametype ensures linear progression through levels, not allowing random picks. Only used by Co-op. |
GTR_RINGSLINGER
|
This is a gametype where players can throw rings to attack. Can be overriden by the value of the ringslinger console variable. Used by Match, Team Match, Tag, Hide & Seek, and CTF.
|
GTR_SPECTATORS
|
This gametype allows players to spectate. Used by all GTR_RINGSLINGER gametypes.
|
GTR_LIVES
|
This gametype features lives. Used by Co-op and Competition. |
GTR_TEAMS
|
This gametype features teams. Used by Team Match and CTF. |
GTR_FIRSTPERSON
|
This gametype defaults the player's camera to first person view. Used by all GTR_RINGSLINGER gametypes.
|
GTR_POWERSTONES
|
Multiplayer Emeralds are allowed to spawn in this gametype. Used by Match and CTF. |
GTR_TEAMFLAGS
|
Team flags are allowed to spawn in this gametype. Used by CTF only. |
GTR_FRIENDLY
|
This gametype is non-competitive. Used by Co-op only. |
GTR_SPECIALSTAGES
|
This gametype allows Special Stages to be accessed via Emerald Tokens. Used by Co-op only. |
GTR_EMERALDTOKENS
|
Emerald Tokens are allowed to spawn in this gametype. Used by Co-op and Competition. |
GTR_EMERALDHUNT
|
This gametype will start an Emerald Hunt if any Emerald Hunt Locations are placed, and end the level when three Chaos Emeralds are found. Used by Co-op only. |
GTR_RACE
|
This gametype is a race with an initial countdown. Levels will end 60 seconds after the first player finishes the circuit. Used by Race and Competition. |
GTR_TAG
|
This gametype is a game of Tag. Used by Tag and Hide & Seek. |
GTR_POINTLIMIT
|
This gametype can end levels when a point limit is reached. Used by all GTR_RINGSLINGER gametypes.
|
GTR_TIMELIMIT
|
This gametype can end levels when a time limit is reached. Used by all GTR_RINGSLINGER gametypes.
|
GTR_OVERTIME
|
This gametype will start an overtime when both teams, or two or more players are tied. Can be overriden by the overtime variable.
|
GTR_HURTMESSAGES
|
This gametype will display a battle log in the console. Used by all GTR_RINGSLINGER gametypes.
|
GTR_FRIENDLYFIRE
|
This gametype allows players to attack other players by throwing rings regardless of team. Can be overriden by the value of the friendlyfire variable.
|
GTR_STARTCOUNTDOWN
|
This gives GTR_TAG gametypes an initial countdown for players to flee and hide from the "it".
|
GTR_HIDEFROZEN
|
In GTR_TAG gametypes, players won't be allowed to move after GTR_STARTCOUNTDOWN has elapsed, or not been set. Used by Hide & Seek only.
|
GTR_BLINDFOLDED
|
In GTR_TAG gametypes, this will blindfold the "it" player during fleeing/hiding time if GTR_STARTCOUNTDOWN has been set.
|
GTR_RESPAWNDELAY
|
This gametype makes use of the respawndelay variable to set a timer before players can respawn. Used by all GTR_RINGSLINGER gametypes.
|
GTR_PITYSHIELD
|
This gametype makes use of the pity counter to award losing players a Pity Shield. Used by Match, Team Match and CTF. |
GTR_DEATHPENALTY
|
This gametype penalizes players by 50 points for dying. Used by Match only. |
GTR_NOSPECTATORSPAWN
|
Players spawn in the game by default, instead of as spectators. Must be coupled with GTR_SPECTATORS .
|
GTR_DEATHMATCHSTARTS
|
This gametype uses Deathmatch spawns as a first option for spawning players. |
GTR_SPAWNINVUL
|
This gametype spawns players with temporary invincibility. Used by all vanilla gametypes except Co-op. |
GTR_SPAWNENEMIES
|
Enemies are allowed to spawn in this gametype. Used by Co-op, Competition and Race. |
GTR_ALLOWEXIT
|
Players can end a level by touching an Exit Sector. Used by Co-op, Competition and Race. |
GTR_NOTITLECARD
|
This gametype does not display a title card. |
GTR_CUTSCENES
|
This gametype allows cutscenes, the ending sequence, credits and the secrets evaluation screen to be displayed. Used by Co-op only. |
DefaultTimeLimit
: If the ruleGTR_TIMELIMIT
is present, this will set a default time limit for the gametype's matches, in minutes.DefaultPointLimit
: if the ruleGTR_POINTLIMIT
is present, this will set a default point limit for the gametype's matches.Description
: The description of the gametype in the level select platter. Defaults to "???" if not specified.HeaderColor
: The bar color of the gametype in the level select platter. This overridesHeaderLeftColor
andHeaderRightColor
. This attribute, as well as the subsequent two, must be indices from the palette.HeaderLeftColor
: The color of the first half of the gametype's bar in the level select platter. Used in vanilla for CTF.HeaderRightColor
: The color of the second half of the gametype's bar in the level select platter. Used in vanilla for CTF.RankingType
: The type of ranking the gametype will use in the Multiplayer score tally when Tab is held. Can use one of the vanillaGT_
constants.IntermissionType
: The type of intermission the gametype will use between levels. Can use one of the constants in the table below.
Constant | Type |
---|---|
int_none
|
No intermission, skips straight to the next level |
int_coop
|
Single Player and Co-op "Sonic got through the act" style intermission |
int_match
|
Match, Tag and Hide & Seek score tally |
int_teammatch
|
Team Match score tally |
int_ctf
|
Capture the Flag score tally |
int_race
|
Race score tally |
int_competition
|
Competition score tally |
int_spec
|
Special Stage intermission, displays the amount of emeralds the player has |
SOC definition
This is an example of a gametype definition written with SOC and the syntax it uses. The definition must end with a #
character.
GameType Hangout TypeOfLevel = Coop,Hangout Identifier = "hangout" Rules = GTR_SPECTATORS|GTR_FRIENDLY|GTR_NOSPECTATORSPAWN|GTR_NOTITLECARD IntermissionType = int_none HeaderColor = 103 Description = "Chill out from the battles and races and relax with your friends in your favorite levels without a care in the world." #
Lua definition
This is an example of a gametype definition written with Lua. It must be done in the form of a table passed to the function G_AddGametype
. Note that all attributes need to be in lowercase.
G_AddGametype({
name = "Hangout",
identifier = "hangout",
typeoflevel = TOL_COOP|TOL_HANGOUT,
rules = GTR_SPECTATORS|GTR_FRIENDLY|GTR_NOSPECTATORSPAWN|GTR_NOTITLECARD,
intermissiontype = int_none,
headercolor = 103,
description = "Chill out from the battles and races and relax with your friends in your favorite levels without a care in the world."
})
Outdated gametypes and level types
These gametypes and level types were once featured in SRB2, but have been removed for various reasons and are no longer in the game.
- Chaos was a gametype that was introduced in SRB2 2k3 and remained in the game until Final Demo 1.08. In this gametype, random enemies would spawn from designated spawn points and players would compete to kill these enemies for a high score. Killing multiple enemies in one move would increase the score rapidly, while dying halved it. Chaos was played both on Match maps and on maps designed specifically for the gametype, which were similar to Match maps but generally smaller and simpler. The gametype was poorly received and was eventually disabled in Final Demo 1.09.
- Ice Hockey was a level type that only appeared once in Final Demo 1.08 and was only used for a single stage, Ice Hockey Zone. It was similar to CTF, the objective being to push a snowman onto the goal of the opposing team. Due to a bug, the map was not playable and the mode was subsequently removed.
- Golf was a level type that also appeared in Final Demo 1.08, to be played on Single Player levels. Golf levels played similarly to normal Single Player levels, but in a golf-like fashion: The player was unable to do anything except charge spindashes to move across the level. Each spindash would be counted as a "putt", the total of which would be compared against the map's par requirement to gain bonus points at the end of the level. No Golf maps were included in SRB2 officially, and the level type was scarcely used at all, which led to it being removed in the next release.
- Adventure mode was a level type during the Final Demo era that emulates some gameplay elements of Sonic Adventure, such as analog control, the homing attack and the light dash. It was used for the unlockable SA Example Zone. While analog control is still available as a control scheme and the homing attack is usable as an ability for custom characters, the level type itself was removed in v2.0 due to poor reception and limited usage.
Game modes | [view] | |
Game modes | Campaign • Ultimate mode • Marathon Run • Record Attack/NiGHTS Mode • Multiplayer | |
Gametypes | Single Player/Co-op • Competition • Race • Match/Team Match • Tag/Hide & Seek • Capture the Flag | |
Level types | Supplementary: 2D mode • Mario mode • NiGHTS Other: Special Stage • Emerald Hunt |