From SRB2 Wiki
Jump to: navigation, search

The S_SKIN is a special text lump that is used to define a playable character skin for SRB2. It determines the name of the skin, the graphics used to represent the skin, and various attributes for the character itself; e.g. abilities, movement speeds and items spawned. The lump itself also acts as a starting marker for the character's sprites, which must immediately follow it within a WAD file.

The exact name of this lump given in a WAD file is partially flexible – the game will only check if the lump's name starts with "S_SKIN" in order for it to be recognised as the definition of a new skin. Anything can be used after these first six characters, e.g. S_SKIN1, S_SKIN2, and S_SKINA are all acceptable alternatives to S_SKIN as the lump name.


The format of text within S_SKIN is very similar to that of a SOC lump; for instance, text in the S_SKIN lump is not case-sensitive. That means "facename" can be identified as "facename", "FACENAME", "FaceName", or even "FaCeNaMe", and it will still be recognised as the same thing.

When placed at the start of a line, the '#' (number sign, or hash) symbol is used to signify the start of a comment, just as in SOCs. However, comment lines can also be started by placing two forward slashes in a row (//) at the start of a line.

This is a typical example of what an S_SKIN lump may look like:

name = Idreia
ability2 = CA2_NONE
normalspeed = 36
thrustfactor = 3
accelstart = 112
acceleration = 42
startcolor = 200
prefcolor = Steel_Blue
jumpfactor = 1

Note that you don't have to supply all parameters available for S_SKIN (see below), or even anything at all (this is not recommended though). Whatever is left out will fall on a set of default stats.



Default: skin [number]

The unique name of the skin, for identification purposes internally. It is used with the SKIN command in the console and will always be used and displayed in all lowercase. Spaces are not allowed; use underscores instead. If another skin of the same name is added to the game, the game will automatically give the latter skin a number onto the end of it's name – ensure your skin name is completely unique to avoid this, possibly tagging it with your own username (or an abbreviation of it).

Example: name = metalsonic


Default: 0

Determines the skin flags given to the skin – these are a series of toggles that determine whether certain miscellaneous traits available for a character are applied.

Decimal Hexadecimal Flag name Description
1 0x01 SF_SUPER Determines if the character can turn Super in Single Player/Coop after collecting all Chaos Emeralds; used only by Sonic in unmodified SRB2.
2 0x02 SF_SUPERANIMS The character uses the designated special ability animations (frames U–Z) for the character's Super form, much like Sonic does. This does not include the Super transformation, which has been separated and no longer requires this flag. If this flag is not set, the normal character animations are used while Super.

If set, then frames U and V are used for Super standing, frames W and X are used for Super running, frame Y is used for tipping on an edge, and frame Z is used for getting hurt while Super.

4 0x04 SF_SUPERSPIN If the character has ability2 set to CA2_SPINDASH, the character's Super form will use the normal spinning animations when jumping, spindashing or otherwise rolling on the ground. If this flag is not set, the character will instead use standing, walking or running animations when performing these actions, as Super Sonic himself did in versions of SRB2 before v1.09.4.

This flag's effects are relevant only if SF_SUPERANIMS is also set; without it, its effects are redundant as the character's Super form will be able to use spinning animations regardless of whether this flag is set or not. If the character does not have CA2_SPINDASH, this flag will do nothing anyway (except when forced to use the spinning animations, such as in a zoomtube).

8 0x08 SF_HIRES The character's sprites will be rendered at a different scale to normal; by default they will be render at half-size. See highresscale for precise control over this feature.
16 0x10 SF_NOSKID The character does not display skid particles and sounds when braking or making sharp turns.
32 0x20 SF_NOSPEEDADJUST The character's animations will not be automatically adjusted according to the player's velocity, for example when Sonic's walking animation speeds up as he walks faster. Instead, the animations will use the default state durations as set in the player's states.
64 0x40 SF_RUNONWATER Allows the character to run on top of water and goop FOFs.

The skin flags are stored in an integer where every bit represents a flag, i.e. 0 means "disabled" and 1 means "enabled". To set several flags at once, the bitwise OR operator (|) has to be performed on them.



Default: ???

The name of the character displayed next to the life icon on the HUD. It is recommended to keep this name length low to fit with the standard five letter lives icons. If not given, this defaults to the value given by realname if it is set, or otherwise by name.

Example: hudname = METAL


Default: Someone

The "real" name of the character displayed by the game in general, e.g. on intermission screens, the multiplayer character select screen, etc. This is not required to be a unique name, unlike with name. If not given, this defaults to the value given by hudname if it is set, or otherwise by name.

Example: realname = Metal_Sonic



The lump name for the character portrait displayed for the character in Single Player's character select screen and the Record Attack screen. This image must be exactly 128×128 pixels in size, or 256×256 for high resolution. XWE automatically gives this offsets, but this lump should not have any.


Default: MISSING

The lump name to the life icon used for the character. The life icon is a 32×32 picture shown at the bottom-left of the screen as part of the HUD. Although the value is not case-sensitive (values "STLIFE", "stlife", and "StLiFe" all point to the lump "STLIFE"), it's very highly recommended to input the value in all caps, to match that the lump name is presumably all caps as well. It's more elegant and accepted this way. XWE automatically gives this offsets, but this lump should not have any.

Example: face = METALIFE


Default: MISSING

The lump name of the character's life icon when they turn Super. If not given, this defaults to the life icon graphic given by face.

Example: superface = METALSUP


Default: CA_NONE

The character's primary ability, such as Sonic's thok, or Tails's flying ability. Only one may be selected. The values possible are as follows:

Value Ability Description
CA_NONE No ability The character will not have a special ability. This is the default ability given to characters that do not have one set.
CA_THOK Speed thok Sonic's default ability, loosely based on Sonic's air dash attack from Sonic Adventure. Pressing jump a second time in mid-air will thrust the player forward at the speed determined by actionspd.
CA_FLY Flying Tails' default ability, based on Tails' flight ability from Sonic 3. Pressing jump a second time in mid-air will make the player start flying in mid-air – repeatedly pressing jump afterwards will allow the player to fly further upwards. However, the player will be unable to fly after a limited amount of time (determined by TailsFlyTics in the MainCfg block, which is by default 8 seconds). The speed the player moves upwards or downwards when flying is determined by actionspd.

Other notes about flying:

  • The player's top speed will be reduced, but acceleration is increased to compensate.
  • The spin button can be used to descend more quickly if necessary.
  • The player will be unable to inflict damage to enemies, except by flying into them from below.

Frames U and V are used for the flying animation, and frames W–Z are used when the character can't fly anymore.

CA_GLIDEANDCLIMB Gliding and climbing Knuckles' default ability, based on Knuckles' abilities (gliding, climbing and rock smashing) from Sonic & Knuckles. Pressing jump a second time in mid-air will make the player start a glide – the player will accelerate forward from a starting speed determined by actionspd for as long as the jump button is held down. However, the player will gradually fall down while doing so. The player will be able to damage all enemies that touch them while using this ability. The player will also skid when landing on the ground from gliding, slowing down to a grinding halt when doing so.

If the player glides into a wall, they will latch onto it and can move in any direction up, down or to the sides of it, and can climb over to other walls if possible. If the player is climbing, pressing jump will make them jump off and face away from the wall; pressing spin will make them jump away while still facing the wall. However, not all walls are climbable; some linedefs may have the Not Climbable flag checked, which prevents characters with this ability from climbing it. Any walls that are part of the sky will also not be climbable regardless of linedef flags.

Additionally, characters with this ability will be able to destroy all types of bustable FOFs on touch, rather than needing to spin into them. Some bustable FOFs will have the FF_KNUXONLY flag set – this prevents anyone from destroying them except characters with this ability.

Frames U and V are used for the gliding animation, frame W is used for the climbing "standing", and frames X–Z are used for the actual climbing movement animation.

CA_HOMINGTHOK Homing attack A weakened version of the speed thok ability, but with the addition of a homing attack feature similar to that of Sonic Adventure's and beyond – if an enemy, spring or monitor is close enough to the player when triggering the ability, the player will home in towards the target Object until they touch/destroy it. If the character fails to reach the Object within 3 seconds, the homing attack is automatically cancelled.
CA_SWIM Swimming Similar to the flying ability, except this ability will work only underwater; attempting to use this ability outside of water will do nothing. Also unlike flight however, the ability can be used indefinitely while underwater. Characters with this ability will also be given the ability to run on water.
CA_DOUBLEJUMP Double jump Pressing jump a second time in mid-air will make the player do a second jump.
CA_FLOAT Floating Pressing jump a second time in mid-air and holding the button down will allow the player to hold their vertical position mid-air continuously, similarly to Super Sonic's own floating ability but without the limitation of needing to move while doing so.
CA_SLOWFALL Floating with slow descent Pressing jump a second time in mid-air and holding the button down will cause the player to fall at a fixed rate downwards, slowing down the rate the character falls down. This is similar to E-102 Gamma's booster powerup from Sonic Adventure.
CA_TELEKINESIS Telekinesis Pressing the jump button in mid-air will push enemies and players within a set radius around the player away; pressing spin in midair will pull them closer instead. The thrust of the pushing/pulling is determined by actionspd.
CA_FALLSWITCH Fall switch Reverses the player's vertical momentum when pressing jump in mid-air, thrusting them in the opposite direction instead.
CA_JUMPBOOST Jump boost The faster the player moves about, the higher the player's jump speed will be. actionspd is used as a multiplier for the jump boost given. Pressing the jump button in mid-air has no effect otherwise.
CA_AIRDRILL Air drill Pressing jump a second time in mid-air will initiate an air drill, thrusting the player forward at the angle they're facing. The player will fly in an arc, eventually finishing the drill when the player is falling down to the ground. Holding the spin button while drilling will cause the player to descend more swiftly. actionspd is used as an angular speed for the drill.
CA_JUMPTHOK Jump-thok A hybrid between the thok and the double jump. Gives the player a burst of speed and an extra jump with each use.
Example: ability = CA_THOK



The character's secondary ability. Only one of these may be selected; the level header rule of adding numbers to combine properties does not apply here. The values possible are as follows:

Value Ability Description
CA2_NONE No ability The player will not have a secondary special ability. The player will jump with the springing/falling animation frames (P, `, and lowercase a).
CA2_SPINDASH Spindash The default secondary ability for Sonic, Tails and Knuckles. The player can use the Spin control to charge a spindash, or otherwise spin on the ground while moving. The player will also jump with the spinning animation (frames L–O).
CA2_MULTIABILITY Multiability Changes how the player's special ability functions, depending on the value set for ability. By default, this simply allows the special ability to be used more than once per jump; for a number of abilities this applies other effects instead:
  • CA_FLY/CA_SWIMSonic Adventure-style flight: Jump button can be held down for the character to fly upwards, instead of being repeatedly pressed. Note that the overall strength of this is stronger than normal flight, so actionspd should be adjusted accordingly.
  • CA_DOUBLEJUMP – Greatly increases the character's jump speed, instead of allowing repeated use of the ability per jump.
  • CA_FLOAT/CA_SLOWFALL – Increases the character's jump speed, in addition to allowing repeated use of the ability per jump.
  • CA_JUMPBOOST – Doubles the jump speed increase given to the character.

The player will jump with the springing/falling animation frames (P, `, and lowercase a).

Example: ability2 = CA2_SPINDASH


Default: 30

Defines the speed value of the character's special ability, or how fast the character can move when performing their special ability. This only applies for thokking, flying, gliding, swimming and homing attack. A negative value can also be given to actionspd to make any of the abilities do reverse actions. The thok becomes reversed and sends the player backwards, flight and swim become unable to rise and are turned into a slow fall that gradually becomes faster and can't hurt enemies, and glide becomes a backwards glide that cannot climb walls.

Example: actionspd = 20
  • Sonic – 60
  • Tails – 100
  • Knuckles – 25


Default: 15

Defines the minimum speed that the character can spin at after charging a spindash.

Example: mindash = 15


Default: 90

Defines the maximum speed that the character can spin at after charging a spindash. Setting this to "0" will cause the player to spin in place after releasing a spindash – this can be used to give the character a mêlée attack.

Example: maxdash = 90


Default: 36

The character's normal top running speed, without power-ups.

Example: normalspeed = 32
  • Sonic – 36
  • Tails – 32
  • Knuckles – 34


Default: 28

Defines at which speed the character starts going into their running animation. This does not have to be within the confines of the character's normalspeed. An example would be Tails from v1.09.4 and older, where he could only reach his runspeed by use of Super Sneakers.

Example: runspeed = 30


Default: 5

Has to do with the character's speed. Literally, as found in the SRB2 source, "Thrust = thrustfactor * acceleration".

In other words, the character's other speed values are multiplied by whatever value thrustfactor is to give a complete picture of the character's speed. The higher the thrustfactor, the more speedy the character is. Think "thrust factor"; the character thrusts themselves forward by a factor of this much (whatever the value for this attribute is).

Example: thrustfactor = 3
  • Sonic – 5
  • Tails – 3
  • Knuckles – 4


Default: 96

The rate that the character starts to accelerate at from when they first stand still. Once one first presses the key, the character's speed will increase by this much until they gain enough speed.

Example: accelstart = 128
  • Sonic – 96
  • Tails – 192
  • Knuckles – 128


Default: 40

The rate the character accelerates once they are already moving. When moving, their speed will increase by this much per certain amount of time until it reaches the normalspeed.

Example: acceleration = 40
  • Sonic – 40
  • Tails – 50
  • Knuckles – 45


Default: 160

Specifies the range of colors of the palette on the character's sprites that can change in multiplayer mode. This is a range of 16 colors, starting from the palette color index specified by this parameter. See List of skin colors for more information.

Example: startcolor = 192


Default: Green

Specifies the default skin color for the character. This is required for Single Player, where the character's color cannot be changed by the player. The possible values are as follows.

White Silver Grey Black Cyan Teal Steel_Blue Blue Peach Tan Pink Lavender Purple Orange Rosewood Beige Brown Red Dark_Red Neon_Green Green Zim Olive Yellow Gold
Example: prefcolor = Blue


Default: 1.0

Sets the jump speed, measured as a factor of the default jump thrust. The usual setting (and the default) for this would be 1.0 (1.0× the default jump thrust), although Knuckles has it set to 0.85.

Example: jumpfactor = 1.0


Default: 0.5

If the skin flag SF_HIRES is set, this parameter is used to set exactly what relative size to draw this skin's sprites at. It defaults to 0.5, for double-resolution sprites to be drawn at half-scale. This setting does not affect the character's hitbox, however.

Example: highresscale = 0.5


Default: -1

Replaces the default translucent speed trail left behind by thokking with an Object of the specified Object type. The default is -1, which results in MT_THOK.

Example: thokitem = MT_THOK


Default: -1

Replaces the default translucent speed trail left behind by spindashing and spinning on the ground with an Object of the specified Object type. The default is -1, which results in MT_THOK.

Example: spinitem = MT_THOK


Default: -1

Replaces the default translucent circles created by charging a spindash with an Object of the specified Object type. The default is -1, which results in MT_THOK.

Example: revitem = MT_THOK

Custom sounds

As an optional feature, the S_SKIN lump is capable of replacing specific sounds (e.g. jumping, spinning, spilling rings) with alternative sounds exclusively for the corresponding character (i.e. the sound will be unchanged when played for other characters) – these can be sound files that already exist in srb2.srb, sound files that exists in another external file, or (most frequently) custom sound files provided in the WAD file containing the character and S_SKIN lump itself. The new sound(s) will not take up any sound freeslots.

The S_SKIN defines custom sounds for a character by using the lump names of the original sound and the sound to replace it, such as in the example displayed below:

dsthok = dsmythok

This will cause any instance of sfx_thok (lump name DSTHOK) to be replaced by a sound whose lump name is DSMYTHOK, whenever the sound's origin is of a player using the character associated with the S_SKIN.

Below is the full list of sounds that can have character-specific replacement sounds through a character's S_SKIN – any other sounds besides these will not be accepted in the S_SKIN:

Lump name Sound name Description
DSSPIN sfx_spin Sound made when going into a spin while moving
DSPUTPUT sfx_putput Tails flying
DSPUDPUD sfx_pudpud Tails exhausted from flying
DSTHOK sfx_thok Sonic thokking
DSSPNDSH sfx_spndsh Spindash charge
DSZOOM sfx_zoom Spindash release
DSGASP sfx_gasp Grabbing an air bubble
DSJUMP sfx_jump Jumping
DSSKID sfx_skid Skidding
DSALTOW1 sfx_altow1 Pain taunts #1–#4 1
DSALTOW2 sfx_altow2
DSALTOW3 sfx_altow3
DSALTOW4 sfx_altow4
DSVICTR1 sfx_victr1 Victory taunts #1–#4 1
DSVICTR2 sfx_victr2
DSVICTR3 sfx_victr3
DSVICTR4 sfx_victr4
DSALTDI1 sfx_altdi1 Death taunts #1–#4 1
DSALTDI2 sfx_altdi2
DSALTDI3 sfx_altdi3
DSALTDI4 sfx_altdi4

1 The game will randomly select any one of the four taunts when needed – to increase the chances of playing a specific sound, more than one of these slots can be replaced with the same custom sounds. If only one taunt sound is needed, all four of the slots should be replaced with the same custom sound.

Related links