caveman2cosmos / Caveman2Cosmos

The most expansive mod for Civilization IV: Beyond the Sword.
https://forums.civfanatics.com/forums/civ4-caveman-2-cosmos.449
59 stars 46 forks source link

Unused global defines xml #372

Closed MattOttawa closed 4 years ago

MattOttawa commented 4 years ago

I made this list while messing around a while ago. These are not used in dll or python. It may not be 100% accurate.

USE_MULTIPLE_THREADS_PROPERTY_SOLVER ZOOM_CITY_FOR_PRODUCTION_POPUP // Matt: commented out in the places it was used. KILLERRABBIT_SPAWN_MODIFIER BANDIT_SPAWN_MODIFIER SEA_ANIMAL_SPAWN_MODIFIER ANIMAL_SPAWN_MODIFIER NEANDERTHAL_SPAWN_MODIFIER MIN_VERSION SAVE_VERSION MAX_NUM_LANGUAGES // Matt: commented out in the places it was used. MIN_ANIMAL_STARTING_DISTANCE DONT_ESCORT_SUBDUED_LAND_ANIMAL DONT_ESCORT_SUBDUED_SEA_ANIMAL EVENT_MESSAGE_STAGGER_TIME SEAWATER_SEE_THROUGH_CHANGE MAX_WORLD_WONDERS_PER_CITY // Matt: commented out in the places it was used. MAX_TEAM_WONDERS_PER_CITY // Matt: commented out in the places it was used. MAX_NATIONAL_WONDERS_PER_CITY // Matt: commented out in the places it was used. MAX_NATIONAL_WONDERS_PER_CITY_FOR_OCC // Matt: commented out in the places it was used. BONUS_OBSOLETE_VALUE_MODIFIER CAMERA_CITY_TURN CAMERA_CITY_NO_PITCH GREAT_PEOPLE_THRESHOLD_INCREASE_TEAM GREAT_GENERALS_THRESHOLD_INCREASE_TEAM ESCAPE_MODIFIER_PER_TURN CAMERA_MIN_SCROLL_SPEED CAMERA_MAX_SCROLL_SPEED CAMERA_SMALLEST_MAX_DISTANCE CAMERA_NEAR_FAR_PLANE_RATIO CAMERA_FORCE_TO_SMALLEST_MAX_DISTANCE RENDER_AREABORDER_UNDER_FEATURES RENDER_GLOBEVIEW_CLOUDS RENDER_WATER CAMERA_CITY_ZOOM_IN_DISTANCE CAMERA_BATTLE_ZOOM_IN_DISTANCE CAMERA_SHRINE_ZOOM_IN_DISTANCE EFFECT_DEFAULT_SIZE IMPROVEMENT_SCALE BONUS_SCALE AIR_IDLE_HEIGHT AIR_PATROL_RADIUS AIR_PATROL_SPEED AIR_PATROL_HEIGHT AIR_EXECUTE_DISTANCE AIR_EXECUTE_FINISH AIR_DEFEND_DISTANCE AIR_DEFEND_FINISH UNIT_ANIM_PAGE_MAX DEFAULT_ANIM_PAGE_MAX FLAG_OFFSET_X FLAG_OFFSET_Y FLAG_OFFSET2_X FLAG_OFFSET2_Y UNIT_TRAIL_RESOLUTION TURN_LOG_MAX_WIDTH TURN_LOG_MAX_HEIGHT TURN_LOG_MIN_HEIGHT LEADERHEAD_RANDOM SINGLE_UNIT_GFX_EXTRA_SCALE FOW_WAS_VISIBLE_COLOR FOW_MINIMAP_WAS_VISIBLE_COLOR TECH_COST_TOTAL_KNOWN_TEAM_MODIFIER // Matt: commented out in the places it was used. TECH_COST_KNOWN_PREREQ_MODIFIER // Matt: cached in CvGlobals but not used at all. PROJECT_PRODUCTION_PERCENT SM_MISSILE_CARGO_INCREMENT SM_NAVAL_CARGO_INCREMENT ROUTE_Z_BIAS RIVER_Z_BIAS CIVILOPEDIA_SHOW_ACTIVE_CIVS_ONLY USE_MODDERS_PLAYEROPTION_1 USE_MODDERS_PLAYEROPTION_2 USE_MODDERS_PLAYEROPTION_3 MAX_BOMBARD_DEFENSE // Matt: this has a modder game option enum. FORCED_WAR_WAR_WEARINESS_MODIFIER ADVANCED_START_CULTURE_COST_INCREASE BONUS_OBSOLETE_VALUE_MODIFIER DISBANDING_EARNS_GOLD BATTLEFIELD_PROMOTIONS // Matt: this has a modder game option enum. XML_LOGGING_ENABLED // Matt: not sure what i did to this one.

GAMEOPTION_HISTORICAL_WONDERS

Toffer90 commented 4 years ago

