Event System 2ndrev3

I am currently modifying the base events file of civ to be more in line with the time and area frame of our mod. When I am completed I will know a lot about creating events for the mod and would be willing to code any good suggestions into the mod. If you code them I may be willing to put mediocre suggestions in as well. Particularly if they have what this mod is deficient in, which is events that have prereq techs. All of the tech prereqs from normal civ are no longer valid as are many events.

I have other sinister and grandiose plans some of which I mentioned in the main discussion thread. I will announce them here as soon as I am done the base re-writing of the file and as soon as I actually look at how easy/hard they would be to implement.

No reason to stall creativity though, by all means let the suggestions roll.

Oh yea and if anyone has ideas for what could replace the parrots/sea turtles/prairie dogs/black pearls event text which would sound less ridiculous I'm all ears, cause these event texts have put me completely on the fence. Sometimes I look at them and think "this is not right", but then when I go to change them they have a tendency of making me laugh and distract me from thinking up an alternative.
 
Oh I see what that was for I was wondering what in the hell that was. Yea I'll mod it to either happen 100% or even better only happen on an ideology tag. For instance a anarchist nation taking back a city that only has anarchism as a ideology would not spawn the event.

Those events are meant for just the raw unimproved tiles (eccept the black pearl). I was mostly just thinking what kind of word replacement would not make it sound so hokey and 1800s, it is by no means a big deal or anything anyway since such things could conceivably sell and be harvested.

I had considered doing some interesting improvement events like a eco-tourism destination one which throws up a Forrest preserve on a tile and adds a commerce bonus to the tile. I don't think there is such an event coded yet, but I'm only just over 1/3 the way through so... back to work.
 
do you think we should just plug the event text into the xml or reference it?

The event text is in an XML of it's own. When I'm working on events I have xml/text/CIV4Gametext_events_bts.xml, xml/events/CIV4EventTriggerInfos.xml and xml/events/CIV4EventInfos.xml all open at once. Actually I've taken to keeping the CIV4BuildingInfos.xml open too since there is usually some building related information which is quicker to look up than to waste your time asking about. For instance I changed the forge events to work for factories and the market events to work for banks. That sort of crap. When I'm done with it the event system will be squeaky clean.
 
allrighty, I have some issues that I will need to mention regarding some of the events. I am looking at some of them, particularly specific quests, that need to be considered for discussion. Most of them reference a variable X which is the default # of players for that map size. I do not know what this number is or how to change it, but I've found a guide which convinces me that with a bit of python editing I can and possibly I could set it for a different variable per civ.

1: Harbormaster quest: needs x amount of harbors and y amount of z naval vessles.
In addition to the fact that these harbors are probibly already built (If we add a harbor building) I don't know what the variables X,Y&Z should be.
I am a little concerned that this quest could be imbalanced, easily achieved by one side but not others. So it could be cut if it's too much of a pain in the ass

2: Classic literature: build X "libraries" and control great library for bonus.
Obviously this will need to be changed. I would think it would be good to do with schools or something (schools in all cities = universal education?), it would be good to code it for one for every city min pop 4...

... too be continued when I am less busy.
 
we can just nix the harbormaster. i think there is a lesser reliance on navy in my map.

i like the education type event. we can think through that one.

we also need to get a list for all the unique buildings, and we need to decide if we will have one or two unique buildings per civ

yeah i have been so busy today i havent even got to play a minute of video games or modding. but the soren johnson episode should be out by saturday. :)
 
Oh yea that reminds me, you may consider looking at a multi-layer audio editor for your modcasts. I haven't used one in a while, but I remember a program called acid pro was good for it back in the day. I looked at the one you use and I was dumbfounded as to how you edited effects in and whatnot. The interface seemed like it may be slowing you up. Maybe just my preference though.


Anywhoo. good call on harbormasters.

(Continued)
3: Master Blacksmith: build X forges, bonus for having a religon.
Religion bonus needs to go and forges may need to be an advanced or future factory. Call it super-industrialization or something.

4: Best Deffense: build X castles, bonus for great wall
I like this quest if we go with the advanced logistics building I mentioned in the buildings thread. A logistics wonder may be good too to take the place of the great wall.

5: Sports League: build X Coliseums, bonus for controlling %s2_building (whatever the :):):):) that is)
I think coliseums are stadiums in SR... correct? If so this could be interesting.

