Results 1 to 8 of 8

Thread: Dual Artillery.

  1. #1

    Dual Artillery.

    Hello everyone,
    No amount of searching, wikireading or general exploring has gotten me any closer to a solution so im just gonna post here and ask.

    I have a little testing grounds mission where i am just prodding around to get better at the editor, and i am trying to fire off a MLRS barrage at a target and then illuminate it with a mortar barrage, pref at about the same time.
    I have physical batteries on the map that both do these things coordinated through triggers and the SOM Module, however i can only do one of them and then the other is locked out.

    Is there a way around this? Possibly putting the mortar barrage in a different category or something? I could just refill the support with a script, but the thing is that i want just one mortar barrage and one MLRS barrage, not multiple.

    Hope this makes some sense.

  2. #2
    I think you can re-add support with a script, but in your case I would just drop the som module alltogether. I would just send both batterys a fire mission. You can find the code on the arty module wiki

    It can be done in just a trigger. When I get home I can post an example if needed.

  3. #3
    Warrant Officer Demonized's Avatar
    Join Date
    Nov 16 2010
    Location
    Back from afk 2013
    Posts
    2,614
    maybe just do it outside SOM module, with a seperate radio trigger or a addaction.
    My scripts:
    Spoiler:

    what to do when posting any kind of code dammit!!

    Any new mission editor or scripter in Arma2 should have read Mr Murrays Editing Guide Deluxe at least once, it still applies for A2 even though it was made for Armed Assault.

  4. #4
    Quote Originally Posted by Riouken View Post
    I think you can re-add support with a script, but in your case I would just drop the som module alltogether. I would just send both batterys a fire mission. You can find the code on the arty module wiki

    It can be done in just a trigger. When I get home I can post an example if needed.
    That would be great Riouken, i'm still a bit unclear on it all and people who google their way to this thread might also benefit from it.

  5. #5
    Quote Originally Posted by Riouken View Post
    I think you can re-add support with a script, but in your case I would just drop the som module alltogether. I would just send both batterys a fire mission. You can find the code on the arty module wiki

    It can be done in just a trigger. When I get home I can post an example if needed.
    That would be nice Riouken, would be nice to see it in action and maybe it would help out anyone who googles themselves to this page in the future.

  6. #6
    Most of this code is in the arty wiki just check it out or ask questions if your not sure about anything.


    Just execute this on the server and provide the names of your arty battery's to the corresponding(_mymlrsBattery,_myd30Battery).


    Code:
    // Create the Fire mission templates
    _heTemplate = ["IMMEDIATE", "HE", 0, 15];
    _illumTemplate = ["IMMEDIATE", “ILLUM”, 10, 15];
    
    // Get pos of the target above sea level.
    _targetPos = getPosASL _targetUnit;
    
    // Execute the fire missions.
    [_mymlrsBattery, _targetPos, _heTemplate] call BIS_ARTY_F_ExecuteTemplateMission;
    
    [_myd30Battery, _targetPos, _illumTemplate] call BIS_ARTY_F_ExecuteTemplateMission;

  7. #7
    That just gives me a "Local variable in global space" error, in front of _targetpos and _heTemplate at the "Execute firemissions" paragraph, im sure there is something very basic i am missing here.

    Edit: Figured it out, the underscore meant that it was up to me to name those variables and then i had to add a radiotrigger to activate it, thank you!
    Last edited by Coinkidoink; Jun 25 2011 at 20:01.

  8. #8
    @Coinkidoink

    Arma will not accept local variables in triggers,and init fields.


    Code:
    _MyVariable = "I now understand local/global variables"; //  <---- This is a local Variable
    MyVariable = "I now understand local/global variables"; //    <---- This is a global Variable

Posting Permissions

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