Lag While Using S86 Powers #3


  • Defect
  • Started
Open
Assigned to sirrus86x
  • _ForgeUser7265160 created this issue Aug 12, 2012

    Hey I'm an admin on a server using S86 Powers and was asked to post this ticket.
    We are currently using version 3.2.1 and it has been causing extreme lag spikes on the server. We are using a hosting company called cloudcraft with 4gb of ram so it shouldn't lag. When we took the plugin off for a few minutes the lag spikes seemed to go away, but when we re-enabled it a few minutes later the lag spikes started to occur again. Any idea what's causing this? Let me know if you need any logs or the IP to join and see what's causing it.

  • _ForgeUser7265160 added the tags Defect New Aug 12, 2012
  • sirrus86x posted a comment Aug 12, 2012

    S86 Powers is a relatively expansive plugin; each power you see listed is its own Java class file, and many of these class files attempt to run synchronous tasks as often as every server tick (which SHOULD be 20 times per second). Some of these tasks are huge resource hogs; in fact it was confirmed that repeated use of Bloodbend could cause a server to crash (this has since hopefully been fixed with the upcoming update). Fortunately, if no one is using a given power, there's nothing for it to run.

    I test this plugin on two computers. One is my own, which has 16GB of ram and is run as a local server with little to no lag. The other is a server several states away, which has 4GB of ram and has mild lag. Neither of these computers has more than maybe 15 players on at a time, so it's difficult to test.

    So some info that may help: How many players are on who have powers at any given time? What powers are they dominantly using? Is memory usage higher while using S86 Powers than when not using it? Version 3.2.2 allows you to lock powers, which prevents them from loading at all. When/if you get it try locking certain powers and see if it improves or not.

  • sirrus86x removed a tag New Aug 12, 2012
  • sirrus86x added a tag Waiting Aug 12, 2012
  • _ForgeUser7265160 posted a comment Aug 12, 2012

    @sirrus86: Go

    Alright I'll try locking them and when we were lagging there were only about 6 players on. The powers being mostly used are acrobat and the grapplinghook. And about the memory usage I'll have to check I'm not sure right now. Just went to check on 3.2.2 and it doesn't seem to be uploaded? Link?


    Edited Aug 13, 2012
  • _ForgeUser7265160 removed a tag Waiting Aug 12, 2012
  • _ForgeUser7265160 added a tag Replied Aug 12, 2012
  • sirrus86x posted a comment Aug 12, 2012

    @junglebunyslayr: Go

    6 players is nothing so it isn't that.

    Acrobat and GrapplingHook aren't very resource-demanding powers from a coding standpoint, may be able to rule that out.

    Get me that other information when you can and I'll do what I can to fix this issue.

  • sirrus86x removed a tag Replied Aug 12, 2012
  • sirrus86x added a tag Waiting Aug 12, 2012
  • _ForgeUser7485562 posted a comment Aug 13, 2012

    @sirrus86: Go

    Hey sirrus86, I'm also an admin on the same server and junglebunyslayr and I am in fact the one who installed the powers. Although I'm not too java savvy, here's what I can tell you right now.

    We currently have the server set up to automatically move players to different groups (Aka classes) depending on whether they have unlocked the classes or not. This is a relatively brand new feature of the server, and in fact we have used MyCommand to make the custom commands.

    For example when a player chooses the "Pyro" class, they will type /class Pyro and in the console (Or as an OP) MyCommand runs the following commands:

    /power group Zeus -r $player

    /power group Vampire -r $player /power group Explorer -r $player /power group Pyro -a $player

    /msg $player You have switched to the Pyro class! As a pyro hitting people with your sword will set them on fire, while hitting people with an arrow from your bow can also set them on fire! The higher your level the more of a chance you have to light you enemies on fire!

    Which is pretty much an automatic group switcher. I'm not too sure if there are any commands that could possible 'clear' the player from any group they are in, then allow the command to change their group start, instead of making the plugin try and remove them from every available group out there. We also have the 'text' commands with MyCommand that are /eggs and /classes. At current each class contains the powers: Zeus - Thunderbow and Fireaura Vampire - Vampirism, Darkregen, PreEmptive Explorer - Acrobat, GrapplingRod Pyro - Pyroblade, Pyrobow

    We are planning to add more but we are unsure because of the lag right now, so we are treading very lightly. Regards, Muffinjello


    Edited Aug 13, 2012
  • _ForgeUser7485562 removed a tag Waiting Aug 13, 2012
  • _ForgeUser7485562 added a tag Replied Aug 13, 2012
  • sirrus86x posted a comment Aug 13, 2012

    @muffinjello: Go

    That sounds like a really cool system you've got going.

    Version 3.2.2 includes a way to assign players to groups using permissions, for example "s86powers.groups.pyro" would put them in the Pyro grpup. They won't show up in the group list when you do "/powers group <name>", but otherwise their powers will work the same. When/if you get version 3.2.2, I suggest using permissions instead as it doesn't require overwriting the config file every time a player is put into a different group, which would avoid one possible cause of lag (although it does require rewriting the permissions file, so it may make things worse as well).

    Version 3.2.2 is currently in the approval stage and should be available at some point today, I recommend trying my suggestion and see if it helps at all.

    In the future I'll see about implementing a way to remove players from any group they're in, as that'd definitely be more convenient for what you're trying to do.

  • sirrus86x removed a tag Replied Aug 13, 2012
  • sirrus86x added a tag Waiting Aug 13, 2012
  • _ForgeUser7485562 posted a comment Aug 13, 2012

    @sirrus86 Great I will try that!!! Yeah you should totally come on our server sometime and use it to see how our classes work, and test which powers/classes cause lag. I would definitely appreciate it that when you try to change groups and are already in one, instead of the plugin stopping you and saying that you are in one, it automatically removes you from your current one to the one you want to change to.

    As for the pConfig.yml , I'm not too sure already, but can you set a cool down on any powers, or only ones that have the cool down line already?

  • _ForgeUser7485562 removed a tag Waiting Aug 13, 2012
  • _ForgeUser7485562 added a tag Replied Aug 13, 2012
  • sirrus86x posted a comment Aug 13, 2012

    @muffinjello: Go

    Heh if you really want I can swing by and check out your server :P For testing, of course... Just PM me the address and I can check it out sometime when I'm free.

    The reason the "already in a group" error comes up is so someone managing one group can't just take someone from another group and put them in theirs. It is still inconvenient in its current state however, I'll see about getting a better solution for this.

    Keep in mind the pConfig.yml file is still incomplete, but with each update you should see more powers being added to it as I complete them. Anyplace you see something like "cooldown" or "something-cooldown" lets you set the cooldown for that power. Just be sure to use a time format like "15s" for fifteen seconds or "10m30s" for ten minutes, thirty seconds.

  • sirrus86x removed a tag Replied Aug 13, 2012
  • sirrus86x added a tag Waiting Aug 13, 2012
  • _ForgeUser7485562 posted a comment Aug 13, 2012

    @sirrus86: Go

    Yeah, great thanks ^^

    Maybe then add a " op / admin only " command like /powers Agroup <group name> -a <player name>

    The 'Agroup' could stand for Admin group, and permission to use the command might be separate than the other commands.

    Also, another thing you could check would be to see if the person running the regular /powers group <group name> -a <player name> was 'OP' and if so, then to force fully remove their current group and transfer them to the target group... these are all suggestions of course. :)

    I'll try to get you the server log tomorrow when I get home and can sit down properly and send it to you.


    Edited Aug 13, 2012
  • _ForgeUser7485562 removed a tag Waiting Aug 13, 2012
  • _ForgeUser7485562 added a tag Replied Aug 13, 2012
  • sirrus86x removed a tag Replied Aug 30, 2012
  • sirrus86x added a tag Started Aug 30, 2012

To post a comment, please login or register a new account.