These are ones I have flagged for being odd quests and needing to discuss. When I find more I will add them. A few of them need building related discussion. But moreover I would like to look at what should stay/go and what python variables I could/should use for X. If it could possibly be the same variable for every civ/quest it would make things a lot easier for me. However obviously with situations like the school idea there is going to be more than 7 right away. So perhaps changing them to non-initial buildings would be a better idea.
 
remember we are going to implement defense bonus somehow too :) so the castle quest might work. we have to make the building quests around non-unique non-vanilla. so basically any building we add to the game. one of the quests could be written for solar plants, and building a bunch of those :)

you are doing very well, its such a huge undertaking :goodjob:
 
yes the quests are not difficult to write and they are quite similar in their XML programing, but I should add that it is apparent that the additional bonus for controlling the matching wonder needs to be written into python so I will obviously have to look at that in order to make changes with regard to that.

I think the castle one will work with the related suggestions I made in the buildings thread. I'll draw one up for a logistics wonder.

I particularly wanted to know what you thought of the already placed buildings dilemma and the X variable mystery. Is the workingsave map the most current model of the map for SR3.0?
 
yea I've used that a bit, but more for XML value reference than python. I haven't read a lot of it or any of the python section at all. I think I will flag most of the python stuff that needs changing to look at later. Might be worthwhile to look at though. I know some days I open the xmls to start editing and I realize "oh yea, most of this job is rephrasing text into the modern era" and some days, I can barely find the will to get started. Looking at the python for those days may be a good idea.

edit: forget what I said about the wonders. It's in the XML, I just missed it, my bad.
 
BTW partisans only happens when the city is razed.

I think I will double the bonus of the original partisans (for razed) and try to make one along the lines of what we discussed above for captured cities. I will need to do some serious python work though to get this running right, but I think it is important. It was a feature of civ 2 so I may go see if anyone has done it already and I could scavenge their programing.
 
These are a list of missions that I have cut and if you would like them to be re-written in for whatever reason feel free to mention it. Pleas mention a vague premise of what the event is supposed to be at minimum, any changes (you would like)to prereqs/triggers/events and if you really want, entire blurbs for the events (1 for the world events text, 1 for the player events text and 1 for each event).

Spoiler :

City Ruins
Prereq: City Ruins in your control
Result:
1.you get 15% of remaining tech cost for a tech
2.you get 15% of remaining tech cost for a tech AND pay gold (5% of tech cost) for a chance for 3
3.you get +15% of remaining tech cost for a tech

Joyous Wedding
Prereq: You and neighboring AI have the same State Religion
Result:
1.Nothing
2.You pay 15 gold AND gain +1 Attitude with neighboring AI
3.You pay 60 gold AND gain +3 Attitude with neighboring AI

Wedding Feud
Prereq: You and neighboring AI have different State Religion
Result:
1.-1 Attitude with neighboring AI
2.you pay 15 gold AND gain -2 Attitude with neighboring AI AND gain +1 happy face for 30 turns in all your cities with the state religion
3.you pay 60 gold AND gain -2 Attitude with neighboring AI AND gain +1 Attitude with AIs with your state religion, neighboring player is asked if he wants to declare war.

Left at the Altar
Prereq: You share borders with other AI
Result:
1.-1 Attitude with other AI

Great Depression
Prereq: at least 1 founded corporation somewhere
Result:
1.All players lose 25% of their gold
--could just be re-inserted I am not entirely sure why
--I took this one out in the first place, probibly to do
--with the fact that in a civil war it seemed nonsensical

Bermuda Triangle
Prereq: 1 DESTROYER or BATTLESHIP or MISSILE_CRUISER or STEALTH_DESTROYER or SUBMARINE or ATTACK_SUBMARINE or CARRIER or TRANSPORT on Ocean plot AND FLIGHT
Result:
1.Unit is destroyed
-- removed for obvious reasons.

Hindenberg (sic!)
Prereq: 1 Airship anywhere AND RADIO
Result:
1.Nothing
2.pay 45 gold AND gain +1 happy face for every Airport

Solo Flight
Prereq: minimum 8 landmasses (standard size map) AND FLIGHT
Result:
1.+1 Attitude with all AIs you have met

