Gameoption bug

TC01

Deity
Joined
Jun 28, 2009
Messages
2,216
Location
Irregularly Online
Don't know if you're already aware of this, but I think I found out why the gameoption menu is a little messed up when going through the DLL source files.

CvEnums.h has this code, defining six new gameoptions:

Code:
//Ass: Added by Kael 07/02/2008
	GAMEOPTION_ASSIMILATION,
	GAMEOPTION_FLEXIBLE_DIFFICULTY,
	GAMEOPTION_CHALLENGE_BARBARIAN_WORLD,
	GAMEOPTION_CHALLENGE_CUT_LOSERS,
	GAMEOPTION_CHALLENGE_HIGH_TO_LOW,
	GAMEOPTION_CHALLENGE_INCREASING_DIFFICULTY,
//Ass: End Add

However, in the XML, only five new gameoptions are defined.

Spoiler New Gameoption Infos :
Code:
		<GameOptionInfo>
			<Type>GAMEOPTION_ASSIMILATION</Type>
			<Description>TXT_KEY_GAME_OPTION_ASSIMILATION</Description>
			<Help>TXT_KEY_GAME_OPTION_ASSIMILATION_HELP</Help>
			<bDefault>1</bDefault>
			<bVisible>1</bVisible>
		</GameOptionInfo>
		<GameOptionInfo>
			<Type>GAMEOPTION_FLEXIBLE_DIFFICULTY</Type>
			<Description>TXT_KEY_GAME_OPTION_FLEXIBLE_DIFFICULTY</Description>
			<Help>TXT_KEY_GAME_OPTION_FLEXIBLE_DIFFICULTY_HELP</Help>
			<bDefault>0</bDefault>
			<bVisible>1</bVisible>
		</GameOptionInfo>
		<GameOptionInfo>
			<Type>GAMEOPTION_CHALLENGE_CUT_LOSERS</Type>
			<Description>TXT_KEY_GAME_OPTION_CHALLENGE_CUT_LOSERS</Description>
			<Help>TXT_KEY_GAME_OPTION_CHALLENGE_CUT_LOSERS_HELP</Help>
			<bDefault>0</bDefault>
			<bVisible>1</bVisible>
		</GameOptionInfo>
		<GameOptionInfo>
			<Type>GAMEOPTION_CHALLENGE_HIGH_TO_LOW</Type>
			<Description>TXT_KEY_GAME_OPTION_CHALLENGE_HIGH_TO_LOW</Description>
			<Help>TXT_KEY_GAME_OPTION_CHALLENGE_HIGH_TO_LOW_HELP</Help>
			<bDefault>0</bDefault>
			<bVisible>1</bVisible>
		</GameOptionInfo>
		<GameOptionInfo>
			<Type>GAMEOPTION_CHALLENGE_INCREASING_DIFFICULTY</Type>
			<Description>TXT_KEY_GAME_OPTION_CHALLENGE_INCREASING_DIFFICULTY</Description>
			<Help>TXT_KEY_GAME_OPTION_CHALLENGE_INCREASING_DIFFICULTY_HELP</Help>
			<bDefault>0</bDefault>
			<bVisible>1</bVisible>
		</GameOptionInfo>

If you remove the "GAMEOPTION_CHALLENGE_BARBARIAN_WORLD," from CvEnums.h (and CyEnumInterface.cpp) and compile a new DLL, the other gameoptions below it in the enums listing should work properly and the "ghost" gameoption should go away.

Alternatively, you could add a GAMEOPTION_CHALLENGE_BARBARIAN_WORLD to its proper place and simply set bVisible to 0 to prevent it from showing up. That should work too.
 
Well, thx very much. :) (Couldn't figure out why it got messed up...)

I'll make sure to include it in v. 5.2 or upload a patch. ;)

(Errr... ofcourse we do have a Bug/Error thread stickied...)
 
(Errr... ofcourse we do have a Bug/Error thread stickied...)

Oops.

I was thinking this was the Star Trek forum, where there is no bug/errors thread, and so whenever I report an error I make a new thread for it.
 
Hey! This isn't the Star Trek forum! :lol:

Clearly... it's just I'm so used to posting errors there when I'm working on the DLL of another Final Frontier mod other than my own.

Speaking of that- I've successfully compiled a DLL with both the FF+ and the MOO2Civ code included.
 
Top Bottom