Quite a few of them are used by the exe though. e.g. CAMERA_MIN_SCROLL_SPEED CAMERA_MAX_SCROLL_SPEED CAMERA_SMALLEST_MAX_DISTANCE CAMERA_NEAR_FAR_PLANE_RATIO CAMERA_FORCE_TO_SMALLEST_MAX_DISTANCE RENDER_AREABORDER_UNDER_FEATURES RENDER_GLOBEVIEW_CLOUDS RENDER_WATER CAMERA_CITY_ZOOM_IN_DISTANCE CAMERA_BATTLE_ZOOM_IN_DISTANCE CAMERA_SHRINE_ZOOM_IN_DISTANCE FLAG_OFFSET_X FLAG_OFFSET_Y FLAG_OFFSET2_X FLAG_OFFSET2_Y SINGLE_UNIT_GFX_EXTRA_SCALE

These are just some I remember off-hand when glancing over your list. A rule of thumb is that if the global define exist in vanilla then it's probably in use.

Edit: I closed the issue by mistake due to being distracted.

MattOttawa commented 4 years ago

I'm pretty sure some of those you point out are used in CvCameraControl.py in vanilla bts. I'll update.

MattOttawa commented 4 years ago

Nevermind. Can you remember using any of them successfully or are you guessing for those? I know removing USE_FINISH_TEXT_CALLBACK will cause crash. If removing ones used by the exe causes crash, then it would be easy to find out.

Toffer90 commented 4 years ago

I'm pretty sure some of those you point out are used in CvCameraControl.py in vanilla bts. I'll update.

Some of them are, though CvCameraControl isn't used at all in C2C, meaning its code would never be processed when playing C2C.

Toffer90 commented 4 years ago

Can you remember using any of them successfully or are you guessing for those?

I remember confirming most, if not all, of those I listed above as active values which affect the game.

Toffer90 commented 4 years ago

These two are also referenced in the exe ROUTE_Z_BIAS RIVER_Z_BIAS Though I haven't tried tweaking them to see if i could confirm that the exe actually use them for anything.

Edit: Same with this one: UNIT_TRAIL_RESOLUTION Edit: And these: FOW_WAS_VISIBLE_COLOR FOW_MINIMAP_WAS_VISIBLE_COLOR Edit: { These three are also referenced by the exe: ▬ EFFECT_DEFAULT_SIZE ▬ IMPROVEMENT_SCALE ▬ BONUS_SCALE } Edit: EVENT_MESSAGE_STAGGER_TIME, UNIT_ANIM_PAGE_MAX, MIN_VERSION, SAVE_VERSION, LEADERHEAD_RANDOM

MattOttawa commented 4 years ago

USE_MULTIPLE_THREADS_PROPERTY_SOLVER ZOOM_CITY_FOR_PRODUCTION_POPUP // Matt: commented out in the places it was used. KILLERRABBIT_SPAWN_MODIFIER BANDIT_SPAWN_MODIFIER SEA_ANIMAL_SPAWN_MODIFIER ANIMAL_SPAWN_MODIFIER NEANDERTHAL_SPAWN_MODIFIER MIN_VERSION SAVE_VERSION MAX_NUM_LANGUAGES // Matt: commented out in the places it was used. MIN_ANIMAL_STARTING_DISTANCE DONT_ESCORT_SUBDUED_LAND_ANIMAL DONT_ESCORT_SUBDUED_SEA_ANIMAL EVENT_MESSAGE_STAGGER_TIME SEAWATER_SEE_THROUGH_CHANGE MAX_WORLD_WONDERS_PER_CITY // Matt: commented out in the places it was used. MAX_TEAM_WONDERS_PER_CITY // Matt: commented out in the places it was used. MAX_NATIONAL_WONDERS_PER_CITY // Matt: commented out in the places it was used. MAX_NATIONAL_WONDERS_PER_CITY_FOR_OCC // Matt: commented out in the places it was used. BONUS_OBSOLETE_VALUE_MODIFIER GREAT_PEOPLE_THRESHOLD_INCREASE_TEAM GREAT_GENERALS_THRESHOLD_INCREASE_TEAM ESCAPE_MODIFIER_PER_TURN LEADERHEAD_RANDOM FOW_WAS_VISIBLE_COLOR FOW_MINIMAP_WAS_VISIBLE_COLOR TECH_COST_TOTAL_KNOWN_TEAM_MODIFIER // Matt: commented out in the places it was used. TECH_COST_KNOWN_PREREQ_MODIFIER // Matt: cached in CvGlobals but not used at all. PROJECT_PRODUCTION_PERCENT SM_MISSILE_CARGO_INCREMENT SM_NAVAL_CARGO_INCREMENT CIVILOPEDIA_SHOW_ACTIVE_CIVS_ONLY USE_MODDERS_PLAYEROPTION_1 USE_MODDERS_PLAYEROPTION_2 USE_MODDERS_PLAYEROPTION_3 MAX_BOMBARD_DEFENSE // Matt: this has a modder game option enum. FORCED_WAR_WAR_WEARINESS_MODIFIER ADVANCED_START_CULTURE_COST_INCREASE BONUS_OBSOLETE_VALUE_MODIFIER DISBANDING_EARNS_GOLD BATTLEFIELD_PROMOTIONS // Matt: this has a modder game option enum.

GAMEOPTION_HISTORICAL_WONDERS

Thunderbrd commented 4 years ago

Some of those may be used in modules. The killer rabbit, for example, is purely modular. Was python referenced here? Pretty sure the SM Missile and Naval Cargo Increments aren't used now nor needed.