RULES FOR WORLD SCENARIO // ==OBJECTIVES == OBJECTIVE obj_Byzantium1 name = "Save the Byzantium from Ottoman Turks" desc = "You will win once you terminate Ottoman leaders" type = kScenarioObjectiveType_Primary starthidden = 0 targetlocation1x= 286 targetlocation1y= 8 END_OBJECTIVE OBJECTIVE obj_Byzantium2 name = "Free this land from the threat of Bulgarian barbarians" desc = "Wipe out Bulgarian leader to force Bulgaria to capitulate" type = kScenarioObjectiveType_Secondary starthidden = 0 targetlocation1x= 12 targetlocation1y= 289 END_OBJECTIVE OBJECTIVE obj_Byzantium3 name = "Text5" desc = "Text6" type = kScenarioObjectiveType_Lose starthidden = 0 targetunit1 = "tx_Hero" END_OBJECTIVE OBJECTIVE obj_Byzantium4 name = "Text7" desc = "Text8" type = kScenarioObjectiveType_Lose starthidden = 0 targetlocation1x= 118 targetlocation1y= 217 targetlocation2x= 123 targetlocation2y= 221 targetlocation3x= 112 targetlocation3y= 226 END_OBJECTIVE OBJECTIVE obj_Byzantium5 name = "Text9" desc = "Text10" type = kScenarioObjectiveType_Lose starthidden = 0 targetlocation1x= 205 targetlocation1y= 221 targetlocation2x= 211 targetlocation2y= 232 targetlocation3x= 216 targetlocation3y= 245 targetlocation4x= 216 targetlocation4y= 259 targetlocation5x= 220 targetlocation5y= 274 END_OBJECTIVE //== GENERAL SCENARIO INFORMATION == name = "Save Byzantium" brief = "Probably, my last scenario. This one is about changing history.\n\nI’ve always dreamed about scenario this big (not overblown, but fabulous), depicting the Byzantium downfall. A big map, thousands of Turkic warriors and the ancient Constantinople which is ultimately doomed. It could be a great scenario, the final round.\n\nHowever, I’ve changed my mind. Byzantine Empire was so corrupt, weak and despairing that happy end was nearly impossible. Well, here you come. Can the one man change the destiny? Give it a shot." //victory = "You are victorious!" //loss = "You have lost." hints = "- This scenario is all about thoughtful resource management. You’ve got the chain of command, the army and the fleet, production capacities and extensive territories. Manage them right: cherish every man, every boat and every piece of a wall. ACTIVE PAUSE will help\n\n- The amount of strategic resources is small. Also, you can afford little construction, so repair buildings wherever possible\n\n- Defeating Bulgarians is optional, but defeating them quickly is wholesome. Not only you’ll get a strategic advantage of fighting Turks alone, but also discover one more thing...\n\n- Battering rams and trebuchets are number-one priority. Halt the enemies’ advance as far away from Constantinople as possible! (See the terms of surrender)" historicalInfo = "The Byzantine Empire was the continuation of the Roman Empire (after its end in 476 A.D.). Its capital city was Constantinople (formerly Byzantium). It survived the fragmentation and fall of the Western Roman Empire in the 5th century AD and continued to exist for an additional 1 000 years until it fell to the Ottoman Turks in 1453.\n\nDuring most of its existence, the Empire was the most powerful economic, cultural, and military force in Europe. It was also the center of world Christianity with the biggest Christian church of all time – the Hagia Sophia.\n\nHowever, at some point prosperity stalled. The rich land began to attract more and more immigrants, besides the locals became complacent and produced less goods than import. Then corruption quickly emerged, impressive in its scale (for instance, the position of tax collector was officially sold at auction, and the Admiral of the fleet traded sails from his ships). The authorities named \"lack of money\" the biggest problem of the nation, but the real threat were barbarians from the East – the Seljuk Turks, who just ruthlessly captured region after region.\n\nIn the 11th-12th centuries Constantinople had already lost its former greatness. The crisis was also exacerbated by the Teutonic campaigns organized by the Europeans: instead of helping to fight the Turks, the crusaders only plundered the country! The Empire was losing its last shred of grandeur. The capture of Constantinople was inevitable. Europeans have never been able to return these lands, which was a great lesson for everyone." //date = "1000-1400 AD" END_SCENARIO //////////////////////////////////////////////////////////// // DEFINITIONS //////////////////////////////////////////////////////////// DEFINITIONS // OBJECTIVES //PLAYERS constant int BYZANTINE_EMPIRE constant int OTTOMAN_TURKS constant int BULGARIA END_DEFINITIONS //////////////////////////////////////////////////////////// // INITIALIZATION //////////////////////////////////////////////////////////// INITIALIZATION CarveShroudArea(1, "Vision_Area"); CarveShroudArea(1, "Vision_Area2"); CarveShroudArea(1, "Vision_Area3"); PauseCalendar(false); SetCurrentMonth(9); PauseWeatherSystem(false); LockDiplomaticState(1, 2); LockDiplomaticState(1, 3); LockDiplomaticState(2, 1); LockDiplomaticState(2, 3); LockDiplomaticState(3, 1); LockDiplomaticState(3, 2); // CONSTANTS // OBJECTIVES //PLAYERS BYZANTINE_EMPIRE = 1; OTTOMAN_TURKS = 2; BULGARIA = 3; SetMaxEpochUI(6); SetTechEnabled(BYZANTINE_EMPIRE, "Main7", false); SetTechEnabled(OTTOMAN_TURKS, "Main7", false); SetTechEnabled(BULGARIA, "Main6", false); SetTechEnabled(BYZANTINE_EMPIRE, "CityCenter", false); SetTechEnabled(BYZANTINE_EMPIRE, "Wall", false); SetTechEnabled(BYZANTINE_EMPIRE, "Bridge", false); SetTechEnabled(BYZANTINE_EMPIRE, "Fortress", false); SetTechEnabled(BYZANTINE_EMPIRE, "Palisade", false); SetTechEnabled(BYZANTINE_EMPIRE, "Outpost", false); SetTechEnabled(BYZANTINE_EMPIRE, "Barracks", false); SetTechEnabled(BYZANTINE_EMPIRE, "Mill", false); SetTechEnabled(BYZANTINE_EMPIRE, "Stable", false); SetTechEnabled(BYZANTINE_EMPIRE, "Citizen", false); SetTechEnabled(OTTOMAN_TURKS, "House", false); SetTechEnabled(OTTOMAN_TURKS, "Wall", false); SetTechEnabled(OTTOMAN_TURKS, "Bridge", false); SetTechEnabled(OTTOMAN_TURKS, "Fortress", false); SetTechEnabled(OTTOMAN_TURKS, "Palisade", false); SetTechEnabled(OTTOMAN_TURKS, "Outpost", false); SetTechEnabled(OTTOMAN_TURKS, "Barracks", false); SetTechEnabled(OTTOMAN_TURKS, "Mill", false); SetTechEnabled(OTTOMAN_TURKS, "Stable", false); SetTechEnabled(OTTOMAN_TURKS, "Dock", false); SetTechEnabled(OTTOMAN_TURKS, "University", false); SetTechEnabled(BULGARIA, "CityCenter", false); SetTechEnabled(BULGARIA, "House", false); SetTechEnabled(BULGARIA, "Wall", false); SetTechEnabled(BULGARIA, "Bridge", false); SetTechEnabled(BULGARIA, "Fortress", false); SetTechEnabled(BULGARIA, "Palisade", false); SetTechEnabled(BULGARIA, "Outpost", false); SetTechEnabled(BULGARIA, "Barracks", false); SetTechEnabled(BULGARIA, "Mill", false); SetTechEnabled(BULGARIA, "Stable", false); SetTechEnabled(BULGARIA, "Dock", false); SetTechEnabled(BULGARIA, "University", false); GiveAttackBasePreference(2, "Attack1_Area", 10.0); GiveAttackBasePreference(2, "Attack2_Area", 8.0); GiveAttackBasePreference(2, "Attack3_Area", 6.0); GiveAttackBasePreference(2, "East_Constantinople_Area", 4.0); GiveAttackBasePreference(3, "Village_Area", 5.0); GiveAttackBasePreference(3, "West_Constantinople_Area", 5.0); END_INITIALIZATION // //////////////////////////////////////////////////////////// // //RUNS AFTER CINEMATIC, BEFORE OBJECTIVES OPEN // //////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////// // OBJ_BYZANTIUM //////////////////////////////////////////////////////////// RULE Ships ONESHOT if ((GetElapsedGameTime() > 5)) then Ships END_RULE ACTION Ships SCRIPT WORLD PauseCalendar(true); PauseWeatherSystem(true); END_SCRIPT END_ACTION RULE ruleObj_Byzantium1 ONESHOT if (!DoesUnitExist( "tx_Enemy_1" ) ) then KingDeadAction1 END_RULE ACTION KingDeadAction1 SCRIPT WORLD WinScenario(); END_SCRIPT END_ACTION RULE ruleObj_Byzantium2 ONESHOT if (!DoesUnitExist( "tx_Enemy_2" ) ) then KingDeadAction2 END_RULE ACTION KingDeadAction2 SCRIPT WORLD if ((PlayerInGame(3)) &&(!IsPlayerHumanControlled(3))){ SetAIDiplomacyEnabled(3,true); ForceSurrenderOffer(3, 1); SetAIDiplomacyEnabled(3,false); } else { CreateNamedGroup("BULGARIANS"); AddUnitsByTypeToGroup("BULGARIANS", "BareBoneBuilding", 3, kPlayerMode_Self, NULL); AddUnitsByAttributeToGroup("BULGARIANS", "MobileUnits", 3, kPlayerMode_Self, NULL); if(NumUnitsInGroup("BULGARIANS") > 0){ SelectGroupForPlayer("BULGARIANS", 3); KillSelection(); ClearSelection(); } } END_SCRIPT END_ACTION RULE ruleObj_Byzantium3 ONESHOT if (!DoesUnitExist( "tx_Hero" ) ) then EndGameAction1 END_RULE ACTION EndGameAction1 SCRIPT WORLD LoseScenario(); END_SCRIPT END_ACTION RULE ruleObj_Byzantium4 ONESHOT if (!DoesUnitExist( "tx_Hagia_Sophia_1" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium5 ONESHOT if (!DoesUnitExist( "tx_Hagia_Sophia_2" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium6 ONESHOT if (!DoesUnitExist( "tx_Hagia_Sophia_3" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium7 ONESHOT if (!DoesUnitExist( "tx_Wall_1" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium8 ONESHOT if (!DoesUnitExist( "tx_Wall_2" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium9 ONESHOT if (!DoesUnitExist( "tx_Wall_3" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium10 ONESHOT if (!DoesUnitExist( "tx_Wall_4" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium11 ONESHOT if (!DoesUnitExist( "tx_Wall_5" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium12 ONESHOT if (!DoesUnitExist( "tx_Wall_6" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium13 ONESHOT if (!DoesUnitExist( "tx_Wall_7" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium14 ONESHOT if (!DoesUnitExist( "tx_Wall_8" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium15 ONESHOT if (!DoesUnitExist( "tx_Wall_9" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium16 ONESHOT if (!DoesUnitExist( "tx_Wall_10" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium17 ONESHOT if (!DoesUnitExist( "tx_Wall_11" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium18 ONESHOT if (!DoesUnitExist( "tx_Wall_12" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium19 ONESHOT if (!DoesUnitExist( "tx_Wall_13" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium20 ONESHOT if (!DoesUnitExist( "tx_Wall_14" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium21 ONESHOT if (!DoesUnitExist( "tx_Wall_15" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium22 ONESHOT if (!DoesUnitExist( "tx_Wall_16" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium23 ONESHOT if (!DoesUnitExist( "tx_Wall_17" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium24 ONESHOT if (!DoesUnitExist( "tx_Wall_18" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium25 ONESHOT if (!DoesUnitExist( "tx_Wall_19" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium26 ONESHOT if (!DoesUnitExist( "tx_Wall_20" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium27 ONESHOT if (!DoesUnitExist( "tx_Wall_21" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium28 ONESHOT if (!DoesUnitExist( "tx_Wall_22" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium29 ONESHOT if (!DoesUnitExist( "tx_Wall_23" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium30 ONESHOT if (!DoesUnitExist( "tx_Wall_24" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium31 ONESHOT if (!DoesUnitExist( "tx_Wall_25" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium32 ONESHOT if (!DoesUnitExist( "tx_Wall_26" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium33 ONESHOT if (!DoesUnitExist( "tx_Wall_27" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium34 ONESHOT if (!DoesUnitExist( "tx_Wall_28" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium35 ONESHOT if (!DoesUnitExist( "tx_Wall_29" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium36 ONESHOT if (!DoesUnitExist( "tx_Wall_30" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium37 ONESHOT if (!DoesUnitExist( "tx_Wall_31" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium38 ONESHOT if (!DoesUnitExist( "tx_Wall_32" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium39 ONESHOT if (!DoesUnitExist( "tx_Wall_33" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium40 ONESHOT if (!DoesUnitExist( "tx_Wall_34" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium41 ONESHOT if (!DoesUnitExist( "tx_Wall_35" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium42 ONESHOT if (!DoesUnitExist( "tx_Wall_36" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium43 ONESHOT if (!DoesUnitExist( "tx_Wall_37" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium44 ONESHOT if (!DoesUnitExist( "tx_Wall_38" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium45 ONESHOT if (!DoesUnitExist( "tx_Wall_39" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium46 ONESHOT if (!DoesUnitExist( "tx_Wall_40" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium47 ONESHOT if (!DoesUnitExist( "tx_Wall_41" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium48 ONESHOT if (!DoesUnitExist( "tx_Wall_42" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium49 ONESHOT if (!DoesUnitExist( "tx_Wall_43" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium50 ONESHOT if (!DoesUnitExist( "tx_Wall_44" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium51 ONESHOT if (!DoesUnitExist( "tx_Wall_45" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium52 ONESHOT if (!DoesUnitExist( "tx_Wall_46" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium53 ONESHOT if (!DoesUnitExist( "tx_Wall_47" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium54 ONESHOT if (!DoesUnitExist( "tx_Wall_48" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium55 ONESHOT if (!DoesUnitExist( "tx_Wall_49" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium56 ONESHOT if (!DoesUnitExist( "tx_Wall_50" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium57 ONESHOT if (!DoesUnitExist( "tx_Wall_51" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium58 ONESHOT if (!DoesUnitExist( "tx_Wall_52" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium59 ONESHOT if (!DoesUnitExist( "tx_Wall_53" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium60 ONESHOT if (!DoesUnitExist( "tx_Wall_54" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium61 ONESHOT if (!DoesUnitExist( "tx_Wall_55" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium62 ONESHOT if (!DoesUnitExist( "tx_Wall_56" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium63 ONESHOT if (!DoesUnitExist( "tx_Wall_57" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium64 ONESHOT if (!DoesUnitExist( "tx_Wall_58" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium65 ONESHOT if (!DoesUnitExist( "tx_Wall_59" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium66 ONESHOT if (!DoesUnitExist( "tx_Wall_60" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium67 ONESHOT if (!DoesUnitExist( "tx_Wall_61" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium68 ONESHOT if (!DoesUnitExist( "tx_Wall_62" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium69 ONESHOT if (!DoesUnitExist( "tx_Wall_63" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium70 ONESHOT if (!DoesUnitExist( "tx_Wall_64" ) ) then EndGameAction1 END_RULE RULE ruleObj_Byzantium71 ONESHOT if (!DoesUnitExist( "tx_Wall_65" ) ) then EndGameAction1 END_RULE