Ancient Olympics
Prereq: POLYTHEISM AND State Religion is NOT Judaism OR Christianity OR Islam
Result:
1.Nothing
2.pay 20 gold AND gain +1 attitude with all neighboring AIs

Modern Olympics
Prereq: SCIENTIFIC_METHOD AND Event77 option 2 has occurred
Result:
1.+1 Attitude with all AIs you have met

Earth Day
Prereq: Environmentalism civic AND INDUSTRIALISM or RADIO
Result:
1.All your cities gain +1 happy face for 10 turns
2.you pay 60 gold AND all cities gain +1 happy face AND some other AIs switch to Environmentalism civic

Ancient Texts
Prereq: Desert tile with NO Flood plains NO Resource NO road NO railroad AND NO improvement AND STEAM_POWER or STEEL or SCIENTIFIC_METHOD or ARTILLERY
Result:
1.You get 15% of remaining tech cost for a tech
2.You pay 200 gold AND gain +1 Attitude with all AIs you have met

*Many events that spawn 4 barbarians*

Thoroughbred
Prereq: City with Stable AND tile with Horse resource AND pasture AND road OR railroad
Obsolete: None
Active/Weight: 90/100
Result:
1.you gain 30 to 70 gold

Chilly Flight
Prereq: City with Airport
Result:
1.City gains +2 gold for its airport

Civ Game
Prereq: COMPUTERS
Result:
1.+1 happy face in all your cities
2.all universities get +3 research
3.you receive gold (320 base)

Great Beast
Prereq: own a plot with camp AND HUNTING and POLYTHEISM and have a State Religion
Result:
1.+1 food on plot
2.pay gold (15 base) AND gain +1 population in a city
3.+1 happy face for 40 turns in all cities with state religion

Rabbi
Prereq: City with Judaism AND Jewish Monastery AND PAPER
Result:
1.Convert 5 own and 3 foreign cities to Judaism
2.pay gold (100 base) AND get 1 free scientist in city
3.+8 culture AND +5 gold from Jewish monastery in that city

Golden Buddha
Prereq: City with Buddhism AND Forge AND own plot with Gold AND Mine AND Road
Result:
1.gain gold (180 to 200)
2.city's forge gains +6 culture
3.pay gold (70 base) AND gain 350 culture in all cities

Preaching Researcher
Prereq: City with Christianity AND Christian Monastery AND University
Result:
1.City's Christian monastery gains +2 culture
2.pay gold (120 base) AND City's Christian Monastery gains +2 culture AND +4 research

Toxcatl
Prereq: Player is Aztec AND City with Sacrificial Altar AND at least 1 unit
Result:
1.+2 angry faces (like whipped)
2.pay gold (65 base) AND unit is immobile for 3 turns

Dissident Priest
Prereq: Player is Egyptian AND City does NOT have the state religion AND is NOT the Capital AND does NOT have the Forbidden Palace NOR Versailles AND has at least 30 culture per turn
Result:
1.+1 angry face (like whipped) in city AND 2 turns of revolt
2.+1 angry face (like whipped) in all cities
3.pay gold (200 base) AND all libraries gain +2 research AND +2 culture

Rogue Station
Prereq: City with Broadcast Tower AND ASSEMBLY_LINE AND Player is Russian AND State Property civic AND contact with another player
Result:
1.lose 150 Espionage points with other player AND lose Broadcast Tower
2.+1 angry face (like whipped) in city
3.+2 angry faces (like whipped) AND factories gain +2 production in all cities


Quests:
Spoiler :

Blessed Sea
Prereq: GALLEY or CARAVEL or GALLEON AND State Religion BUDDHISM or CONFUCIANISM or TAOISM AND Minimum number of Landmasses is 2*default number of players for this map size (12 for standard) AND Maximum number of Landmasses you have cities on is 0.5*default number of players for this map size (3 for standard)
Aim:
Have cities on 1.5*default number of players for this map size (10 for standard) landmasses while never switching State Religion
Result:
1.convert 20 own cities to your state religion
2.gain a temple in every city size 5 or more
3.get on great prophet unit

Holy Mountain
Prereq: State Religion JUDAISM or CHRISTIANITY or ISLAM
Aim:
Build 2*default number of players for this world size temples/monasteries (14 for standard), cathedrals count as 4 temples/monasteries to reveal the holy mountain peak
Settle at the holy mountain peak to control it
Result:
1.+1 happy face in all your cities

