Adding introduction text

Download scenarios and talk about scenario design.

Moderators: Slitherine Core, BA Moderators

Post Reply
Dita0
Corporal - Strongpoint
Corporal - Strongpoint
Posts: 55
Joined: Sat Jun 26, 2010 12:39 pm

Adding introduction text

Post by Dita0 »

Having looked at the existing campaigns, I`m trying to add similiar "pop up" text on the introctuction screen for the campaign and the scenarios. So far I`ve got this--

IDS_CAMPAIGN_NAME,"Sniper",
IDS_CAMPAIGN_TEXTa,"Somewhere in Normandy...",
IDS_CAMPAIGN_TEXTb,"Trapped and alone...",

However, only the "sniper" part is showing. Any suggestions? I`m sure I`m missing something.

The file for the desert shows this--
IDS_CAMPAIGN_TEXTa,"The Western Desert 1940 - 1943",
IDS_CAMPAIGN_TEXTb,"The battle between the Allies and Axis forces surges back and forth across the harsh desert...",
IDS_CAMPAIGN_TEXTc,"... with neither side able to achieve a decisive victory.",

So I`m not sure what I`ve done.
Thanks for responses.
pipfromslitherine
Site Admin
Site Admin
Posts: 9878
Joined: Wed Mar 23, 2005 10:35 pm

Post by pipfromslitherine »

You need to use a custom scenario UI file. You can use one of the ones from the desert or DDay and just tweak the strings (which seems to be what you want to do). To do this:

- open the folder CAMPAIGNS\2Normandy\DATA\UI and copy the SCENUI_DDAY.TXT file into the DATA\UI directory inside your custom campaign
- open your copy of the SCENUI_DDAY.TXT file. You'll see the UI script which shows the animated mission description.
- find the lines which are of the form

string IDS_Scenario_desc_DDay_* where * is a, b, c, etc. Change the IDS_ entries to be the strings you want to show.

- save the file and exit. Now rename the file to be SCENUI_name.txt where name is the name of your scenario.

You should now see your text displayed in the same animated way.

If you want to have an animated campaign description, you do the same thing, except copy over the CAMPAIGN_OVERLAY.TXT file, and don't rename it.

Hope I have explained that clearly enough!

Cheers

Pip
Dita0
Corporal - Strongpoint
Corporal - Strongpoint
Posts: 55
Joined: Sat Jun 26, 2010 12:39 pm

Post by Dita0 »

Hmm, I`m sure your explanation is fine, however, I`m seeing no text now. I`ve got this---

IDS_SCENARIO_DESC_Sniper1,"some text here",
IDS_SCENARIO_DESC_Sniper1_a,"some text here",
IDS_SCENARIO_DESC_Sniper1_b,"some text here
IDS_SCENARIO_DESC_Sniper1_c,"...some text here !",

In the text1 file, and this--

[Ddaytextb_back]
type image
x 285
y 240
width 1
height 1
file back_shadow.dds
//Rescale

[DDaytextb]
type text
x 290
y 245
width 290
height 55
string IDS_Scenario_desc_sniper1_b
textleft 297
textwidth 280
texttop 250
colour ff000000
font TooltipFont
file text_window.dds
Rescale
windowedback 10
parent DDaytextb_back

In the SCENUI_sniper1 file. I`ve got more text than this, just abbreviating it! I`ve only changed the IDS_scenario_desc_sniper1_b (previously refering to normandy2) Should I be changing the [ddaytextb] as well?
pipfromslitherine
Site Admin
Site Admin
Posts: 9878
Joined: Wed Mar 23, 2005 10:35 pm

Post by pipfromslitherine »

Are you seeing boxes pop up? Is the screen playing its animation?

If you can't work out what is going on, then upload the campaign somewhere and I will grab it and take a look.

Cheers

Pip
Dita0
Corporal - Strongpoint
Corporal - Strongpoint
Posts: 55
Joined: Sat Jun 26, 2010 12:39 pm

Post by Dita0 »

Thanks. No pop up boxes. If I play around a bit (can`t remember what exactly) I do get some pop up boxes with some of the text in.

I`ll play around a bit more.
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Post by junk2drive »

If I don't do the above, I get my DESC in the first selection screen but I don't get a briefing screen.

If I do the above, my DESC does not appear and I still don't get a briefing screen.

I want to take an overhead screenshot of the map, display it as a briefing, with additional text.

Just a simple, non animated screen. Pick the campaign, get the battle selection screen with a short description, get the briefing screen with the map pic and more detailed description.

What are the text limits for the desc?
pipfromslitherine
Site Admin
Site Admin
Posts: 9878
Joined: Wed Mar 23, 2005 10:35 pm

Post by pipfromslitherine »

If you want to show a briefing in the same way as the core battles (which is what I think you are saying?) then you need a UI file for it, and to then trigger it at the very start of the mission to show it to the player. You use the SetBriefingScreen and ShowBriefing commands (these hook the UI screen to the 'show briefing' button top left.

I'd recommend looking at (e.g.) the DDay.BSF file and see how the commands are used, and perhaps use one of the UI files as a starting point.

Cheers

Pip
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Post by junk2drive »

I spent the better part of today figuring all this out. Next post will have a helper file.

Image
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Post by junk2drive »

These are the files you need. Look at a stock campaign. I used desert1 files, modified them, saved as... to my folders.
To place the flags, take a screenshot of the working map in game. Open in a paint program and place your cursor where you want the flag to end up. Note the x,y in your paint program. Edit your name_map.txt, the line ANIM move with the x,y.
Files needed for briefing

main folder

text1.txt with
scen_name
scen_desc_name_a
scen_desc_name_b
etc
ids_m1 lots of stuff

----

data\UI folder

campaign_overlay.txt

scenui_name.txt

name_map.txt

----

data\ui\textures

name_briefing.dds

----

scenario folder

name.bsf with setbriefingscreen through showbriefing with map name
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Post by junk2drive »

junk2drive wrote:If I don't do the above, I get my DESC in the first selection screen but I don't get a briefing screen.

If I do the above, my DESC does not appear and I still don't get a briefing screen.

I want to take an overhead screenshot of the map, display it as a briefing, with additional text.

Just a simple, non animated screen. Pick the campaign, get the battle selection screen with a short description, get the briefing screen with the map pic and more detailed description.

What are the text limits for the desc?
Bump for Pip
You can call me junk - and type that with one hand.
pipfromslitherine
Site Admin
Site Admin
Posts: 9878
Joined: Wed Mar 23, 2005 10:35 pm

Post by pipfromslitherine »

Sorry - not sure what you mean? There shouldn't be a limit on the amount of text you can put into a description.

If the box isn't expanding it might be that it's not been made auto-sizing, I will check and see if it's a simple fix that will affect all campaigns.

Cheers

Pip
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Post by junk2drive »

OK I don't know if I have tried to cause a problem since 1.4.1 and the auto sizing.

After BF I will see if I can break something.
You can call me junk - and type that with one hand.
Post Reply

Return to “Battle Academy : Scenario Design”