+ Reply to Thread
Page 1 of 2 1 2 LastLast
Results 1 to 15 of 17

Thread: simple meter... the rebirth... work in progress

  1. #1
    Telaran
    Join Date
    Apr 2011
    Posts
    64

    Default simple meter... the rebirth... work in progress

    I have contacted the original creator of simple meter and have confirmed he is no longer working on it or subscribing to Rift.

    He is happy for me to work on it so I will try and get a new release out when I can. I have a background in C/C++, SAS Oracle and .net so have picked LUA up and learn as I go.

    I have made major changes but it's still built basically on the original code.

    *** My main aim is to make it a lot more efficient and minimize system impact as much as possible. In doing so I will eventually create an options panel that will decide how garbage collections are done for "old" units and other options to try and cater for most people.

    For example with the current one if you kill say... 1000 of a single mob you will have 1000 units in your view and if you change to the view all option... disaster. As noted on a few forums... the list just grows and grows and will eventually chew cpu, memory and fps.

    There is an option to reset your session but it wipes all data and from what I have discovered not many people know about.

    This garbage collection does the following and will later be user tuned.
    a) Every time a unit dies it is flagged as potential garbage collection. After 5 seconds (to allow for no other events for this unit to come in) the unit list is searched for another unit with the same name that is also dead or died more than once. If it finds one this record is merged and the record that died is removed.

    What this means is if you kill 1000 units of ... say 5 different mobs then you will only have 5 records and not 1000+.

    Units that are alive and still fighting etc are treated the same... fun just begins when they die.
    b) Occasionally old units are cleared out.... this basically means if i kill 1000 in droughtlands then move to ... say stillmoor and kill another 1000 then after a while all the droughtlands mobs will be removed.

    Any mob that is not dead... but not had any event for > 2 minutes is removed. An example of these is where you agro a mob on your mount and keep running. It records damage and is added but will never get a normal garbage collection.

    Any mob that is dead but no events for 10 minutes is removed.

    However... all the player data is kept so after a day of farming you could in theory have no mobs in the enemy panel but the entire days stats to look at.
    People with lower end pc's will want a more aggressive option for keeping old data at a minimum while raid leaders might elect to keep it around a bit longer. The main thing is... it should never grind you session to a halt or become unstable through bad data retention policy.

    I'm still working on the screen layout for it and will eventually make it so it can have custom skins. That way people can have a smaller or larger profile depending on their needs.

    Example below.

    http://i1066.photobucket.com/albums/...67/screen1.jpg

  2. #2
    Champion Lorandii's Avatar
    Join Date
    Jun 2011
    Posts
    516

    Default

    I like your layout preview. Without being able to see your code, I can't offer any suggestions, except that if you are truly concerned about speed, try these two:
    1. Upvalue the APIs. At the top of your file, type local _G = getfenv(0) new line local Inspect.Unit.Detail = _G.Inspect.Unit.Detail new line local Inspect.System.Secure = _G.Inspect.System.Secure etc.
    2. Use LibUnitChange to see if any UnitIDs are no longer valid. See the new ZorbasBuffBars as an example.
    The first trades memory to gain CPU via caching, and the second should be self explanatory.

  3. #3
    Telaran
    Join Date
    Apr 2011
    Posts
    64

    Default

    Quote Originally Posted by Lorandii View Post
    I like your layout preview. Without being able to see your code, I can't offer any suggestions, except that if you are truly concerned about speed, try these two:
    1. Upvalue the APIs. At the top of your file, type local _G = getfenv(0) new line local Inspect.Unit.Detail = _G.Inspect.Unit.Detail new line local Inspect.System.Secure = _G.Inspect.System.Secure etc.
    2. Use LibUnitChange to see if any UnitIDs are no longer valid. See the new ZorbasBuffBars as an example.
    The first trades memory to gain CPU via caching, and the second should be self explanatory.

    OK.. thanks for that... it all adds up.

  4. #4
    Champion
    Join Date
    Sep 2010
    Posts
    572

    Default

    Nice, can't wait to see what you'll come up with.
    Altruistic Valorians - Faeblight -- *RETIRED*
    Guild Leader
    60 Warrior Main Tank
    FT 4/4 - EE 4/5 - TotDQ 4/4

  5. #5
    RIFT Guide Writer Redcruxs's Avatar
    Join Date
    Jan 2011
    Posts
    3,935

    Default

    nice, glad to see someone working on simplemeter again. i really enjoyed it when i used to use it

    2 reasons i stopped using it were:

    1) accuracy : it didn't start parsing until i hit a mob, which made it useless for raids (this may have already been fixed) and it would stop if i died

    2) it didn't show enough breakdowns. i like to have a damage taken breakdown showing dodge %/parry %/block %/blocked amount ect. in addition to the normal damage done breakdowns (crit%/ ability %/ etc.)


    idk its been a while since i used simple meter so i don't know if these have already been addressed or not. if not then its at least some ideas to work on

    keep it up

  6. #6
    Plane Walker Kreiri's Avatar
    Join Date
    Feb 2011
    Posts
    402

    Default

    Quote Originally Posted by Lorandii View Post
    1. Upvalue the APIs. At the top of your file, type local _G = getfenv(0) new line local Inspect.Unit.Detail = _G.Inspect.Unit.Detail new line local Inspect.System.Secure = _G.Inspect.System.Secure etc.
    Wouldn't it complain that local Inspect is nil?
    Feminism is the radical notion that women are people.

  7. #7
    Telaran
    Join Date
    Apr 2011
    Posts
    64

    Default

    Quote Originally Posted by Redcruxs View Post
    nice, glad to see someone working on simplemeter again. i really enjoyed it when i used to use it

    2 reasons i stopped using it were:

    1) accuracy : it didn't start parsing until i hit a mob, which made it useless for raids (this may have already been fixed) and it would stop if i died

    2) it didn't show enough breakdowns. i like to have a damage taken breakdown showing dodge %/parry %/block %/blocked amount ect. in addition to the normal damage done breakdowns (crit%/ ability %/ etc.)


    idk its been a while since i used simple meter so i don't know if these have already been addressed or not. if not then its at least some ideas to work on

    keep it up
    Current version I have allows you have manual mode where you can turn recording on/off which overrides the recording just when combat starts/ends.

    I also record crits and include that in the breakdown. Spend 10 mins on the dummy and presto... get a breakdown of all your damage abilities with %damage and for each ability the %crit... it also keeps track of the min max and average of each damaging ability.

    I have just finished the option for "personal mode" which only records stuff where you are either the target or caster. This will mean no more flooding it in ourdoor events where 10000 mobs are being killed by 10000 people and flooding you with 100000000 event messages.

  8. #8
    Rift Chaser
    Join Date
    Oct 2011
    Posts
    398

    Default

    Simple Meter definitely needs a lot of work. I'm glad someone has taken on the job. I started doing some modifications a while back, but just didn't have the time to do so. I added in the 'manual mode' you speak of - it was one of my first changes.

    Some suggestions:

    The split and new session buttons are features that are very useful, but many don't know about.

    Then there are the drop down menus for the columns - ex. changing DPS to Damage Taken - that most people don't know about.

    The open/closing of some frames - ex. drop down menus or the copy paste data field - is not very intuitive.

    There should be a toggle to only show players or monsters specifically in the meter logs. Perhaps log everything no matter what, but add a toggle to hide all monsters or all players.

    Perhaps some sort of "synchronized start" feature, where user's can set a time (based off the server's time or a generic timezone - not sure if that's possible) to start (and end) the combat recording at. Then all users in the raid hit the "go" button, and their simple meters all start and end at the same time. Not sure how feasible or possible this one is. Just a workaround to attempt to remedy the no addon to addon communication 'issue'.

    For optimization purposes, the self-mode where it cares about nothing but the player is a great idea.

    Something I originally suggested to the addon developer a little while back...
    Is it possible, when using the "All" setting instead of showing per session, to not lower the DPS of enemies/allies who were not active in some of the sessions? So it only counts the time that the entities were in a session.

    In other words, if there is a session for 1 minute where Jack deals 6000 damage total and Ted deals 6000 damage total, and then another session for 1 minute where Jack left and Ted deals 6000 damage total... when you change from showing session by session to showing everything combined, Jack's DPS would be 100, since he was only in the first 1 minute long session.
    Currently, Jack's DPS would be 50.
    I'm not sure how possible this one is. I fear, if it even is possible, it may be very difficult to do without using far too much resources.


    If you have any questions, problems, etc, do not hesitate to ask.
    Best of luck!
    Last edited by TimeBomb; 02-26-2012 at 02:23 AM.

  9. #9
    Telaran sneakyninja1's Avatar
    Join Date
    Dec 2010
    Posts
    65

    Default

    Woo! Great to see someone pick it up after it just sitting there with out any updates. Now if only MiniUi would get a new owner.

  10. #10
    Champion Lorandii's Avatar
    Join Date
    Jun 2011
    Posts
    516

    Default

    Quote Originally Posted by Kreiri View Post
    Wouldn't it complain that local Inspect is nil?
    The reason it works is because you are assigning a local string to a global string; you are not actually matching a string with a table.

    This, while correct, is not the same as what is after the jump.
    Code:
    local _G = getfenv(0)
    local Inspect.Unit.Detail = G.Inspect.Unit.Detail
    Not correct, will nil or error, because you are calling the inspector with incorrect parameters. Note the () which will cause errors or unexpected results, or nil.
    Code:
    local _G = getfenv(0)
    local Inspect.Unit.Detail = G.Inspect.Unit.Detail()
    Because you are assigning a local variable to a global string, you can call the variable whatever name you want. Therefore the following is also correct.
    Code:
    local _G = getfenv(0)
    local unitDetail = _G.Inspect.Unit.Detail
    You can test by looping Inspect.Unit.Detail to return the player's name 1 000 000 (yes, a million) times. Check the CPU usage and time it takes to process the loop. Then upvalue Inspect.Unit.Detail and do it again, comparing results.

    What about MyAddon only doing any particular inspector call a small handful of times? Well, add the number of times all installed addons might call that same inspector, because every time it is called, it eats CPU cycles. A few inspectors x multiple addons = slow. Cache the inspectors ahead of time, and you offload CPU into memory.

    Conversely, you could cache all the inspectors, but that is highly ineffiecient because you are only bloating RAM on the possibility of saving CPU. Only cache the ones your addon actually uses; let other addons take care of themselves.

  11. #11
    Champion Lorandii's Avatar
    Join Date
    Jun 2011
    Posts
    516

    Default

    Er, I don't feel like editing. When reading, replace the word "string" with "table", because you are creating a local table reference to a global table. Sorry!

    Think of this code, and why it is the same principle
    Code:
    globalTable = {} -- global table
    local localTable = globalTable
    And here is the Lua doc on genfenv.
    Last edited by Lorandii; 02-26-2012 at 05:56 AM.

  12. #12
    Plane Walker Kreiri's Avatar
    Join Date
    Feb 2011
    Posts
    402

    Default

    I'm just curious, did you actually try your code?

    I copied/pasted your code to my "test" addon:

    Code:
    local _G = getfenv(0) 
    local Inspect.Unit.Detail = _G.Inspect.Unit.Detail
    Result:

    16:38:11: [Dummy] Error: Dummy/Dummy.lua:2: unexpected symbol near '.'
    16:38:11: [Dummy] In Dummy / Dummy.lua
    Do you know why this happens? Because local Inspect table does not exist when you try to assign something to something in it.

    This does not give errors:
    Code:
    local _G = getfenv(0) 
    local InspectUnitDetail = _G.Inspect.Unit.Detail
    - because no nonexistent tables are involved

    This also does not give errors:
    Code:
    local _G = getfenv(0) 
    local Inspect = {}
    Inspect.Unit = {}
    Inspect.Unit.Detail = _G.Inspect.Unit.Detail
    - because both local Inspect and Inspect.Unit exist when assignment to Inspect.Unit.Detail happens.
    Feminism is the radical notion that women are people.

  13. #13
    Champion Lorandii's Avatar
    Join Date
    Jun 2011
    Posts
    516

    Default

    Good to know, as no, I had not tested it, just theorized. With the working code, was it faster?

  14. #14
    Plane Walker Kreiri's Avatar
    Join Date
    Feb 2011
    Posts
    402

    Default

    I spotted a mistake in your code and pointed it out. You wrote a wall of text about how "local Inspect.Unit.Detail = G.Inspect.Unit.Detail" is correct and will speed up performance. Well then, I thought, looks like Lorandii needs an error message to see a syntax error.

    My point is: don't tell people "this will speed up your addon" about code which does not even work.
    Feminism is the radical notion that women are people.

  15. #15
    Plane Touched terran698's Avatar
    Join Date
    Jul 2011
    Posts
    200

    Default

    glad to see you working on simple meter... one thing that needs fixed is it need to record healing from candence

+ Reply to Thread
Page 1 of 2 1 2 LastLast

Bookmarks

Posting Permissions

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