1. Are you planning to upload your awesome spell or system to Hive? Please review the rules here.
    Dismiss Notice
  2. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  3. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still havn't received your rank award? Then please contact the administration.
    Dismiss Notice
  4. Travel to distant realms and encounter scenes unknown to the common folk. The Greatest of Adventures is upon us with the 8th Cinematic Contest. Join in on a fun ride.
    Dismiss Notice
  5. The 18th Icon Contest is ON! Choose any ingame unit and give him/her Hero abilities. Good luck to all.
    Dismiss Notice
  6. The Secrets of Warcraft 3 have revealed interesting works. The RESULTS for Abelhawk's Mini-Mapping Contest #15 have come out!
    Dismiss Notice
  7. Contestants are to create a scene set in the Stone Age. Come and see what you can come up with. We wish you the best of luck!
    Dismiss Notice
  8. Colour outside the lines! Techtree Contest #13 is a go. The contest is optionally paired.
    Dismiss Notice
  9. Night Rider gained several songs for his journey. The poll for the 12th Music Contest has started. Check it out!
    Dismiss Notice
  10. Greetings cerebrates, our Swarm needs new spawners that will have numerous children. Join the HIVE's 31st Modeling Contest - Spawners and Spawned! The contest is optionally paired.
    Dismiss Notice
  11. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

DPS Meter 2.11

Submitted by Shunpomaster
This bundle is marked as approved. It works and satisfies the submission rules.
DPS Meter: A system to check the Damage Per Seconds of your units.

Features:
  • DPS of one or multiple units of the same player.
  • Save the highest DPS, and can be reset to 0.
This is mui so multiple units with summons can damage at the same time.
This system is good to test the dps and make balancing easier.




