• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Pick game mode and winning conditions

Status
Not open for further replies.
Level 4
Joined
Apr 4, 2009
Messages
65
Well... I have trouble putting everything together.

So far I have 2 dialogs:

1 is choosing if bounty is on or OFF, seems to work.


dialog 2 is choosing if it's 6V6 or FFA, that's where it does wrong.

After you pick 6v6 or FFA, it should spawn the "summoner" unit for everyone who is playing by turning on a trigger.

Also, it should turn off triggers and set winning conditions ( didnt made that yet, I seem to fail at it)



Anyway this is what I have:

helpwithscripts.png


Yeah I know many memory leaks.
 
Level 4
Joined
Apr 4, 2009
Messages
65
There is a new thing I need:

A winning condition that gets created when you press a dialog button.

For example:

when you press "FFA", if all summoners die ( from every player except yours ) you win the game.

But only for people who "play"

And those who leave, dont need to be killed...



Anyone idea?
 
Level 4
Joined
Jul 1, 2009
Messages
65
You make multiple win conditions with triggers... when you make the trigger, turn it off and when the dialog button is clicked, make an action to turn on the right win condition trigger.

edit: i was making a small concept script for you....but my power cut off ......
 
Last edited:
Level 4
Joined
Jul 1, 2009
Messages
65
kk this could use some real optimizing but here you go

  • FFA
    • Events
      • Unit - A unit Dies
    • Conditions
    • Actions
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked player) Food used) Equal to 0
              • ((Picked player) slot status) Equal to Is playing
            • Then - Actions
              • Game - Defeat (Picked player) with the message: Defeat!
            • Else - Actions
      • Trigger - Run check <gen> (ignoring conditions)
  • check
    • Events
    • Conditions
    • Actions
      • -------- ALL PLAYERS --------
      • Set Players = (All players matching ((((Matching player) controller) Equal to User) and ((((Matching player) slot status) Equal to Is playing) and (((Matching player) Food used) Greater than 0))))
      • Set PlayersCount = (Number of players in Players)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • PlayersCount Less than or equal to 1
        • Then - Actions
          • Player Group - Pick every player in Players and do (Game - Victory (Picked player) (Show dialogs, Show scores))
        • Else - Actions
This is just one you would have too make one for the other modes also...but you would turn FFA initially off
 
Level 4
Joined
Apr 4, 2009
Messages
65
Already have the 6v6 mode :p that ones easy as the teams are permanent.

FFA is just every man for theirself!



Aha, food check thingy! Thank you for helping me out!

+repped and credits for helping with FFA triggers
 
Level 4
Joined
Apr 4, 2009
Messages
65
well actually I didnt fix that bug...

But I guess I found the bug. the "user" thingy. If I test it, I am a user right? the other guy is a computer... Thats why the insant victory I think : D



I will test it today ( if the person who wants to test comes online ) :p
 
Status
Not open for further replies.
Top