StatusScreen
Show declaration
class StatusScreen abstract play version("2.5");
The base class for intermission status screens. Any status screen used by MAPINFO GameInfo must be derived from this class.
Class Methods
-
static int, int, int GetPlayerWidths()
-
static color GetRowColor(PlayerInfo player, bool highlight)
-
static void GetSortedPlayers(in out array<int> sorted, bool teamPlay)
-
TO-DO — This section is not finished yet
-
static void PlaySound(sound snd)
-
Plays a UI sound at full volume using
S_StartSound.
Overview of class methods
Instance Methods
-
void SetSize(int width, int height, int wrapW = -1, int scaleMode = FSMODE_SCALETOFIT43)
-
int DrawCharPatch(Font fnt, int charCode, int x, int y, int translation = Font.CR_UNTRANSLATED, bool noMove = false)
-
void DrawTexture(textureId tex, double x, double y, bool noMove = false)
-
void DrawText(Font fnt, int color, double x, double y, string s, bool noMove = false, bool shadow = false)
-
int DrawName(int y, textureId tex, string levelName)
-
int DrawAuthor(int y, string levelName)
-
deprecated("3.8") int DrawPatchText(int y, PatchInfo pInfo, string stringName)
-
int DrawPatchOrText(int y, PatchInfo pinfo, textureId patch, string stringName)
-
virtual int DrawLf()
-
virtual int DrawEl()
-
int DrawNum(Font fnt, int x, int y, int n, int digits, bool leadingZeros = true, int translation = Font.CR_UNTRANSLATED, bool noMove = false)
-
void DrawPercent(Font fnt, int x, int y, int p, int b, bool show_Total = true, int color = Font.CR_UNTRANSLATED, bool noMove = false)
-
void DrawTimeFont(Font printFont, int x, int y, int t, int color)
-
void DrawTime(int x, int y, int t, bool no_Sucks = false)
-
void DrawTextScaled(Font fnt, double x, double y, string text, double scale, int translation = Font.CR_UNTRANSLATED)
-
void DrawNumScaled(Font fnt, int x, int y, double scale, int n, int digits, int translation = Font.CR_UNTRANSLATED)
-
void DrawPercentScaled(Font fnt, int x, int y, int p, int b, double scale, bool show_Total = true, int color = Font.CR_UNTRANSLATED)
-
void DrawTimeScaled(Font fnt, int x, int y, int t, double scale, int color = Font.CR_UNTRANSLATED)
-
bool AutoSkip()
-
TO-DO — This section is not finished yet
-
virtual void Drawer()
-
Called by
WI_Drawer, which is called every frame whenGameStateisGS_INTERMISSION.
-
virtual void End()
-
Called when the intermission should end. Default behaviour is to set
CurStatetoStatusScreen.LEAVINGINTERMISSIONand remove bots in death-match. Generally,LevelLocals.WorldDoneshould be called directly after this.
-
virtual void Start(WbStartStruct wbs)
-
Called by
WI_Startafter theWbStartStructis populated, sounds are stopped and the screen blend is set to black. Sets up initial values and runsInitStats.
-
virtual void StartMusic()
-
Called in the first tic by
Tickerto set the intermission music.
-
virtual void Ticker()
-
Called by
WI_Ticker, which is called every game tic whenGameStateisGS_INTERMISSION.
-
protected virtual void DrawNoState()
-
Called by
DrawerwhenCurStateisStatusScreen.NOSTATEor any other non-state.
-
protected virtual void DrawShowNextLoc()
-
Called by
DrawerwhenCurStateisStatusScreen.SHOWNEXTLOCand, by default,DrawNoStateafter settingSnl_PointerOntotrue.
-
protected virtual void DrawStats()
-
Called by
Drawerdirectly after drawing the animated background whenCurStateisStatusScreen.STATCOUNT.
-
protected virtual void InitNoState()
-
Called by
UpdateShowNextLocto initiate theStatusScreen.NOSTATEstage.
-
protected virtual void InitShowNextLoc()
-
Called by
UpdateStatsto initiate theStatusScreen.SHOWNEXTLOCstage.
-
protected virtual void InitStats()
-
Called by
Startto initiate theStatusScreen.STATCOUNTstage.
-
protected virtual void UpdateNoState()
-
Called by
TickerwhenCurStateisStatusScreen.NOSTATEor any other non-state. Exits the intermission by callingEndandLevelLocals.WorldDonewhen appropriate.
-
protected virtual void UpdateShowNextLoc()
-
Called by
TickerwhenCurStateisStatusScreen.SHOWNEXTLOC. RunsInitNoStatewhen appropriate and alternatesSnl_PointerOn.
-
protected virtual void UpdateStats()
-
Called by
TickerwhenCurStateisStatusScreen.STATCOUNT. RunsInitShowNextLocwhen appropriate.
-
protected void CheckForAccelerate()
-
Updates the values of
AccelerateStageandPlayerReadyaccording to each player's inputs.
-
protected int FragSum(int playerNum)
-
Returns the number of frags player
playerNumhas accumulated against all currently in-game players. This is different fromWbPlayerStruct.FragCountbecause it is counted dynamically, i.e. if a player leaves the count will be changed. This is only useful for game modes where frags do not count as score.
Overview of instance methods
AutoSkip, CheckForAccelerate, DrawAuthor, DrawCharPatch, DrawEl, DrawLf, DrawName, DrawNoState, DrawNum, DrawNumScaled, DrawPatchOrText, DrawPatchText, DrawPercent, DrawPercentScaled, DrawShowNextLoc, DrawStats, DrawText, DrawTextScaled, DrawTexture, DrawTime, DrawTimeFont, DrawTimeScaled, Drawer, End, FragSum, InitNoState, InitShowNextLoc, InitStats, SetSize, Start, StartMusic, Ticker, UpdateNoState, UpdateShowNextLoc, UpdateStats
Instance Members
-
-
The background for this intermission, set by
Startwith the initialWbStartStructobject.
-
int AccelerateStage
-
Used to signify to the current stage that it should go quicker or be skipped entirely.
-
bool[MAXPLAYERS] PlayerReady
-
Used in networked games to signify when each player is ready to continue to the next map. Set by
CheckForAccelerate.
-
int Me
-
The value of
Wbs.PNumwhenStartwas called. Usually not changed, so essentially equivalent toWbs.PNum.
-
int BCnt
-
TO-DO — This section is not finished yet
-
int CurState
-
The current stage the intermission is in.
-
-
The
WbStartStructpassed to this class via theStartfunction.
-
-
The value of
Wbs.PlyrwhenStartwas called. Usually not changed, so essentially equivalent toWbs.Plyr.
-
int OtherKills
-
int Cnt
-
int Cnt_OtherKills
-
int[MAXPLAYERS] Cnt_Kills
-
int[MAXPLAYERS] Cnt_Items
-
int[MAXPLAYERS] Cnt_Secret
-
int[MAXPLAYERS] Cnt_Frags
-
int[MAXPLAYERS] Cnt_Deaths
-
int Cnt_Time
-
int Cnt_Total_Time
-
int Cnt_Par
-
int Cnt_Pause
-
int Total_Frags
-
int Total_Deaths
-
bool NoAutoStartMap
-
int DoFrags
-
int Ng_State
-
float ShadowAlpha
-
-
-
-
-
-
TO-DO — This section is not finished yet
-
textureId P_Secret
-
The "SECRET" (default
WISCRT2) graphic.
-
textureId Kills
-
The "KILLS" (default
WIOSTK) graphic.
-
textureId Secret
-
The "SCRT" (default
WIOSTS) graphic.
-
textureId Items
-
The "ITEMS" (default
WIOSTI) graphic.
-
textureId TimePic
-
The "TIME" (default
WITIME) graphic.
-
textureId Par
-
The "PAR" (default
WIPAR) graphic.
-
textureId Sucks
-
The "SUCKS" (default
WISUCKS) graphic.
-
textureId FinishedPatch
-
textureId EnteringPatch
-
string[2] LNameTexts
-
string[2] AuthorTexts
-
bool Snl_PointerOn
-
int[MAXPLAYERS] Player_Deaths
-
TO-DO — This section is not finished yet
-
int Sp_State
-
Used in single-player status screens during the
StatusScreen.STATCOUNTstage for indicating the current round of statistics to count up.
-
int CWidth
-
int CHeight
-
int ScaleMode
-
int WrapWidth
-
int ScaleFactorX
-
int ScaleFactorY
-
TO-DO — This section is not finished yet
Overview of instance members
AccelerateStage, Author, AuthorTexts, BCnt, Bg, CHeight, CWidth, Cnt, Cnt_Deaths, Cnt_Frags, Cnt_Items, Cnt_Kills, Cnt_OtherKills, Cnt_Par, Cnt_Pause, Cnt_Secret, Cnt_Time, Cnt_Total_Time, Content, CurState, DoFrags, Entering, EnteringPatch, Finished, FinishedPatch, Items, Kills, LNameTexts, MapName, Me, Ng_State, NoAutoStartMap, OtherKills, P_Secret, Par, PlayerReady, Player_Deaths, Plrs, ScaleFactorX, ScaleFactorY, ScaleMode, Secret, ShadowAlpha, Snl_PointerOn, Sp_State, Sucks, TimePic, Total_Deaths, Total_Frags, Wbs, WrapWidth
Constants
-
const int TITLEY
-
The Y position (in 320x200 pixels) to draw the top of the "finished" and "entering" text. Used by
DrawElandDrawLf.
-
const int SP_STATSX
-
const int SP_STATSY
-
const int SP_TIMEX
-
const int SP_TIMEY
-
const int NG_STATSY
-
const int SHOWNEXTLOCDELAY
-
TO-DO — This section is not finished yet