Results 1 to 4 of 4

Thread: End Trigger if player dies without all objectives finished ?

  1. #1

    End Trigger if player dies without all objectives finished ?

    I have a mission with Objectives 1, 2 and 3

    I want mission to end if player dies but not all objectives accomplished. The twist is the player is supposed to die in last objective so if dies after accomplishing all objectives he wins and if he dies with one objective not finsihed he loses. Any tips are appreciated.
    Captain Bravo
    One of the serious problems in planning the fight against American doctrine, is that the Americans do not read their manuals, nor do they feel any obligation to follow their doctrine"
    From a Russian General's Notebook

    Join Bravo Company
    A highly trained unit run by an ex cook, a hooker and an old pensioner, so expect the best!
    http://forums.bistudio.com/showthread.php?t=80906

  2. #2
    Loose trigger condition if dead and not all completed:
    Code:
    !alive player AND (!obj1 OR !obj2 OR !obj3)
    Make sure you have set obj1,2,3 to false in mission start, also set each of them to true once a objective is completed.

    Now for all completed and dead, im sure you can figure it out now:
    Spoiler:
    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.

  3. #3
    First Lieutenant galzohar's Avatar
    Join Date
    Jun 3 2009
    Location
    Ramat Hasharon, Israel
    Posts
    5,321
    In MP, if all playable units are dead, mission ends immediately (or pretty much immediately), and your scripts won't even run.

    In SP, if the player dies mission is over as well, and again your scripts won't even run. You won't even get a debriefing screen when dying in SP.
    You don't mess with the Zohar!
    YouTube channel: http://www.youtube.com/user/galzohar
    Steam: http://steamcommunity.com/id/galzohar
    ArmA Israel: http://www.arma-il.info
    Check out and support upcoming Ground Branch: http://www.groundbranch.com/

  4. #4
    Master Sergeant CaptainBravo's Avatar
    Join Date
    Nov 24 2005
    Location
    USA-UK
    Posts
    730
    Author of the Thread
    Thanks Demonized for the script, much appreciated.
    @galzohar: you are right the mission will end right away before script is even run. My way of getting around it, is to creat a "playable" unit somewhere on map so if all players die, player can switch to the last remaining playable unit for mission end. Not sure if there is a better way of doing it, but this seems to work.

Similar Threads

  1. End mission when player dies
    By Janat in forum ARMA 2 & OA : MISSIONS - Editing & Scripting
    Replies: 11
    Last Post: Dec 8 2010, 13:54
  2. MP player names and end trigger
    By rrpatch in forum ARMA 2 & OA : MISSIONS - Editing & Scripting
    Replies: 1
    Last Post: Aug 17 2010, 01:14
  3. End trigger after all objectives met
    By Manzilla in forum ARMA 2 & OA : MISSIONS - Editing & Scripting
    Replies: 1
    Last Post: Jul 10 2009, 17:26
  4. End Mission When Specific Dies
    By pebcak in forum ARMA - MISSION EDITING & SCRIPTING
    Replies: 2
    Last Post: Mar 17 2007, 12:52
  5. How do i  end mission after all enemy dies
    By borderswill in forum OFP : MISSION EDITING & SCRIPTING
    Replies: 4
    Last Post: Oct 22 2003, 12:13

Posting Permissions

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