There is no spoon
Difference between revisions of "Legacy:HUD (UT)"
From Unreal Wiki, The Unreal Engine Documentation Site
m |
m |
||
(One intermediate revision by one other user not shown) | |||
Line 1: | Line 1: | ||
− | {{classbox| | + | {{classbox| [[Legacy:Actor|Actor]] >> HUD}} |
The superclass for all heads-up display classes. | The superclass for all heads-up display classes. | ||
Line 6: | Line 6: | ||
===Variables === | ===Variables === | ||
− | ; | + | ; HudMode : |
− | ; | + | ; Crosshair : The number of the currently selected crosshair. <i>(?)</i> |
− | ; | + | ; MainMenuType : A [[Legacy:Menu|Menu]] class. |
− | ; [[Legacy: | + | ; MainMenu : A Menu. <i>(I remember that early versions of Unreal didn't contain the UWindow system. Could this be the menu system used before UWindow? – [[Legacy:Wormbo|Wormbo]])</i> |
− | ; | + | ; HUDConfigWindowType : The name of the class used to configure this HUD. |
− | ; | + | ; WhiteColor : A ''color'' variable containing the color used as "white". (Default is R=0, G=128, B=255 which is a kind of light blue) |
− | ; | + | ; HUDMutator : The first [[Legacy:Mutator|Mutator]] registered as HUD mutator. To go through all HUD mutators use the mutator's NexHUDMutator variable. |
− | ; [[Legacy:PlayerPawn|PlayerPawn]] | + | ; PlayerOwner : The [[Legacy:PlayerPawn|PlayerPawn]] owning this HUD. ([[Legacy:ChallengeHUD|ChallengeHUD]].PawnOwner is the [[Legacy:Pawn (UT)|Pawn (UT)]] the HUD currently displays info for) |
===HUDLocalizedMessage struct === | ===HUDLocalizedMessage struct === | ||
− | ; class< | + | ; class<LocalMessage> Message : The [[Legacy:LocalMessage (UT)|LocalMessage (UT)]] class used to create this message. |
; int Switch : The Switch parameter used in various functions of the LocalMessage. | ; int Switch : The Switch parameter used in various functions of the LocalMessage. | ||
− | ; [[Legacy:PlayerReplicationInfo|PlayerReplicationInfo]] | + | ; PlayerReplicationInfo RelatedPRI : A [[Legacy:PlayerReplicationInfo|PlayerReplicationInfo]]. <i>(Whose is it?)</i> |
− | ; | + | ; Object OptionalObject : The Optional[[Legacy:Object|Object]] parameter used in various functions of the LocalMessage. |
; float EndOfLife : | ; float EndOfLife : | ||
; float LifeTime : | ; float LifeTime : | ||
Line 31: | Line 31: | ||
==Functions == | ==Functions == | ||
− | ; function ClearMessage (out HUDLocalizedMessage M) : Resets the HUDLocalizedMessage M. | + | ; function ClearMessage(out HUDLocalizedMessage M) : Resets the HUDLocalizedMessage M. |
− | ; function CopyMessage (out HUDLocalizedMessage M1, HUDLocalizedMessage M2) : Copies the values of M2 into M1. | + | ; function CopyMessage(out HUDLocalizedMessage M1, HUDLocalizedMessage M2) : Copies the values of M2 into M1. |
− | ; simulated event PreRender ( | + | ; simulated event PreRender(canvas Canvas) : Called before world geometry is drawn. |
− | ; simulated event PostRender ( | + | ; simulated event PostRender(canvas Canvas) : Called after world geometry is drawn and fog is applied. This contains the main HUD rendering functionality. |
− | ; simulated function InputNumber (byte F) : ??? | + | ; simulated function InputNumber(byte F) : ??? |
− | ; simulated function ChangeHud (int d) : Probably used to select a HUD type as saved in the HudMode variable. (???) | + | ; simulated function ChangeHud(int d) : Probably used to select a HUD type as saved in the HudMode variable. (???) |
− | ; simulated function ChangeCrosshair (int d) : Changes the crosshair. | + | ; simulated function ChangeCrosshair(int d) : Changes the crosshair. |
− | ; simulated function DrawCrossHair ( | + | ; simulated function DrawCrossHair( canvas Canvas, int StartX, int StartY) : Draws the crosshair. |
− | ; simulated function Message ( | + | ; simulated function Message(PlayerReplicationInfo PRI, coerce string Msg, name N) : Called when receiving a new string message. (e.g. a kill with damage type 'SpecialDamage') |
− | ; simulated function LocalizedMessage (class< | + | ; simulated function LocalizedMessage(class<LocalMessage> Message, optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2, optional Object OptionalObject, optional string CriticalString) : Called when receiving a new LocalMessage. (e.g. flag capture, any kill in UT, etc...) |
− | ; simulated function PlayReceivedMessage (string S, string PName, | + | ; simulated function PlayReceivedMessage(string S, string PName, ZoneInfo PZone) : |
− | ; simulated function bool DisplayMessages ( | + | ; simulated function bool DisplayMessages(canvas Canvas) : DisplayMessages is called by the Console in PostRender. It offers the HUD a chance to deal with messages instead of the Console. Returns true if messages were dealt with. |
− | ; function bool ProcessKeyEvent (int Key, int Action, float Delta) : | + | ; function bool ProcessKeyEvent(int Key, int Action, float Delta) : |
==Known subclasses == | ==Known subclasses == | ||
* [[Legacy:ChallengeHUD|ChallengeHUD]] | * [[Legacy:ChallengeHUD|ChallengeHUD]] | ||
* [[Legacy:UnrealHUD|UnrealHUD]] | * [[Legacy:UnrealHUD|UnrealHUD]] | ||
− | |||
− |
Revision as of 07:16, 12 April 2002
Actor >> HUD
The superclass for all heads-up display classes.
Properties
Variables
- HudMode
- Crosshair
- The number of the currently selected crosshair. (?)
- MainMenuType
- A Menu class.
- MainMenu
- A Menu. (I remember that early versions of Unreal didn't contain the UWindow system. Could this be the menu system used before UWindow? – Wormbo)
- HUDConfigWindowType
- The name of the class used to configure this HUD.
- WhiteColor
- A color variable containing the color used as "white". (Default is R=0, G=128, B=255 which is a kind of light blue)
- HUDMutator
- The first Mutator registered as HUD mutator. To go through all HUD mutators use the mutator's NexHUDMutator variable.
- PlayerOwner
- The PlayerPawn owning this HUD. (ChallengeHUD.PawnOwner is the Pawn (UT) the HUD currently displays info for)
HUDLocalizedMessage struct
- class<LocalMessage> Message
- The LocalMessage (UT) class used to create this message.
- int Switch
- The Switch parameter used in various functions of the LocalMessage.
- PlayerReplicationInfo RelatedPRI
- A PlayerReplicationInfo. (Whose is it?)
- Object OptionalObject
- The OptionalObject parameter used in various functions of the LocalMessage.
- float EndOfLife
- float LifeTime
- bool bDrawing
- int numLines
- string StringMessage
- color DrawColor
- The message's text color.
- font StringFont
- The message's font.
- float XL, YL
- float YPos
Functions
- function ClearMessage(out HUDLocalizedMessage M)
- Resets the HUDLocalizedMessage M.
- function CopyMessage(out HUDLocalizedMessage M1, HUDLocalizedMessage M2)
- Copies the values of M2 into M1.
- simulated event PreRender(canvas Canvas)
- Called before world geometry is drawn.
- simulated event PostRender(canvas Canvas)
- Called after world geometry is drawn and fog is applied. This contains the main HUD rendering functionality.
- simulated function InputNumber(byte F)
- ???
- simulated function ChangeHud(int d)
- Probably used to select a HUD type as saved in the HudMode variable. (???)
- simulated function ChangeCrosshair(int d)
- Changes the crosshair.
- simulated function DrawCrossHair( canvas Canvas, int StartX, int StartY)
- Draws the crosshair.
- simulated function Message(PlayerReplicationInfo PRI, coerce string Msg, name N)
- Called when receiving a new string message. (e.g. a kill with damage type 'SpecialDamage')
- simulated function LocalizedMessage(class<LocalMessage> Message, optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2, optional Object OptionalObject, optional string CriticalString)
- Called when receiving a new LocalMessage. (e.g. flag capture, any kill in UT, etc...)
- simulated function PlayReceivedMessage(string S, string PName, ZoneInfo PZone)
- simulated function bool DisplayMessages(canvas Canvas)
- DisplayMessages is called by the Console in PostRender. It offers the HUD a chance to deal with messages instead of the Console. Returns true if messages were dealt with.
- function bool ProcessKeyEvent(int Key, int Action, float Delta)