Question on were to put setting variables

Question on were to put setting variables

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

Post Reply
User avatar
robed
Posts: 56
Joined: 02 Mar 2006, 03:18

Question on were to put setting variables

Post by robed »

Looks like we're not doing "configHandler.GetInt("SomeValue", DEF_VALUE)" in every other part of the code anymore. I'm wondering were I should put new option variables. Should i use say gu->m_bNewOption or place it in another object, like the one being affected? For example, let's say I write code so that people can turn off all (or most) textures and only see the outlined models (grid view, or the likes). We'll say the option is bDisableAllTextures. Should the sky object read configHandler.GetInt("bDisableAllTextures", 0) in it's constructor and likewise with the map, and unit drawing objects? or should I just read that variable once in say the gu object and have sky,unit, and map read the value from the gu object? Any devs wanah comment?
Post Reply

Return to “Engine”