Page 15 of 17 FirstFirst ... 567891011121314151617 LastLast
Results 281 to 300 of 340

Thread: Gameplay options for IMPERIAL DESTROYER

  1. #281

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Quote Originally Posted by Sir_Aggelos_GR View Post
    I liked your changes,and i can suggest some more
    what can you suggest ??

  2. #282

    Default Re: Gameplay options for IMPERIAL DESTROYER

    I love this Mod but there is too many things removed from Vanilla Empire and 90% of the gameplay options that you added doesn't work or links are dead please can you repost all the gameplay options please !!

  3. #283

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Hello, I like your mod and I have a question.

    Your file which adds trade ships give them maintenance like 0. It was intentional or its just a bug?

  4. #284

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Hi there. Got a couple of questions re ID which I asked before. Playing the Late Campaign. 1) Enabled regions + fort building for generals. Where do you put this? I notice when you open this you have a Data file, a campaigns folder, 2 Lord folders each with a scripting lua. So where do they go? 2) When I open the game I have a notice saying I have won by capturing 1 region. The instructions say I have to capture 1 region by a certain date, but if I've already captured 1 region what is the point. There is no suggestion as to how many regions I have to capture 3) Do I have to start a new game after installing these options? Apart from these points this is an excellent mod. Congratulations.

  5. #285

    Default Re: Gameplay options for IMPERIAL DESTROYER

    I had the same problem but I it worked for me after extracting the campaign folder from the downloaded file to the ETW data folder. Hope that helps!

  6. #286

    Default Re: Gameplay options for IMPERIAL DESTROYER

    First of all, great mod; best so far. However I noticed that many are having problems with square formation. True, after several hours testing I have concluded that square formation for Imperial destroyer 6.3 does not work properly. Is the creator still working on this mod? Lordsith

  7. #287
    vanian's Avatar Libertus
    Join Date
    Sep 2006
    Location
    London
    Posts
    75

    Default Re: Gameplay options for IMPERIAL DESTROYER

    What would be good if we could have a version of this mod that all the vanilla campaign aspects but keeps all the enhanced graphics, units and battle tactics.

  8. #288

    Default Re: Gameplay options for IMPERIAL DESTROYER

    vanian
    you're right
    you're rightyou're rightyou're rightyou're right

  9. #289

    Default Re: Gameplay options for IMPERIAL DESTROYER

    As I've said before I really enjoy playing ID but there is one thing which really gets me. REBELLIONS! Let me give you an example. The Maharatas sold me Hyderabad (I'm playing as Great Britain) and now I know why. Rebellion after rebellion. Five at the last count. I now have two full stacks sitting in the territory, the public order stats are 0 for the working classes and +23 for the nobility, and still rebellions. Great Britain the most stable of countries politically in the 17th and 18th centuries. Three revolutions in England! I'm getting so that I don't want to capture any more territories because it'll just be more rebellions. Is there a submod, or any tweaks, which reduce the number of rebellions? I don't mind one or two where people want their freedom but this is way OTT.

  10. #290

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Agree, all of this is possible in Pack Manager, I think... Takes a lot of time though.

  11. #291

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Hereґs my core-pack enabling 4 guns for artillery-units as well as explosive shells and carcass for 4 and 8 inch mortars + ottmortar (although carcass is pretty worthless for them). Tried adding granades to grenadiers (no luck), tried restoring units and building (like steamdock) for ottomans (no luck). Combining this with some stuff from gameplay options (1st page) made it a little closer to the vanilla version + the added stuff. Although many units, abilities (like duels, mines, earthworks etc) and buildings are still missing. https://www.mediafire.com/file/64igm...Core.pack/file
    Cheers.

  12. #292
    Pope Gregorius I's Avatar Ducenarius
    Join Date
    Sep 2007
    Location
    Pennsylvania USA
    Posts
    927

    Default Re: Gameplay options for IMPERIAL DESTROYER

    wow. after reading this list I guess im confised as to why any of these options were removed in the first place. definitely going to try and download a few of these if the links still work
    "Have mercy on me, O God, according to Thy great compassion. Your delight is not in horses, nor Your pleasure in warriors strength..."

  13. #293

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Is it possible to increase the amount of ammo soldiers have? I find it way too low.

  14. #294

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Quote Originally Posted by Robocop0112 View Post
    Hereґs my core-pack enabling 4 guns for artillery-units as well as explosive shells and carcass for 4 and 8 inch mortars + ottmortar (although carcass is pretty worthless for them). Tried adding granades to grenadiers (no luck), tried restoring units and building (like steamdock) for ottomans (no luck). Combining this with some stuff from gameplay options (1st page) made it a little closer to the vanilla version + the added stuff. Although many units, abilities (like duels, mines, earthworks etc) and buildings are still missing. https://www.mediafire.com/file/64igm...Core.pack/file
    Cheers.


    Thanks, although I am very interested, it gives me a CTD when starting the game

  15. #295
    Swaldo_02's Avatar Laetus
    Join Date
    Jul 2017
    Location
    Melbourne, Australia
    Posts
    7

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Quote Originally Posted by Lordsith View Post
    Updated campaign as Jacobite Britain
    -Fixed some bugs
    -Improvements in playing for this faction.
    You need to start a new campaign!
    http://www.mediafire.com/file/a89l0b...te+Britain.rar
    Link is dead and I'd really really like to play as them, anyone able to help?

  16. #296

    Default Re: Gameplay options for IMPERIAL DESTROYER

    I've been playing around with the .lua and managed to have all diplomatic options without one nation ridiculously being everyone's protector.

    Just go to ETW > Data > campaigns > Lord_main and open scripting.lua in notepad, delete everything, paste in the text from below, save and then start a new game.
    Currently on turn 40 and everything looks normal - no Dagestan-tier lord-protector of the planet!

    Code:
    local advice = require "export_advice"local historic_events = require "export_historic_events"
    local scripting = require "EpisodicScripting"
    local camera_pan = 0
    
    
    local function OnAdviceIssued(context)
            -- 0013_Battle_Advice_Missile_Superiority_Thread
        if conditions.AdviceJustDisplayed("-1875830202", context) then
            scripting.HighlightComponent("button_melee", true)
    
    
        -- 0065_Battle_Advice_Outnumbered_By_The_Enemy_Thread
        elseif conditions.AdviceJustDisplayed("-758254518", context) then
            scripting.HighlightComponent("button_withdraw", true)
    
    
        -- 0077_Battle_Advice_Fire_At_Will_Button_Thread 
        elseif conditions.AdviceJustDisplayed("737354545", context) then
            scripting.HighlightComponent("button_fire_at_will", true)
    
    
          --0079_Battle_Advice_Group_Formations_Button_Thread 
        elseif conditions.AdviceJustDisplayed("2029281479", context) then
            scripting.HighlightComponent("button_groupforms", true)
    
    
        --0080_Battle_Advice_Withdraw_Button_Thread 
        elseif conditions.AdviceJustDisplayed("1621609724", context) then
            scripting.HighlightComponent("button_withdraw", true)
    
    
        --0081_Battle_Advice_Cancel_Order_Button_Thread 
        elseif conditions.AdviceJustDisplayed("313094221", context) then
            scripting.HighlightComponent("button_halt", true)
    
    
        --0082_Battle_Advice_Group_Button_Thread
         elseif conditions.AdviceJustDisplayed("-722605174", context) then
            scripting.HighlightComponent("button_group", true)
    
    
        --0083_Battle_Advice_Group_Formations_Button_Thread
         elseif conditions.AdviceJustDisplayed("-537894077", context) then
            scripting.HighlightComponent("button_groupforms", true)
    
    
        --0100_Battle_Advice_Radar_Map_Thread
         elseif conditions.AdviceJustDisplayed("-1755835367", context) then
            scripting.HighlightComponent("radar", true)
    
    
        --0103_Battle_Advice_Melee_Button_Thread
         elseif conditions.AdviceJustDisplayed("1424352004", context) then
            scripting.HighlightComponent("button_melee", true)
    
    
        --0104_Battle_Advice_Run_Button_Thread
         elseif conditions.AdviceJustDisplayed("593395637", context) then
            scripting.HighlightComponent("button_movespeed", true)
    
    
        --0106_Battle_Advice_Killometer_Thread
         elseif conditions.AdviceJustDisplayed("-729505557", context) then
            scripting.HighlightComponent("killometer_clip", true)
    
    
        --0107_Battle_Advice_Bombardment_Thread
         elseif conditions.AdviceJustDisplayed("1738763088", context) then
            scripting.HighlightComponent("button_halt", true)
        
        --0144_Battle_Advice_Defending_Forts_Thread
         elseif conditions.AdviceJustDisplayed("-2693399", context) then
            scripting.HighlightComponent("button_fire_at_will", true)
            
        --0150_Battle_Advice_Target_Their_Weaknesses_Thread
         elseif conditions.AdviceJustDisplayed("1169098043", context) then
            scripting.HighlightComponent("nav_button_broadside_L", true)    
            
        --0157_Battle_Advice_Ship_Ablaze_Thread
         elseif conditions.AdviceJustDisplayed("1950152570", context) then
            scripting.HighlightComponent("button_fire_at_will", true)
    
    
        --0175_Battle_Advice_Wind_Direction_Thread
         elseif conditions.AdviceJustDisplayed("-608013080", context) then
            scripting.HighlightComponent("radar", true)
    
    
        --0181_Battle_Advice_Outgunned_Avoidance_Thread
         elseif conditions.AdviceJustDisplayed("-1459886398", context) then
            scripting.HighlightComponent("nav_button_shot_chain", true)
    
    
        --0182_Battle_Advice_Crossing_The_T_Thread
         elseif conditions.AdviceJustDisplayed("1813634075", context) then
            scripting.HighlightComponent("nav_button_broadside_L", true)
        
        --0185_Battle_Advice_Naval_Round_Shot_Thread
         elseif conditions.AdviceJustDisplayed("-111077650", context) then
            scripting.HighlightComponent("nav_button_shot_standard", true)    
    
    
        --0186_Battle_Advice_Naval_Grape_Shot_Thread
         elseif conditions.AdviceJustDisplayed("-1507140649", context) then
            scripting.HighlightComponent("nav_button_shot_grape", true)    
    
    
    
    
        --0187_Battle_Advice_Naval_Chain_Shot_Thread
         elseif conditions.AdviceJustDisplayed("-1177825588", context) then
            scripting.HighlightComponent("nav_button_shot_chain", true)
    
    
        --0188_Battle_Advice_Naval_Radar_Map_Thread
         elseif conditions.AdviceJustDisplayed("2073993693", context) then
            scripting.HighlightComponent("radar", true)
    
    
        --0189_Battle_Advice_Naval_Manoeuvre_Compass_Thread
         elseif conditions.AdviceJustDisplayed("646906330", context) then
            scripting.HighlightComponent("nav_UC_button_turn_left", true)    
        
        --0190_Battle_Advice_Left_Broadside_Button_Thread
         elseif conditions.AdviceJustDisplayed("-145936557", context) then
            scripting.HighlightComponent("nav_button_broadside_L", true)
    
    
        --0191_Battle_Advice_Right_Broadside_Button_Thread
         elseif conditions.AdviceJustDisplayed("1188422552", context) then
            scripting.HighlightComponent("nav_button_broadside_R", true)
    
    
        --0192_Battle_Advice_Naval_Group_Button_Thread
         elseif conditions.AdviceJustDisplayed("-1944874567", context) then
            scripting.HighlightComponent("button_group", true)
    
    
        --0195_Battle_Advice_Naval_Withdraw_Button_Thread
         elseif conditions.AdviceJustDisplayed("-783991516", context) then
            scripting.HighlightComponent("button_withdraw", true)
    
    
        --0196_Battle_Advice_Naval_Fire_At_Will_Thread
         elseif conditions.AdviceJustDisplayed("-1827006635", context) then
            scripting.HighlightComponent("button_fire_at_will", true)
    
    
        --0197_Battle_Advice_Naval_Boarding_Button_Thread
         elseif conditions.AdviceJustDisplayed("952924146", context) then
            scripting.HighlightComponent("nav_button_board", true)
    
    
        --0198_Battle_Advice_Naval_Formations_Button_Thread
         elseif conditions.AdviceJustDisplayed("1916043659", context) then
            scripting.HighlightComponent("nav_button_groupforms", true)
    
    
        --1029_Campaign_Advice_UI_Government_Panel_Thread
         elseif conditions.AdviceJustDisplayed("-891171119", context) then
            scripting.HighlightComponent("button_public-order lowest", true)
    
    
        --1041_Campaign_Advice_UI_Incoming_Message_Thread
         elseif conditions.AdviceJustDisplayed("1216388585", context) then
            scripting.HighlightComponent("Icon", true)
    
    
        --1051_Campaign_Advice_Army_Promotions_Thread
         elseif conditions.AdviceJustDisplayed("-1061827595", context) then
            scripting.HighlightComponent("army_promote", true)
    
    
        --1052_Campaign_Advice_Navy_Promotions_Thread
         elseif conditions.AdviceJustDisplayed("695400466", context) then
            scripting.HighlightComponent("navy_promote", true)
    
    
        --1064_Campaign_Advice_Slot_Selected_Thread
         elseif conditions.AdviceJustDisplayed("1326115363", context) then
            scripting.HighlightComponent("army_fort", true)
    
    
        --1065_Campaign_Advice_Character_Selected_Thread
         elseif conditions.AdviceJustDisplayed("659772888", context) then
            scripting.HighlightComponent("recruitment_tab", true)
    
    
        --1065_Campaign_Advice_Character_Selected_Thread
         elseif conditions.AdviceJustDisplayed("1372607332", context) then
            scripting.HighlightComponent("army_replenish", true)
    
    
        --1100_Campaign_Advice_Government_Type_Thread
         elseif conditions.AdviceJustDisplayed("-1671835166", context) then
            scripting.HighlightComponent("button_government", true)
    
    
        --1110_Campaign_Advice_Trade_Routes_Thread
         elseif conditions.AdviceJustDisplayed("1242837398", context) then
            scripting.HighlightComponent("button_diplomacy", true)
    
    
        --1115_Campaign_Advice_Victory_Conditions_Thread
         elseif conditions.AdviceJustDisplayed("1049050650", context) then
            scripting.HighlightComponent("button_missions", true)
    
    
        --1116_Campaign_Advice_Prestige_Thread
         elseif conditions.AdviceJustDisplayed("-956562909", context) then
            scripting.HighlightComponent("button_missions", true)
    
    
        --1124_Campaign_Advice_Warning_Bankrupt_Thread
         elseif conditions.AdviceJustDisplayed("295527590", context) then
            scripting.HighlightComponent("button_diplomacy", true)
    
    
        --1127_Campaign_Advice_Warning_Trade_Thread
         elseif conditions.AdviceJustDisplayed("1264671506", context) then
            scripting.HighlightComponent("button_diplomacy", true)
    
    
        --1136_Campaign_Advice_Religious_Unrest_Thread
         elseif conditions.AdviceJustDisplayed("1219045742", context) then
            scripting.HighlightComponent("button_tech", true)
    
    
        --1138_Campaign_Advice_Warning_Population_Thread
         elseif conditions.AdviceJustDisplayed("-1395907252", context) then
            scripting.HighlightComponent("button_tech", true)
    
    
        --1202_Campaign_Advice_UI_Help_Buildings_Thread
         elseif conditions.AdviceJustDisplayed("-174893187", context) then
            scripting.HighlightComponent("build_browser", true)
    
    
        --1030b_Campaign_Advice_UI_Government_Panel_Thread
         elseif conditions.AdviceJustDisplayed("-428335498", context) then
            scripting.HighlightComponent("button_government", true)
    
    
        --1030c_Campaign_Advice_UI_Government_Panel_Thread
         elseif conditions.AdviceJustDisplayed("-250658412", context) then
            scripting.HighlightComponent("button_government", true)
    
    
    
    
    --1001_Campaign_Advice_Britain_Initial_Turns_Thread
    --Britain camera pans = 11, 12, 13, 14, 15
        
        elseif conditions.AdviceJustDisplayed("-324484024", context) and not CampaignUI.IsMultiplayer() then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(18,    {-57.000, 418.000, 0.75},
                                    {-29.000, 362.000, 0.95},
                                    {36.000, 371.000, 0.95},
                                    {98.000, 378.000, 0.85})
            camera_pan = 11
    
    
    
    
    --1002_Campaign_Advice_France_Initial_Turns_Thread
    --France camera pans = 21, 22, 23, 24
        
        elseif conditions.AdviceJustDisplayed("-1886952522", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(49,    {0.000, 332.000, 0.95},
                                    {43.000, 336.000, 0.85},
                                    {70.000, 332.000, 0.95},
                                    {98.000, 363.000, 0.95},
                                    {47.000, 367.000, 0.85},
                                    {70.000, 329.000, 0.85},
                                    {17.000, 332.000, 0.75})
            camera_pan = 21
    
    
    
    
    --1003_Campaign_Advice_Spain_Initial_Turns_Thread
    --Spain camera pans = 31, 32, 33
        elseif conditions.AdviceJustDisplayed("-1109259521", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(17,    {-37.000, 274.000, 0.75},
                                    {-3.000, 295.000, 0.80},
                                    {95.000, 276.000, 0.85},
                                    {157.000, 287.000, 0.75})
                                    --{218.000, 247.000, 0.75})
            camera_pan = 31
            
            
    --1005_Campaign_Advice_Russia_Initial_Turns_Thread
    --Russia camera pans = 41, 42
        
        elseif conditions.AdviceJustDisplayed("-1808331232", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(21,    {279.000, 386.000, 0.80},
                                    {221.000, 387.000, 0.75},
                                    {219.00, 326.000, 0.65},
                                    {147.000, 287.000, 0.75})
            camera_pan = 41
        
        
    --1006_Campaign_Advice_Prussia_Initial_Turns_Thread
    --Prussia camera pans = 51, 52
        
        elseif conditions.AdviceJustDisplayed("962797902", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(25,    {104.000, 366.000, 0.90},
                                    {91.000, 370.000, 0.95},
                                    {82.000, 366.000, 0.95},
                                    {106.00, 352.000, 0.90},
                                    {120.000, 359.000, 0.95},
                                    {137.000, 384.000, 0.95})
                                
            camera_pan = 51
        
        
    --1008_Campaign_Advice_Dutch_Initial_Turns_Thread
    --Dutch camera pans = 61, 62, 63, 64
        
        elseif conditions.AdviceJustDisplayed("-1766231494", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(18,    {35.000, 372.000, 1.00},
                                    {40.000, 354.000, 0.95},
                                    {29.00, 352.000, 0.90},
                                    {22.000, 365.000, 0.95},
                                    {35.000, 371.000, 1.00})
            camera_pan = 61
    
    
    
    
    --1009_Campaign_Advice_Austria_Initial_Turns_Thread
    --Austria camera pans = 71, 72, 73
        
        elseif conditions.AdviceJustDisplayed("-1522516535", context) and not CampaignUI.IsMultiplayer() then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(27,    {116.000, 339.000, 1.00},
                                    {160.000, 310.000, 0.95},
                                    {115.00, 322.000, 0.95},
                                    {132.000, 351.000, 0.95},
                                    {116.000, 339.000, 0.80})
            camera_pan = 71
        
        
        
    --1012_Campaign_Advice_Poland_Initial_Turns_Thread
    --Poland camera pans = 81, 82, 83, 84
        
        elseif conditions.AdviceJustDisplayed("665527234", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(11,    {181.000, 352.000, 0.90},
                                    {131.000, 348.000, 0.85},
                                    {129.000, 375.000, 0.90})
    
    
                                    
            camera_pan = 81    
        
    
    
    --1004_Campaign_Advice_Ottoman_Initial_Turns_Thread
    --Ottoman camera pans = 91, 92, 93, 94
    
    
        elseif conditions.AdviceJustDisplayed("1447626053", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(21,    {171.000, 291.000, 0.75},
                                    {145.000, 335.000, 0.80},
                                    {223.000, 309.000, 0.85},
                                    {125.000, 306.000, 0.80})
                                    
            camera_pan = 91    
    
    
    
    
    --1007_Campaign_Advice_Sweden_Initial_Turns_Thread
    --Sweden camera pans = 101, 102
        
            elseif conditions.AdviceJustDisplayed("-1638244308", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(39,    {110.000, 418.000, 0.75},
                                    {201.000, 418.000, 0.75},
                                    {125.000, 388.000, 0.75},
                                    {21.000, 365.000, 0.75},
                                    {62.000, 310.000, 0.75},
                                    {172.000, 283.000, 0.75})
            
            camera_pan = 101    
    
    
    
    
    --1010a_Campaign_Advice_Maratha_Initial_Turns_Thread
    --Maratha camera pans = 111, 112
    
    
            elseif conditions.AdviceJustDisplayed("1221146494", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(24,    {527.000, 122.000, 0.95},
                                    {549.000, 94.000, 0.85},
                                    {543.000, 181.000, 0.95})
                                    
            camera_pan = 111    
    
    
        
        end
    end
    
    
    
    
    local function OnCameraMoverFinished(context)
    
    
    --1001_Campaign_Advice_Britain_Initial_Turns_Thread
    
    
        if camera_pan == 11 then
            CampaignUI.ScrollCamera(11,    {49.000, 332.000, 0.95},
                                    {8.000, 324.000, 0.95},
                                    {-31.000, 282.000, 0.85})
            camera_pan = 12
            
        elseif camera_pan == 12 then
            CampaignUI.ScrollCamera(15,    {-515.000, 121.000, 0.85},
                                    {-580.000, 204.000, 0.75},
                                    {-548.000, 274.000, 0.75},
                                    {-504.000, 311.000, 0.75})
            camera_pan = 13
        
        elseif camera_pan == 13 then
            CampaignUI.ScrollCamera(29,    {523.000, 55.000, 0.65},
                                    {599.000, 135.000, 0.75},
                                    {554.000, 186.000, 0.85},
                                    {504.000, 163.000, 0.85},
                                    {528.000, 114.000, 0.85},
                                    {563.000, 80.000, 0.75},
                                    {532.000, 167.000, 0.65})
            camera_pan = 14
            
        elseif camera_pan == 14 then
            CampaignUI.ScrollCamera(8,    {18.000, 342.000, 0.95},
                                    {6.000, 356.000, 0.95},
                                    {0.000, 362.000, 0.75})
            camera_pan = 15
            
        elseif camera_pan == 15 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(0.000, 362.000)
            camera_pan = 0
    
    
    
    
    --1002_Campaign_Advice_France_Initial_Turns_Thread
    
    
        elseif camera_pan == 21 then
            CampaignUI.ScrollCamera(18,    {-454.000, 349.000, 0.75},
                                    {-514.000, 325.000, 0.80},
                                    {-579.000, 249.000, 0.80},
                                    {-586.000, 179.000, 0.75})
            camera_pan = 22
            
        elseif camera_pan == 22 then
            CampaignUI.ScrollCamera(18,    {490.000, 169.000, 0.75},
                                    {577.000, 72.000, 0.80},
                                    {534.000, 35.000, 0.75},                                
                                    {528.000, 113.000, 0.75})
            camera_pan = 23
    
    
        elseif camera_pan == 23 then
            CampaignUI.ScrollCamera(20,    {-391.000, 177.000, 0.95},
                                    {-432.000, 167.000, 0.95},
                                    {-453.000, 126.000, 0.95},
                                    {-434.000, 96.000, 0.95},
                                    {-467.000, 83.000, 0.90},
                                    {-486.000, 108.000, 0.85},
                                    {-519.000, 137.000, 0.80},
                                    {-581.000, 165.000, 0.75})
            camera_pan = 24
            
        elseif camera_pan == 24 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(17.387, 332.769)
            camera_pan = 0
    
    
    
    
    --1003_Campaign_Advice_Spain_Initial_Turns_Thread
    
    
        elseif camera_pan == 31 then
            CampaignUI.ScrollCamera(18,    {30.000, 375.000, 0.95},
                                    {39.000, 353.000, 0.90},
                                    {0.000, 349.000, 0.85})
            camera_pan = 32
    
    
        elseif camera_pan == 32 then
            CampaignUI.ScrollCamera(27,    {-492.000, 194.000, 0.95},
                                    {-562.000, 168.000, 0.80},
                                    {-500.000, 84.000, 0.70},
                                    {-541.000, 161.000, 0.50})
            camera_pan = 33
    
    
        elseif camera_pan == 33 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(-26.750, 280.811)
            camera_pan = 0
    
    
    
    
    --1005_Campaign_Advice_Russia_Initial_Turns_Thread
        
            elseif camera_pan == 41 then
            CampaignUI.ScrollCamera(34,    {147.000, 376.000, 0.90},
                                    {116.000, 338.000, 0.80},
                                    {73.000, 322.000, 0.75},
                                    {48.000,328.000, 0.75},
                                    {8.000, 351.000, 0.75},
                                    {42.000, 386.000, 0.75},
                                    {93.000, 368.000, 0.80},
                                    {150.000, 360.000, 0.90},
                                    {190.000, 418.000, 0.60})
            camera_pan = 42
        
        elseif camera_pan == 42 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(267.000, 391.000)
            camera_pan = 0
        
    --1006_Campaign_Advice_Prussia_Initial_Turns_Thread
    
    
            camera_pan = 51
    
    
            elseif camera_pan == 51 then
            CampaignUI.ScrollCamera(23,    {140.000, 437.000, 0.75},
                                    {64.000, 397.000, 0.75},
                                    {22.000, 347.000, 0.85},
                                    {100.000, 335.000, 0.95},
                                    {95.000, 368.000, 0.80})
            camera_pan = 52
    
    
        elseif camera_pan == 52 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(95.000, 368.000)
            camera_pan = 0
        
    --1008_Campaign_Advice_Dutch_Initial_Turns_Thread
    
    
        elseif camera_pan == 61 then
            CampaignUI.ScrollCamera(14,    {-35.000, 431.000, 0.95},
                                    {5.000, 352.000, 0.85},
                                    {95.000, 369.000, 0.95})
            camera_pan = 62
            
        elseif camera_pan == 62 then
            CampaignUI.ScrollCamera(8,    {-489.000, 85.000, 0.95},
                                    {-490.000, 81.000, 0.80})
            camera_pan = 63
            
        elseif camera_pan == 63 then
            CampaignUI.ScrollCamera(8,    {851.000, -62.000, 0.95},
                                    {878.000, -69.000, 0.95})
            camera_pan = 64
            
        elseif camera_pan == 64 then
            CampaignUI.ScrollCamera(8,    {562.000, 58.000, 0.75},
                                    {570.000, 56.000, 0.90})
            camera_pan = 65
            
        elseif camera_pan == 65 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(35.000, 371.000)
            camera_pan = 0
            
    
    
    --1009_Campaign_Advice_Austria_Initial_Turns_Thread
    
    
        elseif camera_pan == 71 then
            CampaignUI.ScrollCamera(22,    {31.000, 377.000, 0.80},
                                    {68.000, 361.000, 0.90},
                                    {106.000, 368.000, 0.95},
                                    {135.000, 329.000, 0.80})
            camera_pan = 72
            
        elseif camera_pan == 72 then
            CampaignUI.ScrollCamera(24,    {204.000, 428.000, 0.80},
                                    {128.000, 365.000, 0.90},
                                    {172.000, 356.000, 0.90},
                                    {255.000, 380.000, 0.75})
            camera_pan = 73
            
        elseif camera_pan == 73 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(116.000, 339.000)
            camera_pan = 0
        
        
    --1012_Campaign_Advice_Poland_Initial_Turns_Thread
                                
        elseif camera_pan == 81 then
            CampaignUI.ScrollCamera(29,    {191.000, 413.000, 0.75},
                                    {220.000, 368.000, 0.75},
                                    {139.000, 324.000, 0.85},
                                    {144.000, 341.000, 0.85},
                                    {195.000, 379.000, 0.90})
            camera_pan = 82
            
        elseif camera_pan == 82 then
            CampaignUI.ScrollCamera(23,    {202.000, 290.000, 0.90},
                                    {182.000, 280.000, 0.90},
                                    {153.000, 329.000, 0.85},
                                    {284.000, 297.000, 0.75})
            camera_pan = 83
            
        elseif camera_pan == 83 then
            CampaignUI.ScrollCamera(13,    {-42.000, 278.000, 0.80},
                                    {8.000, 352.000, 0.75})
            camera_pan = 84
            
        elseif camera_pan == 84 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(150.000, 367.000)
            camera_pan = 0
            
    
    
    --1004_Campaign_Advice_Ottoman_Initial_Turns_Thread
    
    
        elseif camera_pan == 91 then
            CampaignUI.ScrollCamera(14,    {370.000, 231.000, 0.90},
                                    {315.000, 231.000, 0.90},
                                    {315.000, 282.000, 0.95})
            camera_pan = 92
    
    
        elseif camera_pan == 92 then
            CampaignUI.ScrollCamera(17,    {104.000, 346.000, 0.90},
                                    {173.000, 275.000, 0.90},
                                    {230.000, 270.000, 0.95})
            camera_pan = 93
    
    
        elseif camera_pan == 93 then
            CampaignUI.ScrollCamera(27,    {-15.000, 322.000, 0.85},
                                    {184.000, 307.000, 0.80},
                                    {68.000, 246.000, 0.75})
            camera_pan = 94
    
    
        elseif camera_pan == 94 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(202.000, 290.000)
            camera_pan = 0
            
    
    
    --1007_Campaign_Advice_Sweden_Initial_Turns_Thread
    
    
        elseif camera_pan == 101 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(125.000, 417.000)
            camera_pan = 0
            
    
    
    --1010a_Campaign_Advice_Maratha_Initial_Turns_Thread
    
    
        elseif camera_pan == 111 then
            CampaignUI.ScrollCamera(22,    {587.000, 112.000, 0.95},
                                    {553.000, 134.000, 0.95},
                                    {525.000, 96.000, 0.85},
                                    {547.000, 69.000, 0.85},
                                    {571.000, 53.000, 0.85})
            camera_pan = 112
    
    
        elseif camera_pan == 112 then
            CampaignUI.ScrollCamera(7,    {-3.000, 368.000, 0.90},
                                    {21.000, 340.000, 0.90})
            camera_pan = 113
        
        elseif camera_pan == 113 then
            CampaignUI.ScrollCamera(14,    {582.000, 37.000, 0.85},
                                    {527.000, 122.000, 0.75})
            camera_pan = 114
                                
        elseif camera_pan == 114 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(527.000, 122.000)
            camera_pan = 0
            
        
        end
    end
    
    
    
    
    
    
    
    
    local function OnAdviceDismissed(context)
        if conditions.AdviceJustDisplayed("-1875830202", context) then
            scripting.HighlightComponent("button_melee", false)
    
    
        elseif conditions.AdviceJustDisplayed("-758254518", context) then
            scripting.HighlightComponent("button_withdraw", false)
    
    
        elseif conditions.AdviceJustDisplayed("737354545", context) then
            scripting.HighlightComponent("button_fire_at_will", false)
    
    
        elseif conditions.AdviceJustDisplayed("2029281479", context) then
            scripting.HighlightComponent("button_groupforms", false)
    
    
        elseif conditions.AdviceJustDisplayed("1621609724", context) then
            scripting.HighlightComponent("button_withdraw", false)
    
    
        elseif conditions.AdviceJustDisplayed("313094221", context) then
            scripting.HighlightComponent("button_halt", false)
    
    
        elseif conditions.AdviceJustDisplayed("-722605174", context) then
            scripting.HighlightComponent("button_group", false)
    
    
        elseif conditions.AdviceJustDisplayed("-537894077", context) then
            scripting.HighlightComponent("button_groupforms", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1755835367", context) then
            scripting.HighlightComponent("radar", false)
    
    
        elseif conditions.AdviceJustDisplayed("1424352004", context) then
            scripting.HighlightComponent("button_melee", false)
    
    
        elseif conditions.AdviceJustDisplayed("593395637", context) then
            scripting.HighlightComponent("button_movespeed", false)
    
    
        elseif conditions.AdviceJustDisplayed("-729505557", context) then
            scripting.HighlightComponent("killometer_clip", false)
    
    
        elseif conditions.AdviceJustDisplayed("1738763088", context) then
            scripting.HighlightComponent("button_halt", false)
    
    
        elseif conditions.AdviceJustDisplayed("-2693399", context) then
            scripting.HighlightComponent("button_fire_at_will", false)
    
    
        elseif conditions.AdviceJustDisplayed("1169098043", context) then
            scripting.HighlightComponent("nav_button_broadside_L", false)
        
        elseif conditions.AdviceJustDisplayed("1950152570", context) then
            scripting.HighlightComponent("button_fire_at_will", false)
    
    
        elseif conditions.AdviceJustDisplayed("-608013080", context) then
            scripting.HighlightComponent("radar", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1459886398", context) then
            scripting.HighlightComponent("nav_button_shot_chain", false)
    
    
        elseif conditions.AdviceJustDisplayed("1813634075", context) then
            scripting.HighlightComponent("nav_button_broadside_L", false)
            
        elseif conditions.AdviceJustDisplayed("-111077650", context) then
            scripting.HighlightComponent("nav_button_shot_standard", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1507140649", context) then
            scripting.HighlightComponent("nav_button_shot_grape", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1177825588", context) then
            scripting.HighlightComponent("nav_button_shot_chain", false)
    
    
        elseif conditions.AdviceJustDisplayed("2073993693", context) then
            scripting.HighlightComponent("radar", false)
    
    
        elseif conditions.AdviceJustDisplayed("646906330", context) then
            scripting.HighlightComponent("nav_UC_button_turn_left", false)
            
        elseif conditions.AdviceJustDisplayed("-145936557", context) then
            scripting.HighlightComponent("nav_button_broadside_L", false)
    
    
        elseif conditions.AdviceJustDisplayed("1188422552", context) then
            scripting.HighlightComponent("nav_button_broadside_R", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1944874567", context) then
            scripting.HighlightComponent("button_group", false)
    
    
        elseif conditions.AdviceJustDisplayed("-783991516", context) then
            scripting.HighlightComponent("button_withdraw", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1827006635", context) then
            scripting.HighlightComponent("button_fire_at_will", false)
    
    
        elseif conditions.AdviceJustDisplayed("952924146", context) then
            scripting.HighlightComponent("nav_button_board", false)
    
    
        elseif conditions.AdviceJustDisplayed("1916043659", context) then
            scripting.HighlightComponent("nav_button_groupforms", false)
    
    
        elseif conditions.AdviceJustDisplayed("-891171119", context) then
            scripting.HighlightComponent("button_public-order lowest", false)
    
    
        elseif conditions.AdviceJustDisplayed("1216388585", context) then
            scripting.HighlightComponent("Icon", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1061827595", context) then
            scripting.HighlightComponent("army_promote", false)
    
    
        elseif conditions.AdviceJustDisplayed("695400466", context) then
            scripting.HighlightComponent("navy_promote", false)
    
    
        elseif conditions.AdviceJustDisplayed("1326115363", context) then
            scripting.HighlightComponent("army_fort", false)
    
    
        elseif conditions.AdviceJustDisplayed("659772888", context) then
            scripting.HighlightComponent("recruitment_tab", false)
    
    
        elseif conditions.AdviceJustDisplayed("1372607332", context) then
            scripting.HighlightComponent("army_replenish", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1671835166", context) then
            scripting.HighlightComponent("button_government", false)
    
    
        elseif conditions.AdviceJustDisplayed("1242837398", context) then
            scripting.HighlightComponent("button_diplomacy", false)
    
    
        elseif conditions.AdviceJustDisplayed("1049050650", context) then
            scripting.HighlightComponent("button_missions", false)
    
    
        elseif conditions.AdviceJustDisplayed("-956562909", context) then
            scripting.HighlightComponent("button_missions", false)
    
    
        elseif conditions.AdviceJustDisplayed("295527590", context) then
            scripting.HighlightComponent("button_diplomacy", false)
    
    
        elseif conditions.AdviceJustDisplayed("1264671506", context) then
            scripting.HighlightComponent("button_diplomacy", false)
    
    
        elseif conditions.AdviceJustDisplayed("1219045742", context) then
            scripting.HighlightComponent("button_tech", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1395907252", context) then
            scripting.HighlightComponent("button_tech", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1604004259", context) then
            scripting.HighlightComponent("button_tech", false)
    
    
        elseif conditions.AdviceJustDisplayed("-174893187", context) then
            scripting.HighlightComponent("build_browser", false)
    
    
        elseif conditions.AdviceJustDisplayed("-428335498", context) then
            scripting.HighlightComponent("button_government", false)
    
    
        elseif conditions.AdviceJustDisplayed("-250658412", context) then
            scripting.HighlightComponent("button_government", false)
              
     --************************************** this is how you can stop the camera pan when the user dismisses the advice
     
        elseif camera_pan ~= 0 then
            
         --Britain
             if conditions.AdviceJustDisplayed("-324484024", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(0.000, 362.000)
                  
        --France
            elseif conditions.AdviceJustDisplayed("-1886952522", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(17.387, 332.769)
    
    
        --Spain
            elseif conditions.AdviceJustDisplayed("-1109259521", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(-26.750, 280.811)
    
    
        --Russia
            elseif conditions.AdviceJustDisplayed("-1808331232", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(267.000, 391.000)
            
        --Prussia
            elseif conditions.AdviceJustDisplayed("962797902", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(95.000, 368.000)
            
        --Dutch    
            elseif conditions.AdviceJustDisplayed("-1766231494", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(35.000, 371.000)
            
        --Austria    
            elseif conditions.AdviceJustDisplayed("-1522516535", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (116.000, 339.000)
            
        --Poland
            elseif conditions.AdviceJustDisplayed("665527234", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (150.000, 367.000)
            
        --Ottoman
            elseif conditions.AdviceJustDisplayed("1447626053", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (202.000, 290.000)
         
        --Sweden
            elseif conditions.AdviceJustDisplayed("-1638244308", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (125.000, 417.000)
         
        --Maratha
            elseif conditions.AdviceJustDisplayed("1221146494", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (527.000, 122.000)
    
    
            end
        end
    end
    
    
    local function OnWorldCreated()
        scripting.game_interface:technology_osmosis_for_playables_enable_culture("european")
        scripting.game_interface:technology_osmosis_for_playables_enable_all()
    
    
        scripting.game_interface:force_diplomacy("pirate", "afghanistan", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "austria", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "barbary_states", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "bavaria", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "britain", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "chechenya_dagestan", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "cherokee", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "colombia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "courland", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "crimean_khanate", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "denmark", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "france", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "genoa", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "georgia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "greece", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "hannover", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "hessen", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "rajpootana", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "hungary", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "huron", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "inuit", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "ireland", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "iroquoi", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "khanate_khiva", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "knights_stjohn", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "louisiana", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "mamelukes", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "maratha", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "hyderabad", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "mexico", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "morocco", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "mughal", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "mysore", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "naples_sicily", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "netherlands", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "new_spain", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "norway", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "ottomans", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "papal_states", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "piedmont_savoy", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "plains", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "poland_lithuania", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "portugal", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "prussia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "pueblo", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "punjab", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "quebec", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "russia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "safavids", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "saxony", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "scotland", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "spain", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "sweden", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "kandy", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "thirteen_colonies", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "utah_aztecs", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "united_states", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "venice", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "westphalia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "wurttemberg", "protectorate", false, false)
    
    
    end
    
    
    
    
    --------------------------------------------------------------------------------------------------------------------
    -- Add event callbacks
    -- For a list of all events supported create a "documentation" directory in your empire directory, run a debug build of the game and see
    -- the events.txt file
    --------------------------------------------------------------------------------------------------------------------
    scripting.AddEventCallBack("WorldCreated", OnWorldCreated)
    scripting.AddEventCallBack("AdviceIssued", OnAdviceIssued)
    scripting.AddEventCallBack("AdviceDismissed", OnAdviceDismissed)
    scripting.AddEventCallBack("AdviceSuperseded", OnAdviceDismissed)
    scripting.AddEventCallBack("CameraMoverFinished", OnCameraMoverFinished)
    scripting.AddEventCallBack("FactionTurnStart", OnFactionTurnStart)
    Note : Pirates can no longer demand a country become its protectorate. They have access to all other diplomatic options - why would you want to protect anyone anyway? Surely you want to paint the map black?

    EDIT : Not compatible with VDM
    Last edited by aleheroix; April 20, 2021 at 06:24 PM.

  17. #297

    Default Re: Gameplay options for IMPERIAL DESTROYER

    hey this works what you have done it makes it where you have all diplomatic options but vdm doesn't work anymore as in that backend script are you aware of this ?

  18. #298

    Default Re: Gameplay options for IMPERIAL DESTROYER

    so what happened to the play as jacobite britain option

  19. #299

    Default Re: Gameplay options for IMPERIAL DESTROYER

    Quote Originally Posted by AKCICEK View Post
    hey this works what you have done it makes it where you have all diplomatic options but vdm doesn't work anymore as in that backend script are you aware of this ?
    Try this and see if it works. I don't have VDM but I've pretty much just added the same thing. If there is no option to force protectorate then it should work. Needs a few turns to be sure though.

    Code:
    local advice = require "export_advice"local historic_events = require "export_historic_events"
    local scripting = require "EpisodicScripting"
    local camera_pan = 0
    
    
    --m_root = nil
    
    
    justSaved = false
    local newCampaign = false
    justLoaded = false
    
    
    
    
    -- table of regions objects
    regions = {}       
    factions = {}
    demolishBildList = {}
    CurFaction={}
    GovTypeList={}
    LisbonEarth=false
    Capitals= {}
    CapitalsLate= {}
    Rebellions = {}
    LateCampaign=false
    
    
    vdmlog = io.open('vdmlog.txt','w')
    vdmlog:write("Starting log\n\n")
        
    function stupidErrorCatchFunction()
    
    
    InitReplenish = assert(loadfile("Replenishment"))
    setfenv(InitReplenish, getfenv())
    InitReplenish()
    
    
    
    
    local dip = require "data.VDM_dip" --VDM.VDM_lib
    local lib = require "data.VDM_lib" --VDM.VDM_lib
    local evn = require "data.VDM_events"
    
    
    vdmlog = io.open('vdmlog.txt','w')
    vdmlog:write("Starting log\n\n")
    
    
    local function OnFactionTurnStart(context)
        
        if conditions.TurnNumber(context) == 2 then
            if conditions.FactionName("russia", context) and conditions.FactionIsHuman("russia", context) then
                scripting.game_interface:trigger_custom_mission("russia_protectorate", "russia", "capture_city", 0, "don_voisko", "", "mission_text_text_main_protectorate_don_voisko_text", "", 5000, "", context)
            end
        elseif conditions.TurnNumber(context) == 3 then
            if conditions.FactionName("russia", context) and conditions.FactionIsHuman("russia", context) then
                scripting.game_interface:trigger_custom_mission("russia_protectorate", "russia", "protectorate_region_capture", 0, "ingria+crimea+estonia_and_livonia+belarus", "", "mission_text_text_main_protectorate_hetmanat_text", "mission_text_text_main_protectorate_hetmanat_reward", 0, "hungary", context)
            end
        elseif conditions.TurnNumber(context) == 5 then
            scripting.game_interface:enable_auto_generated_missions(true)
        end        
    end
    
    
    events.UICreated[#events.UICreated+1] = function (context)
    if context.string=="Campaign UI" then
    --Options
    DeseaseScript=true
    DisasterScript=true
    ClimateScript=true
    RiseDeadFactionScript=true
    WarDipScript=true
    RebellionsScript=true
    EventScript=true
    OccupScript=true
    ArmyRepScript=true
    DiplomacyScript=true
    SpyRebScript=true
    TraditionScript=true
    ResourcesScript=true
    GentExpScript=true
    ManpowerScript=true
    StormScript=true
    TradeShipsScript=true
    SomeBrainsToAI=true
    ConspScript=true
    SlavesScript=true
    ReligionScript=true
    CultScript=true
    TaskScript=true
    ---------NOT STABLE SCRIPTS (turn on on your own risk)
    GeneralScript=false
    --scripting.game_interface:show_shroud(false)      
    end
          local m_root = UIComponent(context.component)
        local c = m_root:Find("army_fort")
        local p = UIComponent(c):Parent()
        UIComponent(c):SetDisabled(true)
        UIComponent(p):Divorce(c)
    end
    --basic manpower (ManpowerMult*20)
    ManpowerMult=1
    --campaign difficulty
    --easy=1, normal=2, hard=3, very hard=4
    CurDif=3
    
    
    local function OnAdviceIssued(context)
            -- 0013_Battle_Advice_Missile_Superiority_Thread
        if conditions.AdviceJustDisplayed("-1875830202", context) then
            scripting.HighlightComponent("button_melee", true)
    
    
        -- 0065_Battle_Advice_Outnumbered_By_The_Enemy_Thread
        elseif conditions.AdviceJustDisplayed("-758254518", context) then
            scripting.HighlightComponent("button_withdraw", true)
    
    
        -- 0077_Battle_Advice_Fire_At_Will_Button_Thread 
        elseif conditions.AdviceJustDisplayed("737354545", context) then
            scripting.HighlightComponent("button_fire_at_will", true)
    
    
          --0079_Battle_Advice_Group_Formations_Button_Thread 
        elseif conditions.AdviceJustDisplayed("2029281479", context) then
            scripting.HighlightComponent("button_groupforms", true)
    
    
        --0080_Battle_Advice_Withdraw_Button_Thread 
        elseif conditions.AdviceJustDisplayed("1621609724", context) then
            scripting.HighlightComponent("button_withdraw", true)
    
    
        --0081_Battle_Advice_Cancel_Order_Button_Thread 
        elseif conditions.AdviceJustDisplayed("313094221", context) then
            scripting.HighlightComponent("button_halt", true)
    
    
        --0082_Battle_Advice_Group_Button_Thread
         elseif conditions.AdviceJustDisplayed("-722605174", context) then
            scripting.HighlightComponent("button_group", true)
    
    
        --0083_Battle_Advice_Group_Formations_Button_Thread
         elseif conditions.AdviceJustDisplayed("-537894077", context) then
            scripting.HighlightComponent("button_groupforms", true)
    
    
        --0100_Battle_Advice_Radar_Map_Thread
         elseif conditions.AdviceJustDisplayed("-1755835367", context) then
            scripting.HighlightComponent("radar", true)
    
    
        --0103_Battle_Advice_Melee_Button_Thread
         elseif conditions.AdviceJustDisplayed("1424352004", context) then
            scripting.HighlightComponent("button_melee", true)
    
    
        --0104_Battle_Advice_Run_Button_Thread
         elseif conditions.AdviceJustDisplayed("593395637", context) then
            scripting.HighlightComponent("button_movespeed", true)
    
    
        --0106_Battle_Advice_Killometer_Thread
         elseif conditions.AdviceJustDisplayed("-729505557", context) then
            scripting.HighlightComponent("killometer_clip", true)
    
    
        --0107_Battle_Advice_Bombardment_Thread
         elseif conditions.AdviceJustDisplayed("1738763088", context) then
            scripting.HighlightComponent("button_halt", true)
        
        --0144_Battle_Advice_Defending_Forts_Thread
         elseif conditions.AdviceJustDisplayed("-2693399", context) then
            scripting.HighlightComponent("button_fire_at_will", true)
            
        --0150_Battle_Advice_Target_Their_Weaknesses_Thread
         elseif conditions.AdviceJustDisplayed("1169098043", context) then
            scripting.HighlightComponent("nav_button_broadside_L", true)    
            
        --0157_Battle_Advice_Ship_Ablaze_Thread
         elseif conditions.AdviceJustDisplayed("1950152570", context) then
            scripting.HighlightComponent("button_fire_at_will", true)
    
    
        --0175_Battle_Advice_Wind_Direction_Thread
         elseif conditions.AdviceJustDisplayed("-608013080", context) then
            scripting.HighlightComponent("radar", true)
    
    
        --0181_Battle_Advice_Outgunned_Avoidance_Thread
         elseif conditions.AdviceJustDisplayed("-1459886398", context) then
            scripting.HighlightComponent("nav_button_shot_chain", true)
    
    
        --0182_Battle_Advice_Crossing_The_T_Thread
         elseif conditions.AdviceJustDisplayed("1813634075", context) then
            scripting.HighlightComponent("nav_button_broadside_L", true)
        
        --0185_Battle_Advice_Naval_Round_Shot_Thread
         elseif conditions.AdviceJustDisplayed("-111077650", context) then
            scripting.HighlightComponent("nav_button_shot_standard", true)    
    
    
        --0186_Battle_Advice_Naval_Grape_Shot_Thread
         elseif conditions.AdviceJustDisplayed("-1507140649", context) then
            scripting.HighlightComponent("nav_button_shot_grape", true)    
    
    
    
    
        --0187_Battle_Advice_Naval_Chain_Shot_Thread
         elseif conditions.AdviceJustDisplayed("-1177825588", context) then
            scripting.HighlightComponent("nav_button_shot_chain", true)
    
    
        --0188_Battle_Advice_Naval_Radar_Map_Thread
         elseif conditions.AdviceJustDisplayed("2073993693", context) then
            scripting.HighlightComponent("radar", true)
    
    
        --0189_Battle_Advice_Naval_Manoeuvre_Compass_Thread
         elseif conditions.AdviceJustDisplayed("646906330", context) then
            scripting.HighlightComponent("nav_UC_button_turn_left", true)    
        
        --0190_Battle_Advice_Left_Broadside_Button_Thread
         elseif conditions.AdviceJustDisplayed("-145936557", context) then
            scripting.HighlightComponent("nav_button_broadside_L", true)
    
    
        --0191_Battle_Advice_Right_Broadside_Button_Thread
         elseif conditions.AdviceJustDisplayed("1188422552", context) then
            scripting.HighlightComponent("nav_button_broadside_R", true)
    
    
        --0192_Battle_Advice_Naval_Group_Button_Thread
         elseif conditions.AdviceJustDisplayed("-1944874567", context) then
            scripting.HighlightComponent("button_group", true)
    
    
        --0195_Battle_Advice_Naval_Withdraw_Button_Thread
         elseif conditions.AdviceJustDisplayed("-783991516", context) then
            scripting.HighlightComponent("button_withdraw", true)
    
    
        --0196_Battle_Advice_Naval_Fire_At_Will_Thread
         elseif conditions.AdviceJustDisplayed("-1827006635", context) then
            scripting.HighlightComponent("button_fire_at_will", true)
    
    
        --0197_Battle_Advice_Naval_Boarding_Button_Thread
         elseif conditions.AdviceJustDisplayed("952924146", context) then
            scripting.HighlightComponent("nav_button_board", true)
    
    
        --0198_Battle_Advice_Naval_Formations_Button_Thread
         elseif conditions.AdviceJustDisplayed("1916043659", context) then
            scripting.HighlightComponent("nav_button_groupforms", true)
    
    
        --1029_Campaign_Advice_UI_Government_Panel_Thread
         elseif conditions.AdviceJustDisplayed("-891171119", context) then
            scripting.HighlightComponent("button_public-order lowest", true)
    
    
        --1041_Campaign_Advice_UI_Incoming_Message_Thread
         elseif conditions.AdviceJustDisplayed("1216388585", context) then
            scripting.HighlightComponent("Icon", true)
    
    
        --1051_Campaign_Advice_Army_Promotions_Thread
         elseif conditions.AdviceJustDisplayed("-1061827595", context) then
            scripting.HighlightComponent("army_promote", true)
    
    
        --1052_Campaign_Advice_Navy_Promotions_Thread
         elseif conditions.AdviceJustDisplayed("695400466", context) then
            scripting.HighlightComponent("navy_promote", true)
    
    
        --1064_Campaign_Advice_Slot_Selected_Thread
         elseif conditions.AdviceJustDisplayed("1326115363", context) then
            scripting.HighlightComponent("army_fort", true)
    
    
        --1065_Campaign_Advice_Character_Selected_Thread
         elseif conditions.AdviceJustDisplayed("659772888", context) then
            scripting.HighlightComponent("recruitment_tab", true)
    
    
        --1065_Campaign_Advice_Character_Selected_Thread
         elseif conditions.AdviceJustDisplayed("1372607332", context) then
            scripting.HighlightComponent("army_replenish", true)
    
    
        --1100_Campaign_Advice_Government_Type_Thread
         elseif conditions.AdviceJustDisplayed("-1671835166", context) then
            scripting.HighlightComponent("button_government", true)
    
    
        --1110_Campaign_Advice_Trade_Routes_Thread
         elseif conditions.AdviceJustDisplayed("1242837398", context) then
            scripting.HighlightComponent("button_diplomacy", true)
    
    
        --1115_Campaign_Advice_Victory_Conditions_Thread
         elseif conditions.AdviceJustDisplayed("1049050650", context) then
            scripting.HighlightComponent("button_missions", true)
    
    
        --1116_Campaign_Advice_Prestige_Thread
         elseif conditions.AdviceJustDisplayed("-956562909", context) then
            scripting.HighlightComponent("button_missions", true)
    
    
        --1124_Campaign_Advice_Warning_Bankrupt_Thread
         elseif conditions.AdviceJustDisplayed("295527590", context) then
            scripting.HighlightComponent("button_diplomacy", true)
    
    
        --1127_Campaign_Advice_Warning_Trade_Thread
         elseif conditions.AdviceJustDisplayed("1264671506", context) then
            scripting.HighlightComponent("button_diplomacy", true)
    
    
        --1136_Campaign_Advice_Religious_Unrest_Thread
         elseif conditions.AdviceJustDisplayed("1219045742", context) then
            scripting.HighlightComponent("button_tech", true)
    
    
        --1138_Campaign_Advice_Warning_Population_Thread
         elseif conditions.AdviceJustDisplayed("-1395907252", context) then
            scripting.HighlightComponent("button_tech", true)
    
    
        --1202_Campaign_Advice_UI_Help_Buildings_Thread
         elseif conditions.AdviceJustDisplayed("-174893187", context) then
            scripting.HighlightComponent("build_browser", true)
    
    
        --1030b_Campaign_Advice_UI_Government_Panel_Thread
         elseif conditions.AdviceJustDisplayed("-428335498", context) then
            scripting.HighlightComponent("button_government", true)
    
    
        --1030c_Campaign_Advice_UI_Government_Panel_Thread
         elseif conditions.AdviceJustDisplayed("-250658412", context) then
            scripting.HighlightComponent("button_government", true)
    
    
    
    
    --1001_Campaign_Advice_Britain_Initial_Turns_Thread
    --Britain camera pans = 11, 12, 13, 14, 15
        
        elseif conditions.AdviceJustDisplayed("-324484024", context) and not CampaignUI.IsMultiplayer() then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(18,    {-57.000, 418.000, 0.75},
                                    {-29.000, 362.000, 0.95},
                                    {36.000, 371.000, 0.95},
                                    {98.000, 378.000, 0.85})
            camera_pan = 11
    
    
    
    
    --1002_Campaign_Advice_France_Initial_Turns_Thread
    --France camera pans = 21, 22, 23, 24
        
        elseif conditions.AdviceJustDisplayed("-1886952522", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(49,    {0.000, 332.000, 0.95},
                                    {43.000, 336.000, 0.85},
                                    {70.000, 332.000, 0.95},
                                    {98.000, 363.000, 0.95},
                                    {47.000, 367.000, 0.85},
                                    {70.000, 329.000, 0.85},
                                    {17.000, 332.000, 0.75})
            camera_pan = 21
    
    
    
    
    --1003_Campaign_Advice_Spain_Initial_Turns_Thread
    --Spain camera pans = 31, 32, 33
        elseif conditions.AdviceJustDisplayed("-1109259521", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(17,    {-37.000, 274.000, 0.75},
                                    {-3.000, 295.000, 0.80},
                                    {95.000, 276.000, 0.85},
                                    {157.000, 287.000, 0.75})
                                    --{218.000, 247.000, 0.75})
            camera_pan = 31
            
            
    --1005_Campaign_Advice_Russia_Initial_Turns_Thread
    --Russia camera pans = 41, 42
        
        elseif conditions.AdviceJustDisplayed("-1808331232", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(21,    {279.000, 386.000, 0.80},
                                    {221.000, 387.000, 0.75},
                                    {219.00, 326.000, 0.65},
                                    {147.000, 287.000, 0.75})
            camera_pan = 41
        
        
    --1006_Campaign_Advice_Prussia_Initial_Turns_Thread
    --Prussia camera pans = 51, 52
        
        elseif conditions.AdviceJustDisplayed("962797902", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(25,    {104.000, 366.000, 0.90},
                                    {91.000, 370.000, 0.95},
                                    {82.000, 366.000, 0.95},
                                    {106.00, 352.000, 0.90},
                                    {120.000, 359.000, 0.95},
                                    {137.000, 384.000, 0.95})
                                
            camera_pan = 51
        
        
    --1008_Campaign_Advice_Dutch_Initial_Turns_Thread
    --Dutch camera pans = 61, 62, 63, 64
        
        elseif conditions.AdviceJustDisplayed("-1766231494", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(18,    {35.000, 372.000, 1.00},
                                    {40.000, 354.000, 0.95},
                                    {29.00, 352.000, 0.90},
                                    {22.000, 365.000, 0.95},
                                    {35.000, 371.000, 1.00})
            camera_pan = 61
    
    
    
    
    --1009_Campaign_Advice_Austria_Initial_Turns_Thread
    --Austria camera pans = 71, 72, 73
        
        elseif conditions.AdviceJustDisplayed("-1522516535", context) and not CampaignUI.IsMultiplayer() then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(27,    {116.000, 339.000, 1.00},
                                    {160.000, 310.000, 0.95},
                                    {115.00, 322.000, 0.95},
                                    {132.000, 351.000, 0.95},
                                    {116.000, 339.000, 0.80})
            camera_pan = 71
        
        
        
    --1012_Campaign_Advice_Poland_Initial_Turns_Thread
    --Poland camera pans = 81, 82, 83, 84
        
        elseif conditions.AdviceJustDisplayed("665527234", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(11,    {181.000, 352.000, 0.90},
                                    {131.000, 348.000, 0.85},
                                    {129.000, 375.000, 0.90})
    
    
                                    
            camera_pan = 81    
        
    
    
    --1004_Campaign_Advice_Ottoman_Initial_Turns_Thread
    --Ottoman camera pans = 91, 92, 93, 94
    
    
        elseif conditions.AdviceJustDisplayed("1447626053", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(21,    {171.000, 291.000, 0.75},
                                    {145.000, 335.000, 0.80},
                                    {223.000, 309.000, 0.85},
                                    {125.000, 306.000, 0.80})
                                    
            camera_pan = 91    
    
    
    
    
    --1007_Campaign_Advice_Sweden_Initial_Turns_Thread
    --Sweden camera pans = 101, 102
        
            elseif conditions.AdviceJustDisplayed("-1638244308", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(39,    {110.000, 418.000, 0.75},
                                    {201.000, 418.000, 0.75},
                                    {125.000, 388.000, 0.75},
                                    {21.000, 365.000, 0.75},
                                    {62.000, 310.000, 0.75},
                                    {172.000, 283.000, 0.75})
            
            camera_pan = 101    
    
    
    
    
    --1010a_Campaign_Advice_Maratha_Initial_Turns_Thread
    --Maratha camera pans = 111, 112
    
    
            elseif conditions.AdviceJustDisplayed("1221146494", context) and not CampaignUI.IsMultiplayer()  then
            scripting.game_interface:set_zoom_limit(1.08, 0.02)
            CampaignUI.ScrollCamera(24,    {527.000, 122.000, 0.95},
                                    {549.000, 94.000, 0.85},
                                    {543.000, 181.000, 0.95})
                                    
            camera_pan = 111    
    
    
        
        end
    end
    
    
    
    
    local function OnCameraMoverFinished(context)
    
    
    --1001_Campaign_Advice_Britain_Initial_Turns_Thread
    
    
        if camera_pan == 11 then
            CampaignUI.ScrollCamera(11,    {49.000, 332.000, 0.95},
                                    {8.000, 324.000, 0.95},
                                    {-31.000, 282.000, 0.85})
            camera_pan = 12
            
        elseif camera_pan == 12 then
            CampaignUI.ScrollCamera(15,    {-515.000, 121.000, 0.85},
                                    {-580.000, 204.000, 0.75},
                                    {-548.000, 274.000, 0.75},
                                    {-504.000, 311.000, 0.75})
            camera_pan = 13
        
        elseif camera_pan == 13 then
            CampaignUI.ScrollCamera(29,    {523.000, 55.000, 0.65},
                                    {599.000, 135.000, 0.75},
                                    {554.000, 186.000, 0.85},
                                    {504.000, 163.000, 0.85},
                                    {528.000, 114.000, 0.85},
                                    {563.000, 80.000, 0.75},
                                    {532.000, 167.000, 0.65})
            camera_pan = 14
            
        elseif camera_pan == 14 then
            CampaignUI.ScrollCamera(8,    {18.000, 342.000, 0.95},
                                    {6.000, 356.000, 0.95},
                                    {0.000, 362.000, 0.75})
            camera_pan = 15
            
        elseif camera_pan == 15 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(0.000, 362.000)
            camera_pan = 0
    
    
    
    
    --1002_Campaign_Advice_France_Initial_Turns_Thread
    
    
        elseif camera_pan == 21 then
            CampaignUI.ScrollCamera(18,    {-454.000, 349.000, 0.75},
                                    {-514.000, 325.000, 0.80},
                                    {-579.000, 249.000, 0.80},
                                    {-586.000, 179.000, 0.75})
            camera_pan = 22
            
        elseif camera_pan == 22 then
            CampaignUI.ScrollCamera(18,    {490.000, 169.000, 0.75},
                                    {577.000, 72.000, 0.80},
                                    {534.000, 35.000, 0.75},                                
                                    {528.000, 113.000, 0.75})
            camera_pan = 23
    
    
        elseif camera_pan == 23 then
            CampaignUI.ScrollCamera(20,    {-391.000, 177.000, 0.95},
                                    {-432.000, 167.000, 0.95},
                                    {-453.000, 126.000, 0.95},
                                    {-434.000, 96.000, 0.95},
                                    {-467.000, 83.000, 0.90},
                                    {-486.000, 108.000, 0.85},
                                    {-519.000, 137.000, 0.80},
                                    {-581.000, 165.000, 0.75})
            camera_pan = 24
            
        elseif camera_pan == 24 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(17.387, 332.769)
            camera_pan = 0
    
    
    
    
    --1003_Campaign_Advice_Spain_Initial_Turns_Thread
    
    
        elseif camera_pan == 31 then
            CampaignUI.ScrollCamera(18,    {30.000, 375.000, 0.95},
                                    {39.000, 353.000, 0.90},
                                    {0.000, 349.000, 0.85})
            camera_pan = 32
    
    
        elseif camera_pan == 32 then
            CampaignUI.ScrollCamera(27,    {-492.000, 194.000, 0.95},
                                    {-562.000, 168.000, 0.80},
                                    {-500.000, 84.000, 0.70},
                                    {-541.000, 161.000, 0.50})
            camera_pan = 33
    
    
        elseif camera_pan == 33 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(-26.750, 280.811)
            camera_pan = 0
    
    
    
    
    --1005_Campaign_Advice_Russia_Initial_Turns_Thread
        
            elseif camera_pan == 41 then
            CampaignUI.ScrollCamera(34,    {147.000, 376.000, 0.90},
                                    {116.000, 338.000, 0.80},
                                    {73.000, 322.000, 0.75},
                                    {48.000,328.000, 0.75},
                                    {8.000, 351.000, 0.75},
                                    {42.000, 386.000, 0.75},
                                    {93.000, 368.000, 0.80},
                                    {150.000, 360.000, 0.90},
                                    {190.000, 418.000, 0.60})
            camera_pan = 42
        
        elseif camera_pan == 42 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(267.000, 391.000)
            camera_pan = 0
        
    --1006_Campaign_Advice_Prussia_Initial_Turns_Thread
    
    
            camera_pan = 51
    
    
            elseif camera_pan == 51 then
            CampaignUI.ScrollCamera(23,    {140.000, 437.000, 0.75},
                                    {64.000, 397.000, 0.75},
                                    {22.000, 347.000, 0.85},
                                    {100.000, 335.000, 0.95},
                                    {95.000, 368.000, 0.80})
            camera_pan = 52
    
    
        elseif camera_pan == 52 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(95.000, 368.000)
            camera_pan = 0
        
    --1008_Campaign_Advice_Dutch_Initial_Turns_Thread
    
    
        elseif camera_pan == 61 then
            CampaignUI.ScrollCamera(14,    {-35.000, 431.000, 0.95},
                                    {5.000, 352.000, 0.85},
                                    {95.000, 369.000, 0.95})
            camera_pan = 62
            
        elseif camera_pan == 62 then
            CampaignUI.ScrollCamera(8,    {-489.000, 85.000, 0.95},
                                    {-490.000, 81.000, 0.80})
            camera_pan = 63
            
        elseif camera_pan == 63 then
            CampaignUI.ScrollCamera(8,    {851.000, -62.000, 0.95},
                                    {878.000, -69.000, 0.95})
            camera_pan = 64
            
        elseif camera_pan == 64 then
            CampaignUI.ScrollCamera(8,    {562.000, 58.000, 0.75},
                                    {570.000, 56.000, 0.90})
            camera_pan = 65
            
        elseif camera_pan == 65 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(35.000, 371.000)
            camera_pan = 0
            
    
    
    --1009_Campaign_Advice_Austria_Initial_Turns_Thread
    
    
        elseif camera_pan == 71 then
            CampaignUI.ScrollCamera(22,    {31.000, 377.000, 0.80},
                                    {68.000, 361.000, 0.90},
                                    {106.000, 368.000, 0.95},
                                    {135.000, 329.000, 0.80})
            camera_pan = 72
            
        elseif camera_pan == 72 then
            CampaignUI.ScrollCamera(24,    {204.000, 428.000, 0.80},
                                    {128.000, 365.000, 0.90},
                                    {172.000, 356.000, 0.90},
                                    {255.000, 380.000, 0.75})
            camera_pan = 73
            
        elseif camera_pan == 73 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(116.000, 339.000)
            camera_pan = 0
        
        
    --1012_Campaign_Advice_Poland_Initial_Turns_Thread
                                
        elseif camera_pan == 81 then
            CampaignUI.ScrollCamera(29,    {191.000, 413.000, 0.75},
                                    {220.000, 368.000, 0.75},
                                    {139.000, 324.000, 0.85},
                                    {144.000, 341.000, 0.85},
                                    {195.000, 379.000, 0.90})
            camera_pan = 82
            
        elseif camera_pan == 82 then
            CampaignUI.ScrollCamera(23,    {202.000, 290.000, 0.90},
                                    {182.000, 280.000, 0.90},
                                    {153.000, 329.000, 0.85},
                                    {284.000, 297.000, 0.75})
            camera_pan = 83
            
        elseif camera_pan == 83 then
            CampaignUI.ScrollCamera(13,    {-42.000, 278.000, 0.80},
                                    {8.000, 352.000, 0.75})
            camera_pan = 84
            
        elseif camera_pan == 84 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(150.000, 367.000)
            camera_pan = 0
            
    
    
    --1004_Campaign_Advice_Ottoman_Initial_Turns_Thread
    
    
        elseif camera_pan == 91 then
            CampaignUI.ScrollCamera(14,    {370.000, 231.000, 0.90},
                                    {315.000, 231.000, 0.90},
                                    {315.000, 282.000, 0.95})
            camera_pan = 92
    
    
        elseif camera_pan == 92 then
            CampaignUI.ScrollCamera(17,    {104.000, 346.000, 0.90},
                                    {173.000, 275.000, 0.90},
                                    {230.000, 270.000, 0.95})
            camera_pan = 93
    
    
        elseif camera_pan == 93 then
            CampaignUI.ScrollCamera(27,    {-15.000, 322.000, 0.85},
                                    {184.000, 307.000, 0.80},
                                    {68.000, 246.000, 0.75})
            camera_pan = 94
    
    
        elseif camera_pan == 94 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(202.000, 290.000)
            camera_pan = 0
            
    
    
    --1007_Campaign_Advice_Sweden_Initial_Turns_Thread
    
    
        elseif camera_pan == 101 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(125.000, 417.000)
            camera_pan = 0
            
    
    
    --1010a_Campaign_Advice_Maratha_Initial_Turns_Thread
    
    
        elseif camera_pan == 111 then
            CampaignUI.ScrollCamera(22,    {587.000, 112.000, 0.95},
                                    {553.000, 134.000, 0.95},
                                    {525.000, 96.000, 0.85},
                                    {547.000, 69.000, 0.85},
                                    {571.000, 53.000, 0.85})
            camera_pan = 112
    
    
        elseif camera_pan == 112 then
            CampaignUI.ScrollCamera(7,    {-3.000, 368.000, 0.90},
                                    {21.000, 340.000, 0.90})
            camera_pan = 113
        
        elseif camera_pan == 113 then
            CampaignUI.ScrollCamera(14,    {582.000, 37.000, 0.85},
                                    {527.000, 122.000, 0.75})
            camera_pan = 114
                                
        elseif camera_pan == 114 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(527.000, 122.000)
            camera_pan = 0
            
        
        end
    end
    
    
    
    
    local function OnCameraMoverFinished(context)
    
    
    --1001_Campaign_Advice_Britain_Initial_Turns_Thread
    
    
        if camera_pan == 11 then
            CampaignUI.ScrollCamera(11,    {49.000, 332.000, 0.95},
                                    {8.000, 324.000, 0.95},
                                    {-31.000, 282.000, 0.85})
            camera_pan = 12
            
        elseif camera_pan == 12 then
            CampaignUI.ScrollCamera(15,    {-515.000, 121.000, 0.85},
                                    {-580.000, 204.000, 0.75},
                                    {-548.000, 274.000, 0.75},
                                    {-504.000, 311.000, 0.75})
            camera_pan = 13
        
        elseif camera_pan == 13 then
            CampaignUI.ScrollCamera(29,    {523.000, 55.000, 0.65},
                                    {599.000, 135.000, 0.75},
                                    {554.000, 186.000, 0.85},
                                    {504.000, 163.000, 0.85},
                                    {528.000, 114.000, 0.85},
                                    {563.000, 80.000, 0.75},
                                    {532.000, 167.000, 0.65})
            camera_pan = 14
            
        elseif camera_pan == 14 then
            CampaignUI.ScrollCamera(8,    {18.000, 342.000, 0.95},
                                    {6.000, 356.000, 0.95},
                                    {0.000, 362.000, 0.75})
            camera_pan = 15
            
        elseif camera_pan == 15 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(0.000, 362.000)
            camera_pan = 0
    
    
    
    
    --1002_Campaign_Advice_France_Initial_Turns_Thread
    
    
        elseif camera_pan == 21 then
            CampaignUI.ScrollCamera(18,    {-454.000, 349.000, 0.75},
                                    {-514.000, 325.000, 0.80},
                                    {-579.000, 249.000, 0.80},
                                    {-586.000, 179.000, 0.75})
            camera_pan = 22
            
        elseif camera_pan == 22 then
            CampaignUI.ScrollCamera(18,    {490.000, 169.000, 0.75},
                                    {577.000, 72.000, 0.80},
                                    {534.000, 35.000, 0.75},                                
                                    {528.000, 113.000, 0.75})
            camera_pan = 23
    
    
        elseif camera_pan == 23 then
            CampaignUI.ScrollCamera(20,    {-391.000, 177.000, 0.95},
                                    {-432.000, 167.000, 0.95},
                                    {-453.000, 126.000, 0.95},
                                    {-434.000, 96.000, 0.95},
                                    {-467.000, 83.000, 0.90},
                                    {-486.000, 108.000, 0.85},
                                    {-519.000, 137.000, 0.80},
                                    {-581.000, 165.000, 0.75})
            camera_pan = 24
            
        elseif camera_pan == 24 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(17.387, 332.769)
            camera_pan = 0
    
    
    
    
    --1003_Campaign_Advice_Spain_Initial_Turns_Thread
    
    
        elseif camera_pan == 31 then
            CampaignUI.ScrollCamera(18,    {30.000, 375.000, 0.95},
                                    {39.000, 353.000, 0.90},
                                    {0.000, 349.000, 0.85})
            camera_pan = 32
    
    
        elseif camera_pan == 32 then
            CampaignUI.ScrollCamera(27,    {-492.000, 194.000, 0.95},
                                    {-562.000, 168.000, 0.80},
                                    {-500.000, 84.000, 0.70},
                                    {-541.000, 161.000, 0.50})
            camera_pan = 33
    
    
        elseif camera_pan == 33 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(-26.750, 280.811)
            camera_pan = 0
    
    
    
    
    --1005_Campaign_Advice_Russia_Initial_Turns_Thread
        
            elseif camera_pan == 41 then
            CampaignUI.ScrollCamera(34,    {147.000, 376.000, 0.90},
                                    {116.000, 338.000, 0.80},
                                    {73.000, 322.000, 0.75},
                                    {48.000,328.000, 0.75},
                                    {8.000, 351.000, 0.75},
                                    {42.000, 386.000, 0.75},
                                    {93.000, 368.000, 0.80},
                                    {150.000, 360.000, 0.90},
                                    {190.000, 418.000, 0.60})
            camera_pan = 42
        
        elseif camera_pan == 42 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(267.000, 391.000)
            camera_pan = 0
        
    --1006_Campaign_Advice_Prussia_Initial_Turns_Thread
    
    
            camera_pan = 51
    
    
            elseif camera_pan == 51 then
            CampaignUI.ScrollCamera(23,    {140.000, 437.000, 0.75},
                                    {64.000, 397.000, 0.75},
                                    {22.000, 347.000, 0.85},
                                    {100.000, 335.000, 0.95},
                                    {95.000, 368.000, 0.80})
            camera_pan = 52
    
    
        elseif camera_pan == 52 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(95.000, 368.000)
            camera_pan = 0
        
    --1008_Campaign_Advice_Dutch_Initial_Turns_Thread
    
    
        elseif camera_pan == 61 then
            CampaignUI.ScrollCamera(14,    {-35.000, 431.000, 0.95},
                                    {5.000, 352.000, 0.85},
                                    {95.000, 369.000, 0.95})
            camera_pan = 62
            
        elseif camera_pan == 62 then
            CampaignUI.ScrollCamera(8,    {-489.000, 85.000, 0.95},
                                    {-490.000, 81.000, 0.80})
            camera_pan = 63
            
        elseif camera_pan == 63 then
            CampaignUI.ScrollCamera(8,    {851.000, -62.000, 0.95},
                                    {878.000, -69.000, 0.95})
            camera_pan = 64
            
        elseif camera_pan == 64 then
            CampaignUI.ScrollCamera(8,    {562.000, 58.000, 0.75},
                                    {570.000, 56.000, 0.90})
            camera_pan = 65
            
        elseif camera_pan == 65 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(35.000, 371.000)
            camera_pan = 0
            
    
    
    --1009_Campaign_Advice_Austria_Initial_Turns_Thread
    
    
        elseif camera_pan == 71 then
            CampaignUI.ScrollCamera(22,    {31.000, 377.000, 0.80},
                                    {68.000, 361.000, 0.90},
                                    {106.000, 368.000, 0.95},
                                    {135.000, 329.000, 0.80})
            camera_pan = 72
            
        elseif camera_pan == 72 then
            CampaignUI.ScrollCamera(24,    {204.000, 428.000, 0.80},
                                    {128.000, 365.000, 0.90},
                                    {172.000, 356.000, 0.90},
                                    {255.000, 380.000, 0.75})
            camera_pan = 73
            
        elseif camera_pan == 73 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(116.000, 339.000)
            camera_pan = 0
        
        
    --1012_Campaign_Advice_Poland_Initial_Turns_Thread
                                
        elseif camera_pan == 81 then
            CampaignUI.ScrollCamera(29,    {191.000, 413.000, 0.75},
                                    {220.000, 368.000, 0.75},
                                    {139.000, 324.000, 0.85},
                                    {144.000, 341.000, 0.85},
                                    {195.000, 379.000, 0.90})
            camera_pan = 82
            
        elseif camera_pan == 82 then
            CampaignUI.ScrollCamera(23,    {202.000, 290.000, 0.90},
                                    {182.000, 280.000, 0.90},
                                    {153.000, 329.000, 0.85},
                                    {284.000, 297.000, 0.75})
            camera_pan = 83
            
        elseif camera_pan == 83 then
            CampaignUI.ScrollCamera(13,    {-42.000, 278.000, 0.80},
                                    {8.000, 352.000, 0.75})
            camera_pan = 84
            
        elseif camera_pan == 84 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(150.000, 367.000)
            camera_pan = 0
            
    
    
    --1004_Campaign_Advice_Ottoman_Initial_Turns_Thread
    
    
        elseif camera_pan == 91 then
            CampaignUI.ScrollCamera(14,    {370.000, 231.000, 0.90},
                                    {315.000, 231.000, 0.90},
                                    {315.000, 282.000, 0.95})
            camera_pan = 92
    
    
        elseif camera_pan == 92 then
            CampaignUI.ScrollCamera(17,    {104.000, 346.000, 0.90},
                                    {173.000, 275.000, 0.90},
                                    {230.000, 270.000, 0.95})
            camera_pan = 93
    
    
        elseif camera_pan == 93 then
            CampaignUI.ScrollCamera(27,    {-15.000, 322.000, 0.85},
                                    {184.000, 307.000, 0.80},
                                    {68.000, 246.000, 0.75})
            camera_pan = 94
    
    
        elseif camera_pan == 94 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(202.000, 290.000)
            camera_pan = 0
            
    
    
    --1007_Campaign_Advice_Sweden_Initial_Turns_Thread
    
    
        elseif camera_pan == 101 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(125.000, 417.000)
            camera_pan = 0
            
    
    
    --1010a_Campaign_Advice_Maratha_Initial_Turns_Thread
    
    
        elseif camera_pan == 111 then
            CampaignUI.ScrollCamera(22,    {587.000, 112.000, 0.95},
                                    {553.000, 134.000, 0.95},
                                    {525.000, 96.000, 0.85},
                                    {547.000, 69.000, 0.85},
                                    {571.000, 53.000, 0.85})
            camera_pan = 112
    
    
        elseif camera_pan == 112 then
            CampaignUI.ScrollCamera(7,    {-3.000, 368.000, 0.90},
                                    {21.000, 340.000, 0.90})
            camera_pan = 113
        
        elseif camera_pan == 113 then
            CampaignUI.ScrollCamera(14,    {582.000, 37.000, 0.85},
                                    {527.000, 122.000, 0.75})
            camera_pan = 114
                                
        elseif camera_pan == 114 then
            scripting.game_interface:set_zoom_limit(1.0, 0.5)
            CampaignUI.SetCameraTarget(527.000, 122.000)
            camera_pan = 0
            
        
        end
    end
    
    
    
    
    
    
    
    
    local function OnAdviceDismissed(context)
        if conditions.AdviceJustDisplayed("-1875830202", context) then
            scripting.HighlightComponent("button_melee", false)
    
    
        elseif conditions.AdviceJustDisplayed("-758254518", context) then
            scripting.HighlightComponent("button_withdraw", false)
    
    
        elseif conditions.AdviceJustDisplayed("737354545", context) then
            scripting.HighlightComponent("button_fire_at_will", false)
    
    
        elseif conditions.AdviceJustDisplayed("2029281479", context) then
            scripting.HighlightComponent("button_groupforms", false)
    
    
        elseif conditions.AdviceJustDisplayed("1621609724", context) then
            scripting.HighlightComponent("button_withdraw", false)
    
    
        elseif conditions.AdviceJustDisplayed("313094221", context) then
            scripting.HighlightComponent("button_halt", false)
    
    
        elseif conditions.AdviceJustDisplayed("-722605174", context) then
            scripting.HighlightComponent("button_group", false)
    
    
        elseif conditions.AdviceJustDisplayed("-537894077", context) then
            scripting.HighlightComponent("button_groupforms", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1755835367", context) then
            scripting.HighlightComponent("radar", false)
    
    
        elseif conditions.AdviceJustDisplayed("1424352004", context) then
            scripting.HighlightComponent("button_melee", false)
    
    
        elseif conditions.AdviceJustDisplayed("593395637", context) then
            scripting.HighlightComponent("button_movespeed", false)
    
    
        elseif conditions.AdviceJustDisplayed("-729505557", context) then
            scripting.HighlightComponent("killometer_clip", false)
    
    
        elseif conditions.AdviceJustDisplayed("1738763088", context) then
            scripting.HighlightComponent("button_halt", false)
    
    
        elseif conditions.AdviceJustDisplayed("-2693399", context) then
            scripting.HighlightComponent("button_fire_at_will", false)
    
    
        elseif conditions.AdviceJustDisplayed("1169098043", context) then
            scripting.HighlightComponent("nav_button_broadside_L", false)
        
        elseif conditions.AdviceJustDisplayed("1950152570", context) then
            scripting.HighlightComponent("button_fire_at_will", false)
    
    
        elseif conditions.AdviceJustDisplayed("-608013080", context) then
            scripting.HighlightComponent("radar", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1459886398", context) then
            scripting.HighlightComponent("nav_button_shot_chain", false)
    
    
        elseif conditions.AdviceJustDisplayed("1813634075", context) then
            scripting.HighlightComponent("nav_button_broadside_L", false)
            
        elseif conditions.AdviceJustDisplayed("-111077650", context) then
            scripting.HighlightComponent("nav_button_shot_standard", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1507140649", context) then
            scripting.HighlightComponent("nav_button_shot_grape", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1177825588", context) then
            scripting.HighlightComponent("nav_button_shot_chain", false)
    
    
        elseif conditions.AdviceJustDisplayed("2073993693", context) then
            scripting.HighlightComponent("radar", false)
    
    
        elseif conditions.AdviceJustDisplayed("646906330", context) then
            scripting.HighlightComponent("nav_UC_button_turn_left", false)
            
        elseif conditions.AdviceJustDisplayed("-145936557", context) then
            scripting.HighlightComponent("nav_button_broadside_L", false)
    
    
        elseif conditions.AdviceJustDisplayed("1188422552", context) then
            scripting.HighlightComponent("nav_button_broadside_R", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1944874567", context) then
            scripting.HighlightComponent("button_group", false)
    
    
        elseif conditions.AdviceJustDisplayed("-783991516", context) then
            scripting.HighlightComponent("button_withdraw", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1827006635", context) then
            scripting.HighlightComponent("button_fire_at_will", false)
    
    
        elseif conditions.AdviceJustDisplayed("952924146", context) then
            scripting.HighlightComponent("nav_button_board", false)
    
    
        elseif conditions.AdviceJustDisplayed("1916043659", context) then
            scripting.HighlightComponent("nav_button_groupforms", false)
    
    
        elseif conditions.AdviceJustDisplayed("-891171119", context) then
            scripting.HighlightComponent("button_public-order lowest", false)
    
    
        elseif conditions.AdviceJustDisplayed("1216388585", context) then
            scripting.HighlightComponent("Icon", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1061827595", context) then
            scripting.HighlightComponent("army_promote", false)
    
    
        elseif conditions.AdviceJustDisplayed("695400466", context) then
            scripting.HighlightComponent("navy_promote", false)
    
    
        elseif conditions.AdviceJustDisplayed("1326115363", context) then
            scripting.HighlightComponent("army_fort", false)
    
    
        elseif conditions.AdviceJustDisplayed("659772888", context) then
            scripting.HighlightComponent("recruitment_tab", false)
    
    
        elseif conditions.AdviceJustDisplayed("1372607332", context) then
            scripting.HighlightComponent("army_replenish", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1671835166", context) then
            scripting.HighlightComponent("button_government", false)
    
    
        elseif conditions.AdviceJustDisplayed("1242837398", context) then
            scripting.HighlightComponent("button_diplomacy", false)
    
    
        elseif conditions.AdviceJustDisplayed("1049050650", context) then
            scripting.HighlightComponent("button_missions", false)
    
    
        elseif conditions.AdviceJustDisplayed("-956562909", context) then
            scripting.HighlightComponent("button_missions", false)
    
    
        elseif conditions.AdviceJustDisplayed("295527590", context) then
            scripting.HighlightComponent("button_diplomacy", false)
    
    
        elseif conditions.AdviceJustDisplayed("1264671506", context) then
            scripting.HighlightComponent("button_diplomacy", false)
    
    
        elseif conditions.AdviceJustDisplayed("1219045742", context) then
            scripting.HighlightComponent("button_tech", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1395907252", context) then
            scripting.HighlightComponent("button_tech", false)
    
    
        elseif conditions.AdviceJustDisplayed("-1604004259", context) then
            scripting.HighlightComponent("button_tech", false)
    
    
        elseif conditions.AdviceJustDisplayed("-174893187", context) then
            scripting.HighlightComponent("build_browser", false)
    
    
        elseif conditions.AdviceJustDisplayed("-428335498", context) then
            scripting.HighlightComponent("button_government", false)
    
    
        elseif conditions.AdviceJustDisplayed("-250658412", context) then
            scripting.HighlightComponent("button_government", false)
              
     --************************************** this is how you can stop the camera pan when the user dismisses the advice
     
        elseif camera_pan ~= 0 then
            
         --Britain
             if conditions.AdviceJustDisplayed("-324484024", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(0.000, 362.000)
                  
        --France
            elseif conditions.AdviceJustDisplayed("-1886952522", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(17.387, 332.769)
    
    
        --Spain
            elseif conditions.AdviceJustDisplayed("-1109259521", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(-26.750, 280.811)
    
    
        --Russia
            elseif conditions.AdviceJustDisplayed("-1808331232", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(267.000, 391.000)
            
        --Prussia
            elseif conditions.AdviceJustDisplayed("962797902", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(95.000, 368.000)
            
        --Dutch    
            elseif conditions.AdviceJustDisplayed("-1766231494", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget(35.000, 371.000)
            
        --Austria    
            elseif conditions.AdviceJustDisplayed("-1522516535", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (116.000, 339.000)
            
        --Poland
            elseif conditions.AdviceJustDisplayed("665527234", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (150.000, 367.000)
            
        --Ottoman
            elseif conditions.AdviceJustDisplayed("1447626053", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (202.000, 290.000)
         
        --Sweden
            elseif conditions.AdviceJustDisplayed("-1638244308", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (125.000, 417.000)
         
        --Maratha
            elseif conditions.AdviceJustDisplayed("1221146494", context) then
                  CampaignUI.StopCamera()
                  camera_pan = 0
                  scripting.game_interface:set_zoom_limit(1.0, 0.5)
                  CampaignUI.SetCameraTarget (527.000, 122.000)
    
    
            end
        end
    end
    
    
    local function OnWorldCreated()
        scripting.game_interface:technology_osmosis_for_playables_enable_culture("european")
        scripting.game_interface:technology_osmosis_for_playables_enable_all()    
            scripting.game_interface:add_restricted_building_level_record("western_artillery_fort")
            scripting.game_interface:add_restricted_building_level_record("star_fort")
            scripting.game_interface:spawn_town_level("maryland", 1, false)
            scripting.game_interface:spawn_town_level("wilderness_hudsonsbay", 1, false)
            scripting.game_interface:spawn_town_level("wilderness_canada", 1, false)
            scripting.game_interface:spawn_town_level("wilderness_mexico", 1, false)
            scripting.game_interface:spawn_town_level("wilderness_arabia", 1, false)
    
    
        scripting.game_interface:force_diplomacy("pirate", "afghanistan", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "austria", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "barbary_states", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "bavaria", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "britain", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "chechenya_dagestan", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "cherokee", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "colombia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "courland", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "crimean_khanate", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "denmark", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "france", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "genoa", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "georgia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "greece", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "hannover", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "hessen", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "rajpootana", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "hungary", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "huron", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "inuit", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "ireland", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "iroquoi", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "khanate_khiva", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "knights_stjohn", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "louisiana", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "mamelukes", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "maratha", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "hyderabad", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "mexico", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "morocco", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "mughal", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "mysore", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "naples_sicily", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "netherlands", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "new_spain", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "norway", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "ottomans", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "papal_states", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "piedmont_savoy", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "plains", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "poland_lithuania", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "portugal", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "prussia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "pueblo", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "punjab", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "quebec", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "russia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "safavids", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "saxony", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "scotland", "protectorate", fa"punjab", lse, false)
        scripting.game_interface:force_diplomacy("pirate", "spain", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "sweden", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "kandy", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "thirteen_colonies", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "utah_aztecs", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "united_states", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "venice", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "westphalia", "protectorate", false, false)
        scripting.game_interface:force_diplomacy("pirate", "wurttemberg", "protectorate", false, false)
    
    
    end
    
    
    -- 5. Perpetuation
    
    
    function UICreatedDoLoad(context)
         if justLoaded then
             
            
            extension,path = CampaignUI.FileExtenstionAndPathForWriteClass("save_game")
    
    
               -- run the perpetuate library
            status, returned = pcall(runPerpetuateLib)
            log("Perpetuate lib returned: "..returned.."\n") 
            perpetuate:loadSavesList()   
    
    
              -- run the region library
              status, returned = pcall(runRegionLib)
            log("Region lib returned: "..returned.."\n")
            stat, regions = pcall(initialiseRegionList)
            log(tostring(regions).."\n")
            
            -- run the faction library
            status, returned = pcall(runFactionLib)
            log("Faction lib returned: "..returned.."\n")
            stat,factions = pcall(initialiseFactionList)
            log("Initialise factions "..tostring(factions).."\n")
            
             if saveGameID > -1 then
             -- if we already have a save we load it    
                SavTable=readtab("VDM_saves\\"..tostring(saveGameID)..".dat")
                factionsLoad=SavTable[1]
                regionsLoad=SavTable[2]
                for kk,vv in pairs(regionsLoad) do
                    for a,b in pairs(vv) do
                        if a~="factionName" then
                            regtab=regions[kk]
                            regtab[a]=b
                        end 
                    end
                end
                for kk,vv in pairs(factionsLoad) do
                    for a,b in pairs(vv) do
                        factab=factions[kk]
                        factab[a]=b
                    end
                end
                 --коммент
                --perpetuate.filename = perpetuate:getPathForID(saveGameID)
                 --perpetuate:addLoader("Region",Region.loader)
                --perpetuate:addPreLoader("Region",Region.preLoader)
                --perpetuate:addLoader("Faction",Faction.loader)
                --perpetuate:addPreLoader("Faction",Faction.preLoader)
                --sta, err = pcall(perpetuate.load,perpetuate)
                --log("Loader returned: "..tostring(err).."\n")
                --коммент
             end 
             justLoaded = false
         end
    end
    
    
    function conductSave()
        
        -- save out
        oldSavegameList = CampaignUI.EnumerateCampaignSaves(path,"*")
        local missingEntry = findMissingEntry(oldSavegameList,newSavegameList)
        perpetuate.filename = path..missingEntry.FileName           
        local id = perpetuate.saves[perpetuate.filename]
        if id ~= nil then
               perpetuate.usedIDs[id] = false
        end
        perpetuate.saves[perpetuate.filename] = saveGameID
        perpetuate.usedIDs[saveGameID] = true
        log("Writing saves list\n")
        -- save savegame list
        perpetuate:writeSavesList()
        savetab({factions,regions},"VDM_saves\\"..tostring(saveGameID)..".dat")
    
    
        --коммент
        --sta,err = pcall(perpetuate.save,perpetuate)
        --log(tostring(err).."\n")
        --коммент
    end
    
    
    
    
    function TurnEndForSavegames(context)
        oldSavegameList = CampaignUI.EnumerateCampaignSaves(path,"*")
        if justSaved then
               conductSave()
               justSaved = false
        end
    end
    
    
    function UIDestroyedForSavegames(context)   
        if justSaved then
               conductSave()
               justSaved = false
        end
    end
    
    
    function ClickForSavegames(context)
        
        if justSaved then
               conductSave()
               justSaved = false
        end
    end
    
    
    function OnSavingGame(context)
        -- assign the current savegame a new ID because we don't know its name yet
        saveGameID = perpetuate:lowestFreeID()    
        scripting.game_interface:save_value(saveGameID,context)
        newSavegameList = CampaignUI.EnumerateCampaignSaves(path,"*")
         --for k,v in pairs(regions) do
                --perpetuate:addSaver("Region:"..k,v)
         --end
         --for k,v in pairs(factions) do
                --perpetuate:addSaver("Faction:"..k,v)
         --end
         justSaved = true   
    end
    
    
    events.PanelOpenedCampaign[#events.PanelOpenedCampaign+1] = function (context)
        oldSavegameList = CampaignUI.EnumerateCampaignSaves(path,"*")
           if justSaved then         
               conductSave()
           end
           justSaved = false
    end 
    
    
    local function OnLoadingGame(context)
          saveGameID = scripting.game_interface:load_value(-1,context)
        
          justLoaded = true
    
    
          log("Save ID: "..tostring(saveGameID).."\n")
    end   
    
    
    -- Сохранение таблицы или массива в файл
    function savetab(tbl,filename)
       local f,err = io.open(filename,"w")
       if not f then
          return nil,err
       end
       for k,v in pairs(tbl) do
            f:write(tostringtab(v).."\n")   
       end
       f:close()
       return true
    end
    
    
    -- Чтение таблицы из файла в массива или таблицу
    function readtab(filename)
       local f,err = io.open(filename,"r")
       if not f then
          return nil,err
       end
       tbl={}
       ggg=assert(loadstring("return "..f:read()))()  
         table.insert(tbl,ggg)
         ggg=assert(loadstring("return "..f:read()))()
         table.insert(tbl,ggg)
       f:close()
       return tbl
    end
    
    
    -- Преобразование таблицы или массива в текстовое представление в соответствии с синтаксисом языка lua
    function tostringtab( tbl )
       local result, done = {}, {}   
       for k, v in ipairs( tbl ) do      
          table.insert( result, val_to_str( v ) )
          done[ k ] = true      
       end
       
       for k, v in pairs( tbl ) do
          if not done[ k ] and k~="regions" and k~="address" then
             table.insert( result, key_to_str( k ) .. "=" .. val_to_str( v ) )
          end
       end
       return "{" .. table.concat( result, ",") .. "}"
    end
    
    
    
    
    function key_to_str ( k )
       if "string" == type( k ) and string.match( k, "^[_%a][_%a%d]*$" ) then
          return "["..'"'..k.. '"'.."]"
       end
       return "[" .. val_to_str( k ) .. "]"
    end
    
    
    function val_to_str ( v )
       if "string" == type( v ) then   
          v = string.gsub( v, "\n", "\\n" )
          if string.match( string.gsub(v,"[^'\"]",""), '^"+$' ) then
             return "'" .. v .. "'"
          end
          return '"' .. string.gsub(v,'"', '\\"' ) .. '"'
       end 
    
    
       return "table" == type( v ) and tostringtab( v ) or tostring( v )
    end   
    
    
    --------------------------------------------------------------------------------------------------------------------
    -- Add event callbacks
    -- For a list of all events supported create a "documentation" directory in your empire directory, run a debug build of the game and see
    -- the events.txt file
    --------------------------------------------------------------------------------------------------------------------
    scripting.AddEventCallBack("WorldCreated", OnWorldCreated)
    scripting.AddEventCallBack("AdviceIssued", OnAdviceIssued)
    scripting.AddEventCallBack("AdviceDismissed", OnAdviceDismissed)
    scripting.AddEventCallBack("AdviceSuperseded", OnAdviceDismissed)
    scripting.AddEventCallBack("CameraMoverFinished", OnCameraMoverFinished)
    scripting.AddEventCallBack("FactionTurnStart", OnFactionTurnStart)
    scripting.AddEventCallBack("SavingGame", OnSavingGame)
    scripting.AddEventCallBack("LoadingGame", OnLoadingGame)
    scripting.AddEventCallBack("UICreated",UICreatedDoLoad)
    scripting.AddEventCallBack("FactionTurnEnd",TurnEndForSavegames)
    scripting.AddEventCallBack("UIDestroyed",UIDestroyedForSavegames)  
    scripting.AddEventCallBack("ComponentLClickUp",ClickForSavegames)
    end                                                                  
    
    
    val,err = pcall(stupidErrorCatchFunction)
    
    
    vdmlog:write(err.."\n")
    
    
    events.UIDestroyed[#events.UIDestroyed+1] =
    function (context)
        vdmlog:close()
    end
    Last edited by aleheroix; April 23, 2021 at 12:42 PM.

  20. #300

    Default Re: Gameplay options for IMPERIAL DESTROYER

    UPDATE : I have Compiled the changes into a .rar

    Extract both scripting.lua and startpos.esf in your Data\campaigns\Lord_main directory and overwrite.


    If you have VDM installed, use scripting (VDM only).lua instead. Dont forget to remove the "(VDM only)" from the name.


    Changes :
    - All diplomatic options unlocked except Pirates asking to become a patron.
    - Hannover is now a protectorate of Great Britain
    - Courland is now a protectorate of Poland-Lithuania
    - Hetmanate is now a protectorate of Russia
    - Georgia and Dagestan are now protectorates of the Safavids.
    - Barbary Pirates are now a protectorate of the Ottoman Empire

    https://www.mediafire.com/file/qr2oj...rates.rar/file

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •