StaffActivity

Discussion in 'Plugin Requests' started by adi0115, Jun 24, 2017.

Thread Status:
Not open for further replies.
  1. Plugin category: Admin

    Minecraft version: 1.8.8

    Suggested name: AdminActivity

    What I want: A simple plugin that track's staff's activity! This plugin tracks all players that added to the plugin, it will stop tracking player's activity if they have not moved/talked for 60 seconds, the activity resets every week!

    Ideas for commands:
    /
    aa add <player> - add that player as staff to the plugin and tracks their activity
    /aa remove <player> - removes the player from the staff list and stop their tracking
    /aa check <player> - checks the following player's acivity
    /aa me - checks your activity

    Ideas for permissions: aa.check - allows you to use /aa me
    aa.admin - allows you to use /aa check and add/remove command.

    When I'd like it by: Today/Tomorrow
     
  2. Offline

    Cuchi28707

    What type of activity? Commands?
     
  3. Offline

    Black_Lottus

    I think that he refer to the time to stay online.

    And don't count if you stay online but stay afk.

    Enviado desde mi XT1032 mediante Tapatalk
     
  4. How long they have been online on the server, and the plugin stop counting it if the staff have not been moving for more than 60 seconds
     
  5. Offline

    Machine Maker

    I can write this plugin.
     
  6. Offline

    icedmoca

  7. Offline

    timtower Administrator Administrator Moderator

  8. Offline

    Machine Maker

    so the plugin is done except for the resetting part. Do you want it to reset every week automatically or do you want a command to reset all staff members or even a specific staff members online time?


    EDIT: and if you want it to happen automatically, is the server ever going to be reloaded during that week?
     
    Last edited: Jun 26, 2017
  9. I would like it to happen automatically and yes, the server may restart once or twice during a week.
     
  10. Offline

    Machine Maker

    Ok. It will be done within the next 4 or 5 hours. I'm busy atm, but I will finish it ASAP.

    In order to avoid using PlayerMovrEvent, I have a scheduler checking player movements every 20 ticks, or one second. This will greatly reduce the server strain. If checking to see if a player moved every second is too slow, let me know.


    EDIT: Here is the plugin. Please feel free to message me or reply here with any problems or changes you'd like. And don't forget to mark the thread as filled!
     
    Last edited: Jun 26, 2017
  11. Offline

    Horsey

    @X1machinemaker1X Don't use a timer, it WILL cause a lot more lag than just listening to the PlayerMoveEvent if there are a lot of players online.
     
  12. Offline

    Machine Maker

    Why would that be? I was reading up on how to do repeated events and came across a few examples of people trying to make a similar thing, checking to see if a player has moved. The PlayerMoveEvent is called anytime any player moves. The scheduled event is called once every second.
     
  13. Offline

    Horsey

    Looping over all online players to get a location from a hashmap, and then run logic to see if the player moved, and then save the player's new location to a hashmap is wayyy more memory intensive than just listening to the player move event.
     
  14. Offline

    Machine Maker

    Its not all online players. It is only the admins for his server. I also created a new class that stores all the information about all online admins instead of using a bunch of hashmaps.
     
  15. Offline

    Black_Lottus

    @X1machinemaker1X

    I use the comand
    /aa add <player> and works great. (I add my name/user)
    this is the config:

    But.. when i use

    /aa me
    or..
    /aa check player

    Don't work:
    [​IMG]

    Any idea?
     
    icedmoca likes this.
  16. Offline

    Machine Maker

    yeah I know whats wrong. I used getDisplayName() instead of using getUniqueID(). Ill fix it right now. Sorry bout that
     
  17. Offline

    Black_Lottus

  18. Offline

    Machine Maker

    Last edited: Jun 26, 2017
  19. Offline

    Black_Lottus

    @X1machinemaker1X

    Can you add this?:

    - Possibility of changing the language messages in the config
    - Change milliseconds for 1h 1m 1s for example. H: hour M: minuts S: seconds
    - That every 7 days, keep in a file the player and the time that was connected during those 7 days. And let the score start from 0.
    - Top of staffs online.
     
  20. Offline

    Machine Maker


    So I'm not sure what you mean by changing the language messages or by top of staffs online. The changing of the time units and the record keeping, I can do. But I need some clarification on the other two items.
     
  21. Offline

    Black_Lottus

    @X1machinemaker1X
    Ok, try if you can make the colon if you know what it means.

    About the rest.
    1.- Among all the members who are added staff ... Make a top of activity.
    For example:
    Top 1: Martin: 8h this week
    Top 2: Sergi: 6h this week
    Top 3: Oliver: 1h this week
    and put this in signs and skulls

    2.- On the translated messages, I mean ... the message of for example ...
    "Your online time is 1000 milliseconds" have the possibility to change it to a language other than English. (In the config)
     
  22. Offline

    Machine Maker


    Ok, I'll see what I can do. It'll take at least another day though. Just a heads up!
     
  23. Offline

    Black_Lottus

    Great thank you very much.
    I wait for the plugin for tomorrow.
    Thanks again @X1machinemaker1X

    pd: Tag me when you complete it.
     
  24. Offline

    icedmoca

    The plugin https://www.spigotmc.org/resources/stafflist.5693/
    Allows for "online time" of a player or staff.

    Proof: welp.jpg
    roast.jpg
     
    Last edited: Jun 27, 2017
  25. Offline

    icedmoca

    Okay sorry I didn't notice that well lets see what @X1machinemaker1X does.
     
  26. Offline

    Machine Maker

    Last edited by a moderator: Jun 27, 2017
Thread Status:
Not open for further replies.

Share This Page