Triggers:

  • DPS Set
  • DPS Set
    • Events
      • Game - DamageEvent becomes Equal to 1.00
    • Conditions
    • Actions
      • Set DPS_Counter[(Player number of (Owner of DamageEventSource))] = 10
      • Set DPS_TotalDamage[(Player number of (Owner of DamageEventSource))] = (DPS_TotalDamage[(Player number of (Owner of DamageEventSource))] + DamageEventAmount)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DPS_RunningCheck[(Player number of (Owner of DamageEventSource))] Equal to False
        • Then - Actions
          • Set DPS_RunningCheck[(Player number of (Owner of DamageEventSource))] = True
          • Set DPS_Index = (DPS_Index + 1)
          • Set DPS_Unit[DPS_Index] = DamageEventSource
          • Set DPS_Player[DPS_Index] = (Owner of DPS_Unit[DPS_Index])
          • Unit Group - Add DPS_Unit[DPS_Index] to DPS_Group
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • DPS_Index Equal to 1
            • Then - Actions
              • Trigger - Turn on DPS Timer <gen>
            • Else - Actions
        • Else - Actions




  • DPS Timer
  • DPS Timer
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • -------- ------------------------ --------
      • For each (Integer DPS_Loop) from 1 to DPS_Index, do (Actions)
        • Loop - Actions
          • -------- ------------------------ --------
          • -------- Check if still damaging or not --------
          • Set DPS_Timer3[DPS_Loop] = (DPS_Timer3[DPS_Loop] + 1)
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • DPS_Counter[(Player number of DPS_Player[DPS_Loop])] Equal to 10
            • Then - Actions
              • Set DPS_Timer1[DPS_Loop] = (DPS_Timer1[DPS_Loop] + 1)
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: (|c006969FFTimer (Seconds)|r : + (String(DPS_Timer3[DPS_Loop])))
            • Else - Actions
              • Set DPS_Timer2[DPS_Loop] = (DPS_Timer2[DPS_Loop] + 1)
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: (|c00FF0000Timer (Seconds)|r : + (String(DPS_Timer3[DPS_Loop])))
          • -------- ------------------------ --------
          • Set DPS_Counter[(Player number of DPS_Player[DPS_Loop])] = (DPS_Counter[(Player number of DPS_Player[DPS_Loop])] - 1)
          • -------- If stopped than damaged again before time out --------
          • -------- ------------------------ --------
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • DPS_Timer2[DPS_Loop] Greater than 0
              • DPS_Counter[(Player number of DPS_Player[DPS_Loop])] Greater than or equal to 9
            • Then - Actions
              • Set DPS_Timer1[DPS_Loop] = (DPS_Timer1[DPS_Loop] + DPS_Timer2[DPS_Loop])
              • Set DPS_Timer2[DPS_Loop] = 0
            • Else - Actions
          • -------- DPS End --------
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • DPS_Counter[(Player number of DPS_Player[DPS_Loop])] Less than or equal to 0
            • Then - Actions
              • -------- ------------------------ --------
              • -------- Check if that is the highest DPS for owner of unit --------
              • -------- For somereason it worked when i made this integer even tho it is useless like this --------
              • Set DPS_Current[DPS_Loop] = (DPS_TotalDamage[(Player number of DPS_Player[DPS_Loop])] / (Real(DPS_Timer1[DPS_Loop])))
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • DPS_Current[DPS_Loop] Greater than or equal to DPS_Highest[(Player number of DPS_Player[DPS_Loop])]
                • Then - Actions
                  • Set DPS_HighestTimer[(Player number of DPS_Player[DPS_Loop])] = DPS_Timer1[DPS_Loop]
                  • Set DPS_Highest[(Player number of DPS_Player[DPS_Loop])] = DPS_Current[DPS_Loop]
                • Else - Actions
                  • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: -------------------...
                  • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: -------------------...
                  • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) for 25.00 seconds the text: (|c0000FF00Your Highest DPS|r : + (String(DPS_Highest[(Player number of DPS_Player[DPS_Loop])])))
                  • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) for 25.00 seconds the text: (|c0000FF00Your Highest DPS Timer|r : + (String(DPS_HighestTimer[(Player number of DPS_Player[DPS_Loop])])))
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: -------------------...
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: -------------------...
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) for 25.00 seconds the text: (|c0096FF96Current DPS|r : + (String(DPS_Current[DPS_Loop])))
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: -------------------...
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) for 25.00 seconds the text: (|c00FF7F00Total Damage|r : + (String((Integer(DPS_TotalDamage[(Player number of DPS_Player[DPS_Loop])])))))
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: -------------------...
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) for 25.00 seconds the text: (|c006969FFTotal Time|r : + (String(DPS_Timer1[DPS_Loop])))
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: -------------------...
              • Game - Display to (All players matching (DPS_Player[DPS_Loop] Equal to (Matching player))) the text: -------------------...
              • -------- End --------
              • Set DPS_Timer1[DPS_Loop] = 0
              • Set DPS_Timer2[DPS_Loop] = 0
              • Set DPS_Timer3[DPS_Loop] = 0
              • Set DPS_Timer1[DPS_Loop] = DPS_Timer1[DPS_Index]
              • Set DPS_Timer2[DPS_Loop] = DPS_Timer2[DPS_Index]
              • Set DPS_Timer3[DPS_Loop] = DPS_Timer3[DPS_Index]
              • Set DPS_Timer1[DPS_Index] = 0
              • Set DPS_Timer2[DPS_Index] = 0
              • Set DPS_Timer3[DPS_Index] = 0
              • Set DPS_TotalDamage[(Player number of DPS_Player[DPS_Loop])] = 0.00
              • Unit Group - Remove DPS_Unit[DPS_Loop] from DPS_Group
              • Set DPS_RunningCheck[(Player number of DPS_Player[DPS_Loop])] = False
              • Set DPS_Unit[DPS_Loop] = DPS_Unit[DPS_Index]
              • Set DPS_Player[DPS_Loop] = DPS_Player[DPS_Index]
              • Set DPS_Index = (DPS_Index - 1)
              • Set DPS_Loop = (DPS_Loop - 1)
              • -------- ------------------------ --------
              • -------- Trigger off --------
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • DPS_Index Equal to 0
                • Then - Actions
                  • Trigger - Turn off (This trigger)
                • Else - Actions
            • Else - Actions




