GetPlrControlName

Category: Player
Since engine version: 4.9.7.0 CR

Description

Returns the name of the control iCon of iPlr.

Syntax

string GetPlrControlName (int iPlr, int iCon, bool fShort);

Parameters

iPlr:
Number of the player to get the control name from.
iCon:
Control the name is needed of. Possible values:
Name Value
CON_CursorLeft 0
CON_CursorToggle 1
CON_CursorRight 2
CON_Throw 3
CON_Up 4
CON_Dig 5
CON_Left 6
CON_Down 7
CON_Right 8
CON_Menu 9
CON_Special 10
CON_Special2 11
fShort:
If true, the short name of the key is returned. (E.g. "<" instead of "< > |")

Example

Log(GetPlrControlName(0, CON_Dig));
Returns the name of the key [Dig] of the first player. This is "D" in the default keyboard profile 1.
Fulgen / Clonk Wiki, Juli 2016