Horse Whispering
Prereq: ANIMAL_HUSBANDRY AND Horse resource
Aim:
Build default number of players for this world size stables (7 for standard)
Result:
1.you get default number of players for this world size Horse Archers (6 for standard)
2.All mounted units get the Sentry promotion
3.All stables provide +1 food

Harbormaster
Prereq: COMPASS AND Map has at least 40% water tiles
Aim:
Build default number of players for this world size harbors (7 for standard) AND half that number +1 caravels (4 for standard)
Result:
1.All Naval Units gain the Combat 1 promotion
2.All harbors gain +1 gold
3.All Naval Units gain the Navigation 1 promotion

War Chariots
Prereq: THE_WHEEL AND State Religion
Aim:
Build default number of players for this world size +1 Chariots (8 for standard)
Result:
1.All Chariot units gain the Combat 1 promotion
2.Spread your state religion to 5 own cities

Elite Swords
Prereq: IRON_WORKING AND State Religion
Aim:
Build default number of players for this world size +1 Swordsmen (8 for standard)
Result:
1.All Swordsman units gain the City Raider 1 promotion
2. IF running HEREDITARY RULE: All Melee units gain the Drill 1 promotion

Warships
Prereq: SAILING and METAL_CASTING AND Map has at least 55% water tiles
Aim:
Build default number of players for this world size Triremes (7 for standard)
Result:
1.All Trireme units gain the Combat 1 promotion
2.IF you control the Great Lighthouse all harbors gain +2 commerce

Guns Butter
Prereq: GUNPOWDER
Aim:
Build default number of players for this world size +1 Musketmen (8 for standard)
Result:
1.All Musketman units gain the Pinch promotion
2.IF Vassalage civic gain 400 gold
3.IF you control the Taj Mahal wonder trigger a golden age

Noble Knights
Prereq: GUILDS and HORSEBACK_RIDING
Aim:
Build default number of players for this world size +1 Knights (8 for standard)
Result:
1.All Knight Units gain the Flanking 1 promotion
2.IF Organized Religion civic AND State Religion: spread your state religion to 5 own cities
3.IF you control the Oracle get a free settled great priest in the Oracle city

Overwhelm
Prereq: FLIGHT and INDUSTRIALISM AND Map has at least 55% water tiles
Aim:
Build 4 destroyers, 2 battleships, 3 carriers and 9 fighters
Result:
1.All DESTROYER, BATTLESHIP, CARRIER, FIGHTER and JET_FIGHTER units gain the Combat 1 promotion
2.All harbors gain +5 commerce
3.IF the Manhattan Project has been build pass the Nuke Ban resolution


Here are ones that are in limbo at the moment. Need to be retooled but of what is unsure.

Spoiler :

At the Sword
Prereq: 1 damaged Swordsman
Result:
1.the chosen Swordsman gains 3 XP

Bowyer
Prereq: ARCHERY
Result:
1.All your Archery units gain the Combat 1 promotion

Horseshoe
Prereq: Pastured Horse AND road OR railroad
Result:
1.All your mounted units gain the Flanking I promotion

Axe Haft
Prereq: BRONZE_WORKING
Result:
1.All Axeman units gain the Shock promotion

Tower Shield
Prereq: MINING
Result:
1.All Melee units gain the Cover promotion

Smokeless Powder
Prereq: GUNPOWDER
Result:
1.All Musketman units gain the Pinch promotion

Stronger Fittings
Prereq: MACHINERY
Result:
1.All Crossbowman units gain the Combat 1 promotion

Firing Pins
Prereq: MILITARY_SCIENCE
Result:
1.All Grenadier units gain the Pinch promotion

Rifled Cannon
Prereq: RIFLING and STEEL
Result:
1.All Cannon units gain the Combat 1 promotion

Metal Decks
Prereq: FLIGHT and INDUSTRIALISM
Result:
1.All Carrier units gain the Drill 3 promotion

Halberd
Prereq: ENGINEERING
Result:
1.All Pikeman units gain the Shock promotion

Reinforced Hull
Prereq: METAL_CASTING
Result:
1.All Trireme units gain the Combat 1 promotion

High Warlord
Prereq: City with castle AND NOT Emancipation civic
Result:
1.you gain 100 gold
2.you gain 2 free Pikeman units
3.city gains 1 free settled great general

