• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • ✅ The POLL for Hive's Texturing Contest #33 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!

New Game Rules

Status
Not open for further replies.
Level 7
Joined
Jul 25, 2008
Messages
292
Okay, I want to change my game so instead of you loosing when all buildings are destroyed, you loose when all units (and buildings are destroyed)

How do I go about this, if I just remove the original settings it makes you not loose no matter what.
 
Delete that line.

Create a trigger like this:

  • Defeat Conditions
    • Events
      • Unit - A unit dies
    • Conditions
    • Actions
      • Custom script: set bj_wantDestroyGroup = true
      • If (All conditions are true) then do (Then actions) else do (Else actions)
        • If - Conditions
          • (Number of units in (Units owned by (Triggering player))) Equal to 0
        • Then - Actions
          • Player - Defeat (Triggering player)
        • Else - Actions
 
Small mistake Bribe :D
>>Btw you were writing this by your own :p? I guess so, because Player - Defeat (Triggering player) doesn't exist, there is only Game - Defeat (Owner of (Triggering unit)) with the message: Defeat! :S

You pick all units, even dead ones what can cause that player who is suppose to lose will still play. We just need to use proper condition. It's also good to point that it doesn't force last remaining player to win the game.

@Hell_Raider: Remember to always remove Melee - Enforce victory/defeat conditions (for all players) action if you want to set your own conditions, since no matter what you do, if other players have no buildings, the one who has at least one wins.

Credits for orginall trigger to Bribe:
  • My victory conditions
    • Events
      • Unit - A unit Dies
    • Conditions
    • Actions
      • Custom script: set bj_wantDestroyGroup = true
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in (Units owned by (Owner of (Triggering unit)) matching (((Matching unit) is alive) Equal to True))) Equal to 0
        • Then - Actions
          • Game - Defeat (Owner of (Triggering unit)) with the message: Defeat!
          • Set tempforce = (All players matching (((Matching player) slot status) Equal to Play))
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Number of players in tempforce) Equal to 1
            • Then - Actions
              • Game - Victory (Owner of (Killing unit)) (Show dialogs, Show scores)
            • Else - Actions
          • Custom script: call DestroyForce (udg_tempforce)
        • Else - Actions
 
Status
Not open for further replies.
Top