It is possible to allow the user to select a character for the player from a list of predefined characters. These characters can have different characteristics and are completely definable. To allow the character selection menu to be activated you must use the IniEditor and check the Allow Character Selection box. Then, right after the New Game button is clicked, the Character Selection menu will appear.
You define the characters the player can choose from in a file called character.ini. Each section of the file defines a different character and you can have up to 10 sections. A section is defined like this :
[CharacterName]
image
|
CEGUI image displayed in menu (set:imageset image:imagename) |
actorname
|
name of actor to use |
actorrotation
|
base rotation of actor |
actorscale
|
scale of actor |
The following section entries are optional and, if used, will override the entry's definitions later in the level.
icon
|
CEGUI image used as the conversation icon (set:imageset image:imagename) |
animationspeed
|
multiplication factor for actor animations |
shadowsize
|
size of actor shadow |
shadowalpha
|
alpha of shadow |
shadowbitmap
|
bitmap to use as shadow |
shadowalphamap
|
alphamap for shadow bitmap |
projectedshadows
|
if true use projected shadows
|
stencilshadows
|
if true use stencil shadows
|
fillcolor
|
fill color of actor lighting |
ambientcolor
|
ambient color of actor lighting |
ambientlightfromfloor
|
if true ambient color is taken from the floor
|
weaponfile
|
name of INI file replacing weapon.ini |
attributefile
|
name of INI file containing player's attributes |
playersetupfile
|
name of INI file replacing PlayerSetup.ini |
environmentfile
|
name of INI file replacing environment.ini |
hudfile
|
name of INI file containing definitions for the Hud |
speed
|
movement speed of player |
jumpspeed
|
jump speed of player |
stepheight
|
step up height of player |
slopeslide
|
minimum slope to start sliding |
slopespeed
|
maximum slope sliding speed |
startlevel
|
name of start level for this character |
playerstartname
|
name of PlayerStart entity to use |
For example, a character called Elf could be defined like this:
[Elf]
image = set:characters image:elf
icon = set:characters image:elf_icon
actorname = elf.act
actorrotation = 0 180 0
actorscale = 1
animationspeed = 1
stencilshadows = true
fillcolor = 32 32 32
ambientcolor = 100 100 100
ambientlightfromfloor = false
weaponfile = elfweapon.ini
attributefile = elf.ini
playersetupfile = elfsetup.ini
environmentfile = elfsounds.ini
hudfile = elfhud.ini
speed = 15
jumpspeed = 10
stepheight = 30
slopeslide = 0.9
slopespeed = 50