Author Topic: Movies -- Modding the 'pop-up text'  (Read 4274 times)

0 Members and 1 Guest are viewing this topic.

Offline Davyboy

Movies -- Modding the 'pop-up text'
« on: September 15, 2012, 01:37:43 PM »
As the subject 'mysteriously materialized' within another discussion thread and to avoid further threadjacking, which seems to be my forté at AC2, I'll start a separate thread to clarify what I was wittering on about.

Don't forget Dave Pitt!

"Essays on Mind and Money" <-- :P Sounds like somebody copy/pasted from Hive. Same for the treaty/war ones.

Mea culpa. Comes from using Facedit (sic) to kick off a new faction textfile, pasting in the index header from Brian's and editing the results.
Looks like I might have left a few Hivisms behind in the process which I am getting round to correcting.

I didn't know about [square brackets]!

It really was new to me too. But  a few days later, as part of my "clean-up" as noted above, I was trawling through 'script.txt' looking for something related - and found THIS almost at the beginning:--

Quote
; 6) The "{" and "}" characters are used to indicate text which should
;    be displayed in BOLD type. The "[" and "]" characters indicate
;    text which should be displayed in ITALIC type. A {} sequence or
;    a [] sequence can begin and end on different lines.
;
; 7) Lines beginning with "^" begin on new lines.
;
; 8 ) Lines beginning with "^^" are centered.

So, it was there all along, written in 1997 by the Firaxis team.
Interesting note: you can see the results of using [ ] brackets at game setup for the Virgin faction BUT if you look up the faction profile through F1 there's NO italic used, it's all squashed to normal font type.

I'm still getting my head around that oddity, but my current best guess would be that alphacentauri.ini values take senior precedence.

Interesting note #2: the [ ] brackets don't seem to work as advertised within the 'movlist.txt' file. On the other hand, the ^ and ^^ operands DO seem functional. Italic type is possible during projects but it's a different hack and has a few variations. I'll post a separate how-to thread when I've dotted all of the "i"s.

OK then. I've dotted  a few "i"s since then and I'm talking about how to have more fun with your game in this area:--

« Last Edit: September 15, 2012, 01:52:31 PM by Davyboy »

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #1 on: September 15, 2012, 02:23:00 PM »
Now, while that's nice, and we've all seen that thousands of times [and benefited from the project bonus] and know that the printed text is controlled  by this entry in 'movlist.txt' :--

#DREAMTWISTER
Arial, 0, 10,
56, 55, 1, 1,
Arial, 1, 14,
56, 55, 1, 1,
Arial, 1, 14,
56, 55, 1, 1,
160, 150, 320, 180,
10, 4000,

^^[The Dream Twister]
^
^
^^+50% to $LINK<PSI Attack=15>.


Just about everyone has, at some stage, wanted to Mod some aspect or other of SMACX.
Many can be progressed with varying levels of difficulty depending on the individual (I personally find that editing graphics files - well, difficult)
and I'm happy to leave that to the experts. (That'll be YOU BUncle and Kilkakon)
Like a few others, I'd like to mock up a few compatible movies; something next to impossible despite the vast quantities of assistance from EA (zilch) and Firaxis (negligable), although I am still waiting on replies to my enquiries regarding EA TQI encoder prototypes...

In the meantime, for a brief Planetlude, I looked around for a "how-to" edit movie text files and came up empty.
Clearly it's too trivially simple or too tucked away on other sites to find, so I dug around a bit and found a few things out.

In the 'movlist.txt' extract above many things look to have pretty obvious uses.

Q) But are there any other possibilities?
A) More than I expected.

For a start all that command type stuff

Quote
^^+50% to $LINK<PSI Attack=15>.

Just boiled away when it was printed to screen. Except that it was (^^) "centered" , so some commands work and some do not.

Rather than present each alteration to the #DREAMTWISTER control text sequentially, driving everyone into Drone Revolt with the tedium, I'll present the fully altered entry, a screenshot of what it looked like as a result, with a few notes to help.




Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #2 on: September 15, 2012, 03:26:40 PM »
Well, that's what you get when you try to make it obviously different from the default values like this:--

