Worst-case scenario: the UEd Goblin wipes the map and burns down your house.
Legacy:LocalMessage
LocalMessages are abstract classes which contain an array of localized text. They can be used to display messages to players, either individually or globally.
The PlayerController function ReceiveLocalizedMessage() is used to send messages to a specific player by specifying the LocalMessage class and index. This allows the message to be localized on the client side, and saves network bandwidth since the text is not sent. Actors (such as the GameInfo) use one or more LocalMessage classes to send messages. The BroadcastHandler function BroadcastLocalizedMessage() is used to broadcast localized messages to all the players. See Using LocalMessages for more.
Also see LocalMessage (UT).
Contents
Properties[edit]
- bool bComplexString
- Indicates a multicolor string message class. The HUD calls the RenderComplexMessage function to let the message render itself. This only works for string messages like Say, TeamSay or death messages. (bSpecial == False)
- bool bIsSpecial
- If true, don't add to normal queue.
- bool bIsUnique
- If true and special, only one can be in the HUD queue at a time.
- bool bIsPartiallyUnique
- If true and special, only one can be in the HUD queue with the same switch value
- bool bIsConsoleMessage
- If true, put a GetString on the console.
- bool bFadeMessage
- If true, use fade out effect on message.
- bool bBeep
- If true, beep!
- int Lifetime
- Number of seconds to stay in HUD message queue.
- class<LocalMessage> ChildMessage
- In some cases, we need to refer to a child message.
- Color DrawColor
- Default draw color for this message.
- EDrawPivot DrawPivot
- EStackMode StackMode
- Brutal hack! o_O
- float PosX, PosY
- Default screen location.
- int FontSize
- 0: Huge, 1: Big, 2: Small
Enums[edit]
EStackMode[edit]
- SM_None
- SM_Up
- SM_Down
Methods[edit]
All LocalMessage methods are static functions and most of them return a value based on the Switch, zero to two PlayerReplicationInfos and maybe an optional Object, so don't be suprised to see long function declaration lines here. ;)
- RenderComplexMessage (Canvas Canvas, out float XL, out float YL, optional String MessageString, optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2, optional Object OptionalObject)
- string GetRelatedString (optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2, optional Object OptionalObject)
- Returns the display string if for the player mentioned in RelatedPRI_1.
- string GetString (optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2, optional Object OptionalObject)
- Returns the display string for all other players.
- string AssembleString (HUD myHUD, optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional String MessageString)
- ClientReceive (PlayerController P, optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2, optional Object OptionalObject)
- color GetConsoleColor (PlayerReplicationInfo RelatedPRI_1)
- color GetColor (optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2)
- Returns the draw color for the message.
- GetPos (int Switch, out EDrawPivot OutDrawPivot, out EStackMode OutStackMode, out float OutPosX, out float OutPosY)
- Returns a draw position on the canvas for the message.
- int GetFontSize (int Switch, PlayerReplicationInfo RelatedPRI1, PlayerReplicationInfo RelatedPRI2, PlayerReplicationInfo LocalPlayer)
- float GetLifeTime (int Switch)
Known Subclasses[edit]
LocalMessage +- BulldogMessage +- CTFHUDMessage | +- xBombHUDMessage +- ComboMessage +- CriticalEventPlus | +- ActionMessage | | +- ActionMessage_BR | | +- ActionMessage_CTF | | +- ActionMessage_DM | | +- ActionMessage_DOM | | +- ActionMessage_SubTitle | +- CTFMessage | +- FirstBloodMessage | +- KillingSpreeMessage | +- StartupMessage | +- TimerMessage | +- xBombMessage +- FailedConnect +- GameMessage +- MultiKillMessage +- PickupMessagePlus +- PlayerNameMessage +- SpecialKillMessage +- StringMessagePlus | +- SayMessagePlus | +- TeamSayMessagePlus +- xDeathMessage +- xDomMessage +- xKillerMessagePlus +- xVictimMessage
Related Topics[edit]
Discussion[edit]
Guest: (TurkeyFromHell) Hey I'm making this discussion section for one specific question :):
var(Message) EStackMode StackMode; // Brutal hack!
wtf does this comment refer to xD?? I assume there's something fun you could do w/ the var in a mutator but I was introduced to LocalMessage about 10 minutes ago... :)
Wormbo: It probably refers to the way LocalMessages with the same PosY value are handled by HUD code, because that's when StackMode comes into play to prevent the messages from being drawn onto the same location on the HUD. Ideally the HUD would know a more sophisticated way for figuring out how to arrange overlapping LocalMessages, but it doesn't.
Guest:(TurkeyFromHell) LOL