• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • Create a faction for Warcraft 3 and enter Hive's 19th Techtree Contest: Co-Op Commanders! Click here to enter!
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 21st Texturing Contest: Upgrade is now concluded, time to vote for your favourite set of icons! Click here to vote!

Action not working why?

Status
Not open for further replies.
Level 14
Joined
Mar 4, 2009
Messages
1,156
  • 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) Not equal to Player 11 (Dark Green)
          • (Picked player) Not equal to Player 12 (Brown)
        • Then - Actions
          • Set PGROUP = (Player group((Picked player)))
          • Leaderboard - Create a leaderboard for PGROUP titled Allowed feeding 100
          • Leaderboard - Add (Picked player) to (Last created leaderboard) with label Your feeding and value 0
          • Custom script: call DestroyForce(udg_PGROUP)
        • Else - Actions
every player (accept 11 and 12) should have Leaderboard like this

TITLE - Allowed Feeding 100
LABEL - Your Feeding 0
 
I believe that converting a player to a player group doesn't leak, so there is no need to remove it.
If you remove the "Set PGROUP = ..." and "DestroyForce ..." it should work.

otherwise, you could try this:
  • Actions
    • For each (Integer i) from 1 to 10, do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • ((Player(i)) slot status) Equal to Is playing
          • Then - Actions
            • Leaderboard - Create a leaderboard for (Player group((Picked player))) titled LOL
            • Leaderboard - Add (Picked player) to (Last created leaderboard) with label [label] and value [value]
          • Else - Actions
 
Level 14
Joined
Mar 4, 2009
Messages
1,156
i think this could be the only possible way coz other actions are "to fast"

  • CL
    • Events
      • Time - Elapsed game time is 1.00 seconds
    • Conditions
    • Actions
      • Game - Display to (All players) the text: (String((Evaluation count of (This trigger)))) (NOT NEEDED)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ID[(Evaluation count of (This trigger))] Equal to Human
        • Then - Actions
          • Set PGROUP = (Player group((Player((Evaluation count of (This trigger))))))
          • Leaderboard - Create a leaderboard for PGROUP titled Allowed feeding ...
          • Custom script: call DestroyForce(udg_PGROUP)
          • Leaderboard - Add (Player((Evaluation count of (This trigger)))) to (Last created leaderboard) with label Your feeding and value 0
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Evaluation count of (This trigger)) Equal to 1
        • Then - Actions
          • Trigger - Add to (This trigger) the event (Time - Every 0.01 seconds of game time)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Evaluation count of (This trigger)) Equal to 10
            • Then - Actions
              • Custom script: call DestroyTrigger( GetTriggeringTrigger() )
            • Else - Actions
 
i think this could be the only possible way coz other actions are "to fast"

  • CL
    • Events
      • Time - Elapsed game time is 1.00 seconds
    • Conditions
    • Actions
      • Game - Display to (All players) the text: (String((Evaluation count of (This trigger)))) (NOT NEEDED)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ID[(Evaluation count of (This trigger))] Equal to Human
        • Then - Actions
          • Set PGROUP = (Player group((Player((Evaluation count of (This trigger))))))
          • Leaderboard - Create a leaderboard for PGROUP titled Allowed feeding ...
          • Custom script: call DestroyForce(udg_PGROUP)
          • Leaderboard - Add (Player((Evaluation count of (This trigger)))) to (Last created leaderboard) with label Your feeding and value 0
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Evaluation count of (This trigger)) Equal to 1
        • Then - Actions
          • Trigger - Add to (This trigger) the event (Time - Every 0.01 seconds of game time)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Evaluation count of (This trigger)) Equal to 10
            • Then - Actions
              • Custom script: call DestroyTrigger( GetTriggeringTrigger() )
            • Else - Actions

Woah, what? I just tested my trigger and it works perfectly o_O
No need for something like this.
 
Level 14
Joined
Mar 4, 2009
Messages
1,156
nwm,my trigger works but i have action that destroys a leaderboard for player 2 but somehow it destroys leaderborad for every player

i used hide leaderboard instead destroy and now its working

but why is that happening when i do

some unit dies
-destroy leaderboard for owned of unit (dying unit)

and it destroy leaderboard to all players ... -.-
 
Last edited:
Status
Not open for further replies.
Top