Changes:

DPS Meter 1.00
  • Fixed some explanation in the map.
  • Added Timer 3 which will be for the texts, and made it to change color when countdown start. Now it look much better and easier to understand.
DPS Meter 1.10
  • Changed the DPS to show as Real numbers instead of Integer because it was not accurate as integer.
  • Fixed the damage accumulated to show all reduced damage from any type of damage reduction. It was not calculating Real numbers very well.
DPS Meter 1.20
  • Changed Highest DPS to show as Real Numbers instead of Integer.
  • Added Highest Timer to save the timer for the highest DPS.
  • Fixed some text.

DPS Meter 2.00
  • Fixed timers problem that prevent this system from being Mui.

DPS Meter 2.10

  • Reduced Count time to 5 sec (10 sec was too long)
  • Using new damage engine in the map which require wc3 1.31 but the system it self can work with older version of wc3 if olden version of damage engine is available
  • Added 2 new commands
  1. -ton Turn DPS count text on
  2. -toff Turn DPS count text off
DPS Meter 2.11

  • Reverted back to older version of damage engine for now since it work fine either way. If already got latest version of damage engine just copy DPS Meter and (Optional) Commands.









How to copy:



  • Turn On "automaticly create unknown variables".
  • Copy Damage Engine to your map.
  • Copy DPS Meter to your map.
  • Copy Commands (Optional).
Here is a list of the commands and what for:

  • -reset dps : Reset highest DPS. Some times DPS end after 1 hit, then that one hit will be the highest dps, and it will be impossible to out dps one hit unless unit damage increase a lot. this command reset it to 0.
  • -ton Turn DPS count text on
  • -toff Turn DPS Count text off
  • -stop dps : When no longer dealing damage there is a 10 seconds count down, with this command it will end immediately to get your result and/or start again.
  • -dps : show the highest dps.
  • -clear : clear all texts.

Credits:

Thanks to Bribe's Damage Engine System I managed to make this.


Keywords:

dps, dps system, system, damage per second
Previews
Contents

DPS Meter 2.00 (Map)

Reviews
KILLCIDE
Given this is meant more for the map developer, I can see some functionality with this in RPGs where players can test out their damage with weapons or whatever. For that reason, I won't be too picky with the system. You also have a lot of...
  1. Sverkerman

    Sverkerman

    Joined:
    Feb 28, 2010
    Messages:
    1,282
    Resources:
    5
    Maps:
    5
    Resources:
    5
    I've decided to use this system in Bosses of Warcraft [24 Player ORPG]
    Great DPS system, you can alter it easily if you know a bit of GUI to do exactly what you want it to do. I'm also using this system as a combat-check. Very handy +4 rep 5/5 well done!
     
  2. Shunpomaster

    Shunpomaster

    Joined:
    Jun 13, 2017
    Messages:
    83
    Resources:
    1
    Spells:
    1
    Resources:
    1
    Thank you for using it. I will update it whenever I have time :)
     
  3. KILLCIDE

    KILLCIDE

    Administrator

    Joined:
    Jul 22, 2015
    Messages:
    3,494
    Resources:
    20
    Models:
    2
    Icons:
    10
    Spells:
    7
    Tutorials:
    1
    Resources:
    20
    Given this is meant more for the map developer, I can see some functionality with this in RPGs where players can test out their damage with weapons or whatever. For that reason, I won't be too picky with the system. You also have a lot of documentation in the triggers, so its easy to modify if need be.

    Needs Fixed

    • Nothing

    Suggestions

    • Make the 1.00 periodic timer configurable.
    • Make the display timer for messages configurable.
    • Having the messages display locally to the player would be better imo.
    • Make it so that the player can turn the DPS meter on/off ingame. Maybe you should also consider making it so that players can turn the meter on/off locally?
    • Hashtables would have been a better approach. Alternatively, you could have used the custom values as an index rather than using a custom index system.

    Status


    Approved