Bravomylife
Chieftain
- Joined
- Jul 2, 2022
- Messages
- 4
I recently tried on UB function that allows extra specialist slot to technology buildings (public school and laboratory 1->2)
What I did was creating a copy of original building with extra slot and used lua to replace the original building into specialized version when created in city.
It worked first of all.
Then the next problem came.
After having my new public school built in my city, the game still displayed original public school on production queue. I had to find a way to disable the original building from displaying after new version made replacement. By making new version building need certain buildingclasses in future era I could stop the new version from displaying so original could only be displayed. Then when I need original version to quit displaying I couldn't find solution. I tried Building_LockedBuildingClasses but didn't work.
There's also another problem. LABORATORY requires public school building class and since the game does not concern my new version as original, it won't unlock laboratory. So I set the new version's building class to public school, hoping to unlock the laboratory but it won't.
Would there be a lua script to disable original building from being displayed when same buildingclass has already been built in the city? And allow next building which requires building class to identify new version's as original's? I believe second problem can be solved if first one gets solved since I think the problem is that new building is identified differently from original so it remains on the list. And because of it, the game might think it's not built yet and so laboratory can't co exist in the same production queue.Only disabling the original after replacing into new one might solve this problem. What do you think about this? Does lua script enabling this exist?
What I did was creating a copy of original building with extra slot and used lua to replace the original building into specialized version when created in city.
It worked first of all.
Then the next problem came.
After having my new public school built in my city, the game still displayed original public school on production queue. I had to find a way to disable the original building from displaying after new version made replacement. By making new version building need certain buildingclasses in future era I could stop the new version from displaying so original could only be displayed. Then when I need original version to quit displaying I couldn't find solution. I tried Building_LockedBuildingClasses but didn't work.
There's also another problem. LABORATORY requires public school building class and since the game does not concern my new version as original, it won't unlock laboratory. So I set the new version's building class to public school, hoping to unlock the laboratory but it won't.
Would there be a lua script to disable original building from being displayed when same buildingclass has already been built in the city? And allow next building which requires building class to identify new version's as original's? I believe second problem can be solved if first one gets solved since I think the problem is that new building is identified differently from original so it remains on the list. And because of it, the game might think it's not built yet and so laboratory can't co exist in the same production queue.Only disabling the original after replacing into new one might solve this problem. What do you think about this? Does lua script enabling this exist?