Results 1 to 10 of 10

Thread: Fog of War lift script

  1. #1

    Default Fog of War lift script

    Is there any way of lifting the fog of war on the campaign map through scripting? The senate missions can reveal a settlement, so perhaps there is a way of scripting this?

  2. #2
    Not affiliated with Red Dwarf. Member Ianofsmeg16's Avatar
    Join Date
    Jan 2005
    Location
    Home of Palm trees, cats with no tails, three-legged men, fairies...and more german bikers than germany
    Posts
    1,996

    Default Re: Fog of War lift script

    press the ` button (above Tab) and it'll bring you into rome_shell, from there type in Toggle_fow then the fow should be lifted until you type it again. N.B this is on the campaign map, i dont know where the script for it is, this method seems easier.
    Hope this helps
    When I was a child
    I caught a fleeting glimpse
    Out of the corner of my eye.
    I turned to look but it was gone
    I cannot put my finger on it now
    The child is grown,
    The dream is gone.
    I have become comfortably numb...

    Proud Supporter of the Gahzette

  3. #3

    Default Re: Fog of War lift script

    There's also a reveal_tile command, which is probably what the Senate are using. toggle_fow through RomeShell is a lot better way of just seeing the whole map.
    Epistolary Richard's modding Rules of Cool
    Cool modders make their mods with the :mod command line switch
    If they don't, then Cool mod-users use the Mod Enabler (JSGME)
    Cool modders use show_err
    Cool modders use the tutorials database Cool modders check out the Welcome to the Modding Forums! thread Cool modders keep backups Cool modders help each other out

  4. #4

    Default Re: Fog of War lift script

    Thanks for the help, what I am trying to do is to reveal the map just around a certain point...

    A player needs to be able to 'see' a volcano for it to erupt. Because of the change in scale on the Sicily campaign map, it is very unlikely that a player will have units near MT Etna when it erupts, so the volcano effect is lost. Perhaps if I could use a script to reveal the volcano for the player (but not the rest of the map), the player would be able to see it erupting...

  5. #5

    Default Re: Fog of War lift script

    Yes, in that case you'll want the reveal_tile script command. It's been used in vanilla so we know it works:
    Code:
    reveal_tile		Sample use: reveal_tile 25, 43
    Unless you're incorporating a background script then you'll need to activate it through an event script. If Mt Etna is erupting at a set date each campaign then this would be quite straightforward.

    These entries would go in your export_descr_advice:
    This would be your trigger:
    Code:
     ;------------------------------------------
    Trigger 3000_Etna_erupts_Trigger
        WhenToTest FactionTurnStart
    
        Condition FactionIsLocal
                and I_TurnNumber = 1 ; insert turn number here 
    
        AdviceThread Etna_erupts_Thread  0
    Here's your advice thread, also in eda.
    Code:
     ;------------------------------------------
    AdviceThread Etna_erupts_Thread
        GameArea Campaign
    
        Item Etna_erupts_Text_01
            Uninhibitable
            Verbosity  0 
            Threshold  1 
            Attitude Normal
            Presentation Default
            Title Etna_erupts_Text_01_Title
            Script scripts\show_me\etna.txt
            Text Etna_erupts_Text_01_Text1
    Add the following to export_descr_advice_enums
    Code:
    Etna_erupts_Text_01_Title
    Etna_erupts_Text_01_Text1
    In your text\export_advice
    Code:
    ¬-------------------
    
    {Etna_erupts_Text_01_Title}	Etna erupts!
    
    {Etna_erupts_Text_01_Text1}
    Click on the show me how button to see it.
    Then create a new file in \scripts\show_me\ called etna
    Code:
    script
    snap_strat_camera 25,43
    reveal_tile 25, 43
    end_script
    If you want to know more about scripts and their terminology, then read this.
    Last edited by Epistolary Richard; 06-11-2005 at 12:21.
    Epistolary Richard's modding Rules of Cool
    Cool modders make their mods with the :mod command line switch
    If they don't, then Cool mod-users use the Mod Enabler (JSGME)
    Cool modders use show_err
    Cool modders use the tutorials database Cool modders check out the Welcome to the Modding Forums! thread Cool modders keep backups Cool modders help each other out

  6. #6

    Default Re: Fog of War lift script

    Hmmm.... actually the reveal_tile command doesn't seem to do much of anything at all....

    Right, there's another way of doing this, but this is far simpler, so replace the script with this:
    Code:
    script
    inhibit_camera_input true
    zoom_strat_camera 0.8
    snap_strat_camera 25,43
    console_command toggle_fow
    wait 5
    console_command toggle_fow
    inhibit_camera_input false
    end_script
    This works, but allows the player to see the whole map on the minimap for five seconds. If this okay for you, then great, if not there's another way.
    Epistolary Richard's modding Rules of Cool
    Cool modders make their mods with the :mod command line switch
    If they don't, then Cool mod-users use the Mod Enabler (JSGME)
    Cool modders use show_err
    Cool modders use the tutorials database Cool modders check out the Welcome to the Modding Forums! thread Cool modders keep backups Cool modders help each other out

  7. #7
    Shaidar Haran Senior Member SAM Site Champion Myrddraal's Avatar
    Join Date
    Feb 2004
    Location
    UK
    Posts
    5,752

    Default Re: Fog of War lift script

    reveal tile does work I believe, it is used in sons of mars for sure...

  8. #8
    Shaidar Haran Senior Member SAM Site Champion Myrddraal's Avatar
    Join Date
    Feb 2004
    Location
    UK
    Posts
    5,752

    Default Re: Fog of War lift script

    Code:
    	snap_strat_camera 21, 54
    
    	reveal_tile 8, 57
    That comes straight from the suns of mars tutorial.

    R u sure you got the right tile when testing...

  9. #9

    Default Re: Fog of War lift script

    Yes, it's in the prologue, which is why I assumed it worked. But I tried it out and snapped the camera to the same position but nothing was revealed. I even put it in a loop so it would continue to fire while the advisor was visible, but nothing changed. Maybe I mistyped the parameters though, if anyone gets it working then let us know.
    Epistolary Richard's modding Rules of Cool
    Cool modders make their mods with the :mod command line switch
    If they don't, then Cool mod-users use the Mod Enabler (JSGME)
    Cool modders use show_err
    Cool modders use the tutorials database Cool modders check out the Welcome to the Modding Forums! thread Cool modders keep backups Cool modders help each other out

  10. #10

    Default Re: Fog of War lift script

    Thanks for the help guys I'll try those

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Single Sign On provided by vBSSO