PDA

View Full Version : City Revolts and "create_building" command



Callicles
12-09-2007, 18:10
When a city revolts to a different faction, I'm not sure that the AI knows to institute a government, and the script doesn't create one unless the AI takes a settlement by force. Is there a way to use the console command "create_building" to add the proper government buildings to AI controlled settlements?

If so, is this how I would do it: create_building "Ankyra" "type2"

Would I need to build the "pacify region" first?

MarcusAureliusAntoninus
12-09-2007, 21:06
I don't think there is an easy way to do so, or else it would have been done already. And you only need to spawn the government, if you spawn the pacification then the government you will have two separate buildings, as the script cannot spawn a building over another even if it is in the same building tier.

Callicles
12-09-2007, 21:42
The console doesn't recognize the "create_building" command. I guess you were right. It doesn't work.

mrtwisties
12-10-2007, 05:26
Some console commands only work through a script, and I'm pretty sure create_building is one of them. There's a generic script file in scripts/show_me which is pretty useful for running incidental stuff like this (or for testing new code). If you open up the file and put the console command in, you might have more success. Depends on whether the syntax for the command is correct, and I've got no idea about that.

IIRC you run the generic script by hitting "F1", clicking the help button on the scroll and then clicking on "show me".

Callicles
12-10-2007, 17:53
Can you explain further if you know? If there is a way to manually create the government structure for the AI, no matter how much work is required, I'll do it.

mrtwisties
12-11-2007, 13:48
Sorry, I'm not sure if I can help much more. I haven't done any modding relating to buildings and cities.

Decimus Attius Arbiter
12-11-2007, 20:20
Same happens if you give a city over. It does build governments but extremely rarely. In .81, the Aedui did, but they built the wrong Arverni one in Narbo.

Callicles
12-11-2007, 21:11
Hypothetically, if a settlement could not construct any buildings unless it had a government in place, the AI would then always build a government first because it would be the only option.

Have I missed something?

Decimus Attius Arbiter
12-11-2007, 21:25
My guess, but I think that the AI only does it when it's adjacent to the player or maybe in a war adjacent to someone else. It should build everywhere for its economy.

konny
12-12-2007, 01:04
Hypothetically, if a settlement could not construct any buildings unless it had a government in place, the AI would then always build a government first because it would be the only option.

The other option would be to don't build anything in that town.