New Tags for GameOptions Infos

Thunderbrd

C2C War Dog
Joined
Jan 2, 2010
Messages
29,813
Location
Las Vegas
Up to now, we've been able to keep all game options interchangeably compatible with one another. But some of the concepts and discussions regarding plans in the works are suggesting that we will not always be able to maintain this option set harmony.

While the coding can certainly work things out so that incompatibilities are sorted out, however fairly or unfairly it may be, regardless, these incompatibilities will always be a potential source of confusion for players and could be a frustration for us as we try to 'stay inside the box' that other options being present have enforced on us.

I've heard more than one modder lately complaining that one or another option would have to go so that what they'd like to be able to do with another option could be done. This is because the two concepts are flat out incompatible.

So, I've generated a solution. We have some limitations, however, that keep the solution from being perfectly elegant from a modding perspective. But from the player perspective, an added step or two allows us to circumvent our limits and create a 'system' that enables us to establish that some GameOptions are either Incompatible with others, or actually require the use of others as the processes involved in those options are relied upon in the new Option.

How to Set this Up

I've left extensive notes in the GameOptionInfos file that cover everything. I'll put it all forward here though since it helps to be able to read it on the forum.

The first thing to understand is we have two new tags:
  • EnforcesGameOptionOnTypes - Allows you to list off other Game Options as being required to be ON when this option is run and if this option is selected, those specified options WILL be selected by the game engine as it initializes the game if they weren't turned on by the player. (aka: These Options are REQUIRED)
  • EnforcesGameOptionOffTypes - Allows you to list off other Game Options as being required to be OFF when this option is run and if this option is selected, those specified options WILL be turned off by the game engine as it initializes the game if they weren't turned off by the player. (aka: These Options are INCOMPATIBLE)

While the processing in the dll will enforce these conditions just fine, I was not able to affect the actual game option list that we see at game setup. Apparently that's all handled via the exe, including the Help Hover text that comes up when you hover the mousepointer over an option to get more information. Even that is not given to us to be able to manipulate further than the Help text itself.

Had we more control, I would've made selection of the tagged EnforcesGameOptionOnType Option cause those designated options to be turned on and greyed out unless the tagged option were turned off thereafter. And vice versa. But this isn't possible :(

So to make sure that we at least warn the player, in the notes at the beginning of the GameOptionInfos file, I gave us some 'template' messages to add to the required or incompatible options Help texts and the tagged Option's help text.
Code:
<!-- These effects should be indicated strongly in the Help text for the option, and in the Help text(s) for the effected option(s) too.  There's no way to add it automatically since the option help hover is completely handled in the core-->
<!-- Thus use the following line in the text (for english anyhow) at the end of the normal Help string (copy and paste onto the end of the help text after a space and replace the (indicatedOption(s))): -->
<!-- [COLOR_WARNING_TEXT]This Option requires, and thus will force the (indicated game option(s)) to be ON![COLOR_REVERT] -->
<!-- Or: [COLOR_WARNING_TEXT]This Option is incompatible with, and thus will force the (indicated game option(s)) to be OFF![COLOR_REVERT] -->
<!-- and on the enforced option(s): [COLOR_WARNING_TEXT]This Option is required for, and will thus be forced ON if (indicating GameOption) is used![COLOR_REVERT] -->
<!-- and on the enforced off option(s): [COLOR_WARNING_TEXT]This Option is incompatible with, and will thus be forced OFF if (indicating GameOption) is used![COLOR_REVERT] -->
<!-- -->

Anyhow, between the two steps, we can now establish prerequisite options and incompatible options.

Any questions, comments, concerns?
 
Ok, well, DH, if you would be so kind as to provide us with links in the Modder's Documentation to this and the Modder's Guide to Game Option Edits threads.
 
Top Bottom