Experienced Captain
Prereq: City with Drydock AND GALLEY or TRIREME or CARAVEL or GALLEON or PRIVATEER or FRIGATE or SHIP_OF_THE_LINE or IRONCLAD or TRANSPORT DESTROYER or STEALTH_DESTROYER or BATTLESHIP or MISSILE_CRUISER or SUBMARINE or ATTACK_SUBMARINE or CARRIER unit with 7 or more XP
Result:
1.City gains +2 gold for its drydock
2.you pay 250 gold AND city gains Military Academy

Heresy
Prereq: Theocracy civic
Obsolete: None
Active/Weight: 85/200
Result:
1.City gains +1 angry face (like whipped) AND you spread your state religion to 2 own cities
2.you pay 40 gold AND gain 15% of remaining tech cost for a religious tech
3.Nothing

New Dynasty
Prereq: Hereditary Rule civic AND capital AND MACHINERY or FEUDALISM or MUSIC or PHILOSOPHY or CIVIL_SERVICE or THEOLOGY
Result:
1.Capital gains +1 settled great general
2.Capital gains +1 settled great merchant
3.Capital gains +1 settled great priest

Crisis in the Senate
Prereq: Representation civic AND NATIONALISM or PRINTING_PRESS or EDUCATION or GUNPOWDER or ASTRONOMY
Result:
1.gain +2 Espionage points for all barracks
2.gain 400 to 600 gold
3.+1 happy face in all cities

Too Close To Call
Prereq: Universal Suffrage civic AND NATIONALISM or PRINTING_PRESS or EDUCATION or GUNPOWDER or ASTRONOMY
Result:
1.gain +1 gold for all courthouses
2.gain +3 culture for all courthouses

Charismatic
Prereq: Police State civic AND NATIONALISM or PRINTING_PRESS or EDUCATION or GUNPOWDER or ASTRONOMY
Result:
1.All Gun units gain the March promotion
2.+2 happy faces in all cities

Slave Revolt Warning
Prereq: Slavery Civic AND city with at least 4 population
Result:
1.text is displayed warning you of the possibility of a slave revolt while in Slavery civic

Anti-Monarchists
Prereq: Player is French AND Hereditary Rule civic
Result:
1.+3 happy faces from Palace
2.+2 gold from all cathedrals

Impeachment
Prereq: Player is American AND CONSTITUTION AND has a capital
Result:
1.+6 Angry faces (like whipped) AND +1 happy face for 10 turns in all cities (sic!)
2.Courthouse in Capital gains +2 production AND city has 2 turns of revolt


Quests:
Spoiler :

Classic Literature
Prereq: WRITING
Aim:
Build default number of players for this world size libraries (7 for standard)
Result:
1.+2 research in one (triggering) city's library
2.get one ancient era tech
3.IF you control the Great Library wonder gain +1 scientist specialist for this wonder

Master Blacksmith
Prereq: City with Forge
Aim:
Build default number of players for this world size forges (7 for standard) while not loosing the city triggering the quest
Result:
1.1 Copper resource is revealed
2.All Swordsman units gain the Shock promotion
3.IF you have a state religion gain 1 engineer specialist in the triggering city

Best Defense
Prereq: ENGINEERING
Aim:
Build default number of players for this world size castles (7 for standard)
Result:
1.All Melee units gain the City Garrison 1 promotion
2.gain +3 Attitude with all AIs you have met
3.IF you control the Great Wall gain +25 Espionage points for the Great Wall
-- I think this one is pretty much resolved

Sports League
Prereq: CONSTRUCTION
Aim:
Build default number of players for this world size Colosseums (7 for standard)
Result:
1.+1 happy face for every Colosseum
2.+4 culture for every collosseum
3.IF you control the Statue of Zeus wonder trigger a golden age
 
i like the promotion events. we just need to change the base unit and promotion. make the swordsman one instead be any other units.

the bowyer one could be expert commando training and give a unit class commando promotion (Maybe too stong)
 
the list is fully completed.

You will notice that the limbo list for straight events is populated mostly by civic linked events and unit promotion related events. Most of the reasons for this are my complete lack of familiarity with these systems.

The unit ones can be retooled to any unit or any promotion relatively easily. Also with concerns like you mentioned I can reduce the frequency of the event occurring.
 
Top Bottom