How do I make text appear in the top left? [Solved]

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
SkinnyODST
Lieutenant Colonel
Lieutenant Colonel
Posts: 545
Joined: Mon Jul 04, 2016 10:56 pm
Location: My other account
Contact:

How do I make text appear in the top left? [Solved]

Post by SkinnyODST »

I don`t want to make a campaign mode, I just want to know how I can add text to the top left of the screen at the start of the game, how to time how long it stays there and if I can trigger it to appear when entering a region. (In standard Conquest). The best example of this is the Battles of the Storm mod.
If I can it would make the map so much better. Thanks
Last edited by SkinnyODST on Wed Oct 05, 2016 11:58 pm, edited 1 time in total.
thelegend
Sith
Sith
Posts: 1433
Joined: Thu Jan 23, 2014 6:01 am
Projects :: Star Wars - Battlefront III Legacy
Games I'm Playing :: Swbf GTA CoD LoL KH
xbox live or psn: El_Fabricio#
Location: Right behind you :)

Re: How do I make text appear in the top left?

Post by thelegend »

ShowMessageText("your.localization.path.in.multilanguagetool", ATTorDEF)

You can put this anywhere where you want. When it comes to triggering/or timing just put it there where usual commands are put in.
SkinnyODST
Lieutenant Colonel
Lieutenant Colonel
Posts: 545
Joined: Mon Jul 04, 2016 10:56 pm
Location: My other account
Contact:

Re: How do I make text appear in the top left?

Post by SkinnyODST »

thelegend wrote:ShowMessageText("your.localization.path.in.multilanguagetool", ATTorDEF)

You can put this anywhere where you want. When it comes to triggering/or timing just put it there where usual commands are put in.
Do I make a new path/scope in the localisation tool? If so, where?
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: How do I make text appear in the top left?

Post by Marth8880 »

SkinnyODST wrote:Do I make a new path/scope in the localisation tool? If so, where?
Yes. It technically doesn't matter where as long as the path reference in ShowMessageText correctly points to it, but generally a good place to put these kinds of keys is in "level.ABC" (replacing ABC with your map's ID).
SkinnyODST
Lieutenant Colonel
Lieutenant Colonel
Posts: 545
Joined: Mon Jul 04, 2016 10:56 pm
Location: My other account
Contact:

Re: How do I make text appear in the top left?

Post by SkinnyODST »

Alright well I made a new scope in "level" (my 3 letter map name) and under it a key called "brief". It comes up as (NULL) in game. I named everything right. What am I doing wrong?

My LUA, or at least the section of importance -
Hidden/Spoiler:
[code]function ScriptPostLoad()

ShowMessageText("brief", ATT)[/code]
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: How do I make text appear in the top left?

Post by Marth8880 »

You need to include the key's full path separating each scope with a period, like so:

ShowMessageText("level.ABC.brief", ATT)
SkinnyODST
Lieutenant Colonel
Lieutenant Colonel
Posts: 545
Joined: Mon Jul 04, 2016 10:56 pm
Location: My other account
Contact:

Re: How do I make text appear in the top left?

Post by SkinnyODST »

It worked! Thanks for the help mate :mrgreen:
Post Reply