#DREAMTWISTER
Alpha Centauri, 0, 12,
56, 95, 1, 2,
Alpha Centauri, 0, 14,
37, 241, 1, 1,
Alpha Centauri, 5, 20,
95, 56, 1, 1,
160, 150, 320, 180,
20, 22000,

^^[The Dream Twister]
^
^Write something here in 12pt Alpha Centauri (white=56) offset from (red=95) by 1 pixel horizontally
and 2 pixels vertically
^
^But any characters inside {braces} {show up in (salmon=37) offset 1,1 from (yellow=241) at 14pt
as specified by the SECOND font/type specification,
^
^while (square brackets) specify the} THIRD {font/type specification which is already BOLD and is now because of the 5 (bold underlined) [double bold underlined 20pt]}
^
^
^^+50% to $LINK<PSI Attack=15>.

So what's happening here?
As best as I can suss (and I'm always open to correction) it goes like this :--

After the video player embedded within terranx.exe has played the movie, these parameters seem to control how the movlist.txt blurb is printed to screen over the top of the frozen final frame of the movie.
Arial is obviously the default font style to be used and a version has to be present within the OS font directory (in my case,for XPSP3, these reside in "Windows--> Fonts")
Arial also appears three times for each movie with two parameters adjacent and another 4 on the next line.
These are my findings for what these and the remaining parameters control.

First instance.
Arial is the font (duh!)The '0' specifies what typeface to use according to the following table:--

0= Normal
1= Bold (default)
2= Italic
3= Bold Italic
4= Normal underscored
5= Bold underscored
6= Italic underscored
7= Bold italic underscored
8= Normal
9= Bold (again - so, maybe just controlled by one byte or even a nibble?)

10 specifies the font point size for the main text body overlay at the end of the movie.(55 black and 56 white are common)

56 specifies the palette colour of the text as listed in palette.pcx the default Firaxis colour palette.
95 specifies the shadow bground colour of the text -- effectively, the screenprinter prints TWICE to the screen per line.
1 (first one) sets the pt offset between the two previous values HORIZONTALLY.
1 (second one) sets the offset VERTICALLY.

Second Instance.
Specifies how text is presented to the screen if you enclose it in {braces}

Third Instance.
Specifies how text is presented to the screen if enclosed in [square brackets] like the movie title.

Next Line is 160, 150, 320, 180,
As best as I have been able to determine this is what these control:--

160 = Pixel offset HORIZONTALLY from the LEFT of the screen determining where the start of the blurb is printed to.
150 = Pixel offset VERTICALLY from the top of the screen determining where the start of the blurb is positioned.
320 = Number of subsequent pixels printed per line before wrapping.
180 = Number of additional pixel-lines printed vertically.

Next line sets parameters for printing to STDOUT.

80 determines the character printing speed in msec/character
22000 specifies persistence time after the last character is presented (also in msec)

So is any of this "going anywhere"? Well maybe it is

Quote
; 6) The "{" and "}" characters are used to indicate text which should
;    be displayed in BOLD type. The "[" and "]" characters indicate
;    text which should be displayed in ITALIC type. A {} sequence or
;    a [] sequence can begin and end on different lines.
;
; 7) Lines beginning with "^" begin on new lines.
;
; 8 ) Lines beginning with "^^" are centered.

Text in the "movlist.txt" DOES follow rules 7 and 8 for pagination, but [ ] and { } brackets are controlled by separate statement entries for each #MOVIENAME entry => should anyone be so inclined as to tweak the #PROJECTS list at the top of "movlist.txt" to include such exotics as 'theyTranscend', write an entry for it way down in the control text with a pithy entry along the lines of ^^{I played Sid Meier's Alpha Centauri, and all I learnt was how to whistle while I wore this crappy T-shirt} -- and THEN be so preternaturally masochistic as to lose a transcendence race; would have a four second banner to that effect as a reward  - centered - of course.

In the meantime I'm content to settle for this:--

It just seemed time to clarify what the Cloudbase actually does, since that sudden C9 ability can often win you the game. (In Arial or Alpha Centauri font)
« Last Edit: September 15, 2012, 03:32:49 PM by Davyboy »

