1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Factions plugin?

Discussion in 'Requests' started by HittmanA, Jan 6, 2017.

  1. HittmanA

    HittmanA Zombie

    Messages:
    207
    GitHub:
    hittmana
    I love FactionsPro. It is so nice, but I tried updating it to api 3.0.0 (changed it to use that api) and it is unusable. It is extremely buggy and crashes the server sometimes when you do /f help. My users are clamoring for a factions plugin and I am stuck. Does anyone know or have a factions plugin.
     
  2. Thunder33345

    Thunder33345 Moderator Staff Member

    Messages:
    2,137
    GitHub:
    Thunder33345
    There have been some other people trying to remake FP but as if rn i dont think so
     
  3. Matthew

    Matthew Baby Zombie

    Messages:
    167
    GitHub:
    matthww
    So I'm expecting you have a crashdump... or some sort of error...
     
    applqpak likes this.
  4. Thunder33345

    Thunder33345 Moderator Staff Member

    Messages:
    2,137
    GitHub:
    Thunder33345
    but this is plugin request thread not plugin help or dev
     
    applqpak and Primus like this.
  5. Primus

    Primus Zombie Pigman

    Messages:
    749
    Yestarday my plugin was public on Github. It's a port from Bukkit plugin by MassiveCraft and it took me a year to gather all information about factions and "best way to do it" in that time I wrote it twice and failed. But third time it took me month to make it ready for production. If anyone are about to make faction plugin with many, many features then say goodbye to many hours of your life :D

    And that's the main reason why I made it closed source, when time comes and I quit hosting my own server, I'll publish it again. However don't try to remake FactionsPro
     
    applqpak and Muqsit like this.
  6. Muqsit

    Muqsit Chicken

    Messages:
    1,548
    GitHub:
    muqsit
    Forget about API3.0.0, in the future PHP build, FactionsPro will need a hard rewrite. (The code is bad anyways). It uses the "SELECT * FROM..." to get values from databases which is going to be removed (the *).
     
    applqpak likes this.
  7. Awzaw

    Awzaw Zombie Pigman Poggit Admin

    Messages:
    726
    GitHub:
    awzaw
    While we await Primuses version, I've added the original FactionsPRO by Tethered_ to Poggit, along with some very minor changes of my own, in particular /f claim restrictions to worlds defined in the config ClaimWorlds array, and support for my AntiSpamPro plugin to keep fac names polite ;-)

    It's been massively tried and tested with all API versions up to and including 3.0.0-ALPHA1, but as with all Poggit CI builds, it is not necessarily bug free - use at your own risk ;-)
    https://poggit.pmmp.io/ci/Awzaw/FactionsPro
     
    Last edited: Jan 7, 2017
    MK500, applqpak and Muqsit like this.
  8. xZeroMCPE

    xZeroMCPE Witch

    Messages:
    67
    GitHub:
    xZeroMCPE
    https://github.com/PocketEssential/UltraFaction

    Was working on that on my free time, should work on API3.0.0 but it's not finished yet....

    I did some things on it wrong, but planning on re-making some things within it. But hey, check it out!
     
    Awzaw likes this.
  9. Muqsit

    Muqsit Chicken

    Messages:
    1,548
    GitHub:
    muqsit
    @Awzaw offtopic but dat poor code still exist. :3
    Screenshot_2017-01-08-11-13-07.png
     
    Awzaw, applqpak and Sandertv like this.
  10. Awzaw

    Awzaw Zombie Pigman Poggit Admin

    Messages:
    726
    GitHub:
    awzaw
    Thankfully that's not me! I'll fix it, well spotted :)
     
  11. Muqsit

    Muqsit Chicken

    Messages:
    1,548
    GitHub:
    muqsit
    I am not blaming you for that. That's just how FactionsPro was coded lol.

    Most of it is just bad. For example, look at this function...

    Screenshot_2017-01-08-18-59-27.png
    Incrementing $i with +1?
    What's $j?
    $row unneeded?
    Plus, it's bad doing too much maths or tasks in loops. For example, the sendMessage bit could've been done outside the loop, by saving the values in an array then imploding it with "\n" instead.
     
    Awzaw and XShockinFireX like this.
  12. Awzaw

    Awzaw Zombie Pigman Poggit Admin

    Messages:
    726
    GitHub:
    awzaw
    Want to make a PR to the original repo? Not sure if he's still active though, so you can PR to my fork if you like
     
  13. Muqsit

    Muqsit Chicken

    Messages:
    1,548
    GitHub:
    muqsit
    Player.php has a getPlayer() function which returns the player (useless).
    And no, the FactionCommands.php file, which was not modded, has poor code still.
     
  14. Thunder33345

    Thunder33345 Moderator Staff Member

    Messages:
    2,137
    GitHub:
    Thunder33345
    i shall say the way they name it is already bad it should been getTopFactions($amount) or something to make it more dynamic
     
    Awakend likes this.
  15. Muqsit

    Muqsit Chicken

    Messages:
    1,548
    GitHub:
    muqsit
    However much you say, you cant argue for the fact that $i + 1 is not a bad practice.
    R.I.P ++$i, $i++
     
  16. xZeroMCPE

    xZeroMCPE Witch

    Messages:
    67
    GitHub:
    xZeroMCPE
    As long as it works, and no performance is lost due to it, then its all good...
     
    Muqsit likes this.
  17. Primus

    Primus Zombie Pigman

    Messages:
    749
    At least you could tag me (@)

    UltraFactions were my first try to create factions plugin, but I lost in design and everything I just decided to rewrite it and simply named FactionsPE that's where I went into porting a plugin from MassiveCraft, but much of that code was from Java and simply translated because I wasn't able to see the full image of plugin mechanic. After few months, I got bit smarter and went for third try. It went out good and is now on my server. I decided to remove it from Github because it won't make my server special anymore, a bit selfish guy :p
     
    Muqsit likes this.
  18. Thunder33345

    Thunder33345 Moderator Staff Member

    Messages:
    2,137
    GitHub:
    Thunder33345
    if that is same then good
    please just dont get into auguring over AND or && is more performance efficient
     
  19. wsngamerz

    wsngamerz Spider

    Messages:
    8
    GitHub:
    wsngamerz
  20. HittmanA

    HittmanA Zombie

    Messages:
    207
    GitHub:
    hittmana
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.