Proper way to remove civilizations?

BlossomPone

Chieftain
Joined
Oct 25, 2014
Messages
23
I am attempting to create a Total Conversion mod for beyond, and I would like to remove the existing sponsors from the game.

Ive created an SQL script to delete all from both Civilizations and Leaders, and it does successfully remove them from the leader selection screen. However, when i attempt to start the game, the client crashes. There doesnt seem to be anything in the lua.log, or anything that I can find in the logs.

Is there a way to remove the existing leaders from the game?
 
Rather than deleting anything, you can update the Civilizations table to flag those civs as unplayable.

e.g.
Code:
<Civilizations> 
   <Update> 
      <Where Type="CIVILIZATION_ARC"/>
      <Set AIPlayable="false" Playable="false"/> 
   </Update>
</Civilizations>
Will remove ARC from the leader selection screen, and prevent either AI or human players from playing as them.
 
Wow, I can't believe i didn't think of that. Worked like a charm!

Would you know if there is such a way to remove anything else? To put this in perspective, I'm going to be nuking the entire tech web, and all buildings, units, virtues, even resources and quests will be removed.

I'm pretty sure the quests are going to be what i run into the most trouble with, considering those are pretty ingrained in the gameplay itself, but... Any more advice would be plenty appreciated :)

EDIT: Also, is it possible to update the database from lua? I've wanted to try to create civilizations and dynamically update things from lua code (sql/xml do have their limits, sadly), but I'm not quite sure how to do it, if possible.

EDIT 2: After fiddling around, I'm trying to apply the idea of finding a way to disable, IF i cannot remove assets from the game. I have successfully removed all technologies from the game, but when removing all buildings, the Transcendental Equasion wonder still remains, for some reason.

Furthermore, I seem to be unable to remove or disable tile improvements. If i remove them, the game crashes whenever a worker unit is created. All of the tile improvements (since the prereqtechs are removed) have been immediately unlocked. Removing them, as i said, crashes the game, and I don't seem to be able to lock them behind a dummy tech either, as adding a technology to the game crashes the game as well...

Does anyone have any ideas?
 
If you don't care about the leftover-stuff in the Civilopedia and compatibility with other mods, then doing something like this is probably the easiest way to create an empty tech"web" and to remove everything from the city view without making the Quest-System and other Lua-related stuff crash:

Code:
<GameData>
	<Technologies>
		<!-- Hide all Technologies by moving them into a ring that isn't visible 
			(unless the player is zoomed out completely and scrolls to the right)-->
		<Update>
			<Set LeafTech="false"
				 GridRadius="12"
				 GridDegrees="0"/>
		</Update>
		
		<!-- Restore Habitation (Needed as the Center-Point - you could also 
			 create a Custom Tech, but as all Civs - especially custom ones - 
			 have Habitation as their Starting Technology this is a lot easier-->
		<Update>
			<Where Type="TECH_HABITATION"/>
			<Set LeafTech="false"
				 GridRadius="0"
				 GridDegrees="0"/>
		</Update>
	</Technologies>

	<!-- Remove all Technology-Connections (so Starting Free Techs from other sources don't give unwanted access to other stuff) -->
	<Technology_Connections>
		<Delete/>
	</Technology_Connections>

	<!-- Make all Buildings unconstructable -->
	<Buildings>
		<Update>
			<Set Cost="-1"
				 PrereqTech="NULL"/>
		</Update>
	</Buildings>

	<!-- These are the Victory Wonders, the Transcendential Equation etc. -->
	<Projects>
		<Update>
			<Set Cost="-1"/>
		</Update>
	</Projects>

	<!-- Make all Units require a Leaf Tech that's not available (so basic units can't be built) -->
	<Units>
		<Update>
			<Set PrereqTech="TECH_SURROGACY"/>
		</Update>
	</Units>
</GameData>
(I haven't actually tested the code, so there may be syntax-errors.)

For the Tile Improvement stuff: Those come in two parts, The Improvement itself and the "Build"-Action (found in Units/CivBEBuilds.xml). If you only delete the Improvement, then the Build has an invalid association, which is probably why it crashes. You shouldn't need to delete Improvements though, just delete the <Unit_Builds> found in CivBEUnits.xml - they are what allows workers to create Improvements, if you remove them, then the Improvement is hidden from everything except for the Civilopedia.
 
You're a godsend, Ryika :) Thank you for your help.

Do you have any idea how to handle removing virtues and and affinity levels? I seem to have done it, but in the logs it spams errors, and when viewing the virtues screen, the DoF does not leave once you've closed the screen, resulting in fuzz simulator 2015

I hate asking for so much help, and i appreciate everyone who has helped so far :) I just havent quite gotten the grasp of how to debug this game yet haha.
 
Rather than deleting anything, you can update the Civilizations table to flag those civs as unplayable.

e.g.
Code:
<Civilizations>
   <Update>
      <Where Type="CIVILIZATION_ARC"/>
      <Set AIPlayable="false" Playable="false"/>
   </Update>
</Civilizations>
Will remove ARC from the leader selection screen, and prevent either AI or human players from playing as them.
Where is the Civilizations table located?
Thank you.
 
sorry to dig this up but does this work with city states?
<Civilizations>
<Update>
<Where Type="CIVILIZATION_ARC"/>
<Set AIPlayable="false" Playable="false"/>
</Update>
</Civilizations>
 
Top Bottom