Offline Kilkakon

  • Likes cute things but is
  • Mostly Harmless
  • *
  • Posts: 1155
  • €695
  • View Inventory
  • Send /Gift
  • It does something (It's free and yet priceless)  
  • Creator of Lost Eden and C&C: Dawn of Tomorrow
  • Scenario Creator Custom Faction Modder AC2 Hall Of Fame AC2 Wiki contributor Downloads Contributor Author of at least one AAR Planet tales writer author of the Lost Eden mod for Alien Crossfire
    • View Profile
    • My website!
    • Awards
Re: Movies -- Modding the 'pop-up text'
« Reply #3 on: September 17, 2012, 07:57:19 AM »
Hey thanks for breaking this down. :) Good to have it all discovered and documented properly!

Although, heh, I like how you left "+50% to PSI Attack" on the end of your Dream Twister example shot haha

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #4 on: September 17, 2012, 09:07:40 AM »
Hey thanks for breaking this down. :) Good to have it all discovered and documented properly!

Although, heh, I like how you left "+50% to PSI Attack" on the end of your Dream Twister example shot haha

Yeah, I was of the opinion that after murdering the rest of the text in livid colour, leaving that bit hanging as an afterthought was a bit comical too  :D

But this is the line written :--
Quote
^^+50% to $LINK<PSI Attack=15>.

Which the Firaxians straight copied from either the help or helpx files seems. All the 'control code' is ignored in the process. A player only sees its effects through the F1 screen, as everyone would expect.

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #5 on: September 21, 2012, 07:27:02 AM »
Slight digression -- I got wondering -- what if you start using these braces and square brackets in game?

Well, just for a start (and a lark) you can do that -- and they do indeed modify text:--

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #6 on: September 21, 2012, 07:31:50 AM »
And that 'green' airgunner is not the green associated with explore-type infrastructure:--

Interestingly, in the base screen it doesn't show as green. (And yes that's a different unit that's had its name modded like the 'Airgunner')
« Last Edit: September 22, 2012, 08:15:44 AM by Davyboy »

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #7 on: September 22, 2012, 08:28:50 AM »
(Later in the game..)

This also shows up in other screens, pop-ups. First an "  [Air Marshall]  " differs in production and mil-intel views:--

