| General | Hosted Sites | Civ5 | CivRev | Civ4Col | Civ4 | Civ3 | Civ2 | Civ1 | Misc | Marketplace |
![]() |
|
|
Welcome to Civilization Fanatics' Center. You are currently viewing our site as a guest which gives you limited access to our site features. By joining our free community, you will be able to participate in the discussions, search the forum, send private messages, vote in polls, upload your own screenshots to the gallery, and access many other special features. Registration is fast, simple and absolutely free, so sign up today! If you have any problems with the registration process or your account login, please contact support. |
|
|||||||
![]() |
|
|
Thread Tools |
|
|
#1 |
|
Warlord
Join Date: Jan 2012
Posts: 104
|
Free promotion after tech research
I think, this could be an interesting element for mods...
My question: I want the scout to have the promotion sentry after discovering tech optics. How is it possible? Could it be similar to the allow_embarkation element? Do I have to create a lua script or is it possible via xml/sql? My idea (not the best)-> Sentry_promo requires optics_tech ( )Give scout free sentry_promo from gamestart Possible? Thanks for your advice
|
|
|
|
|
|
#2 |
|
Tangaroa
![]() |
I just took a look at the optics entry in Civ5Technologies.xml, and that doesn't use a free promotion tag, instead it uses <AllowsEmbarking>true</AllowsEmbarking> . So I'm not quite sure as to how this could be done, although I have a suspicion it would involve LUA
__________________
"I saw our people spreading throughout the land and across the oceans, expanding our kingdom, discovering new people and great riches in faraway lands" - More Civilizations. Most Recent: Tibet "We built wonderous monuments honouring the gods, which reached up to touch the very fabric of the heavens." - More Wonders. Most Recent: Todai-ji |
|
|
|
|
|
#3 | |
|
Mad Scientist
Join Date: Sep 2005
Location: Los Angeles, CA
Posts: 3,062
|
Quote:
Or you can combine the two approaches: in XML, make a "hidden" national wonder that gives the promotion to all units. When you research a certain tech, the Lua code triggers and an invisible copy of that wonder is placed in your capital. From then on, all units (both the ones you already had and the ones you'll build later) will have that promotion because the wonder will continue to exist. The downside to the wonder method is that if your capital is conquered, the building would be destroyed and you'd have no way to get it back unless you added ANOTHER Lua check. You could also do this with Policies, which'd have the benefit of being "intangible" and unable to be destroyed, but that has a whole slew of other issues. Projects would be ideal, as those are linked to the player (like Policies) and aren't destroyable, but Projects don't have any real effects in XML, so you'd still need Lua to place the promotions, and if you're doing that, then why bother with the Project?
__________________
Once upon a time there was the Ages of Man mod set. Then Firaxis broke it. But thanks to the DLL efforts of the community, the mods shall rise again! |
|
|
|
|
|
|
#4 |
|
Warlord
Join Date: Jan 2012
Posts: 104
|
Hm. So I will have to learn about LUA
That will take a while, because I just started modding and I am already gratified when XML/SQL works ![]() Thank you for your advice, spatzimaus. |
|
|
|
![]() |
| Bookmarks |
|
| Thread Tools | |
|
|