Offline Kilkakon

  • Likes cute things but is
  • Mostly Harmless
  • *
  • Posts: 1155
  • €695
  • View Inventory
  • Send /Gift
  • It does something (It's free and yet priceless)  
  • Creator of Lost Eden and C&C: Dawn of Tomorrow
  • Scenario Creator Custom Faction Modder AC2 Hall Of Fame AC2 Wiki contributor Downloads Contributor Author of at least one AAR Planet tales writer author of the Lost Eden mod for Alien Crossfire
    • View Profile
    • My website!
    • Awards
Re: Movies -- Modding the 'pop-up text'
« Reply #8 on: September 22, 2012, 12:56:16 PM »
Fat Man? Hahaha

Nice to know, though. Means that special units can be given special attention in those areas in alphax.txt or whatever.

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #9 on: September 22, 2012, 04:00:29 PM »

Nice to know, though. Means that special units can be given special attention in those areas in alphax.txt or whatever.

That may be possible too, but I haven't gone out on a limb to say as much. The reason being that I did all of these accentuations 'in-game' and specifically avoided modding alphax. Even doing what I did do has some unusual colouring effects in the build queue and on the DW unit design 'conveyor belt'.

It brightens things up.

I tried 'italicising' a basename with { } and that yields a GREEN basename in thin (not italic) capitals.
I tried writing that directly into the faction file -- no effect - probably because the name was already used - or maybe not...

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #10 on: September 23, 2012, 11:19:47 AM »
Finally got the Virgins to an Ascendant vic in 2345 last night - it was late and I let the credits play a little, when I suddenly realized that it was screenprinting in Alpha Centauri font !!

It's the ONLY instance of that font being used in the game since I bunged a copy in the OS's Font folder and tweaked the ini file :--

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #11 on: September 23, 2012, 11:39:55 AM »
..And the 'italic' tweak is carried over from the faction.txt file..
..comes out GREEN as previously noted..
..jury still out deciding what happens during a golden age...

Fat Man? Hahaha

Oh, I do a lot of that, depending on the mood. Would you believe that the fission version sometimes gets labelled with the highly original "Little Boy" handle? Mostly I try to be a bit more creative. In fact it seemed necessary with that Branson / Virgin fac as the gameplay differs quite a bit from what usually passes for typical gameplay

Offline Kilkakon

  • Likes cute things but is
  • Mostly Harmless
  • *
  • Posts: 1155
  • €695
  • View Inventory
  • Send /Gift
  • It does something (It's free and yet priceless)  
  • Creator of Lost Eden and C&C: Dawn of Tomorrow
  • Scenario Creator Custom Faction Modder AC2 Hall Of Fame AC2 Wiki contributor Downloads Contributor Author of at least one AAR Planet tales writer author of the Lost Eden mod for Alien Crossfire
    • View Profile
    • My website!
    • Awards
Re: Movies -- Modding the 'pop-up text'
« Reply #12 on: September 24, 2012, 05:28:23 AM »
Hey, sounds good to me. :D Green text on a normally red faction anybody? Christmas alternating colours? XD

Offline Davyboy

Re: Movies -- Modding the 'pop-up text'
« Reply #13 on: September 24, 2012, 07:16:48 AM »
Hey, sounds good to me. :D Green text on a normally red faction anybody? Christmas alternating colours? XD

There's definitely some weird string manipulation tricks being pulled in this game. Have a look at this shot of a few golden age bases. Only the Megastore has been greened with italics, so does it help or hinder that the appended "(!)" is the only section rendered in white?

If I have an idle moment I'll poke around in concepts and help (for smax) and see if they're copied their too. Most likely the command code lives in the terranx hardcode.

Offline Guv’ner

Re: Movies -- Modding the 'pop-up text'
« Reply #14 on: February 25, 2013, 11:58:42 AM »
Finally got the Virgins to an Ascendant vic in 2345 last night - it was late and I let the credits play a little, when I suddenly realized that it was screenprinting in Alpha Centauri font !!

It's the ONLY instance of that font being used in the game since I bunged a copy in the OS's Font folder and tweaked the ini file :--

It seems that changing the ForceOldVoxelAlgorithm to 0 is unnecessary. The credits display in the Alpha Centauri font as long as it’s installed into Windows fonts, something the installer forgets to do.

Another step added to the install/update process.

 

* User

Welcome, Guest. Please login or register.
Did you miss your activation email?


Login with username, password and session length

Select language:

* Community poll

SMAC v.4 SMAX v.2 (or previous versions)
-=-
24 (7%)
XP Compatibility patch
-=-
9 (2%)
Gog version for Windows
-=-
103 (32%)
Scient (unofficial) patch
-=-
40 (12%)
Kyrub's latest patch
-=-
14 (4%)
Yitzi's latest patch
-=-
89 (28%)
AC for Mac
-=-
3 (0%)
AC for Linux
-=-
6 (1%)
Gog version for Mac
-=-
10 (3%)
No patch
-=-
16 (5%)
Total Members Voted: 314
AC2 Wiki Logo
-click pic for wik-

* Random quote

What do I care for your suffering? Pain, even agony, is no more than information before the senses, data fed to the computer of the mind. The lesson is simple: you have received the information, now act on it. Take control of the input and you shall become master of the output.
~Chairman Sheng-ji Yang 'Essays on Mind and Matter'

* Select your theme

*
Templates: 5: index (default), PortaMx/Mainindex (default), PortaMx/Frames (default), Display (default), GenericControls (default).
Sub templates: 8: init, html_above, body_above, portamx_above, main, portamx_below, body_below, html_below.
Language files: 4: index+Modifications.english (default), TopicRating/.english (default), PortaMx/PortaMx.english (default), OharaYTEmbed.english (default).
Style sheets: 0: .
Files included: 47 - 1280KB. (show)
Queries used: 41.

[Show Queries]