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

What is so bad about Core Plugins?

Discussion in 'General discussion' started by minijaham, Feb 24, 2021.

  1. minijaham

    minijaham Skeleton

    Messages:
    801
    GitHub:
    minijaham
    I've been creating lots of plugins, including core plugins(multiple features packed into one).

    I've seen a lot of people who are against core plugins. However, I didn't see any problem with it as there was almost no difference between having multiple plugins vs having a core.

    Why are core plugins considered "bad" or even "inefficient"? I personally prefer making a core as I can have everything organized, instead of having all different kinds of plugins lying around the plugins directory.

    What are the pros and cons of core plugins?
     
  2. EdwardHamHam

    EdwardHamHam Skeleton

    Messages:
    962
    GitHub:
    edwardhamham
    Cores can be useful in production in terms of centralization like you mentioned but when it comes to debugging it's much easier to find the problem and correct it when plugins are isolated. If they're all in one plugin it can be harder to find through the many lines of code, though good documentation and comments within the source code go a long way towards solving this. It's obviously not entirely foolproof, but then again neither is using separate plugins. It's also possible to combine multiple small plugins into one big one (the core) like multiple servers with custom conent do.
     
    minijaham and Primus like this.
  3. minijaham

    minijaham Skeleton

    Messages:
    801
    GitHub:
    minijaham
    Ah...I see.

    But I've seen people talking about cores being heavyweight which apparently slowers the process of the server.
    Which I disagree with because I've had no issue with loading/cpu performance.

    Does it actually make a difference in performance?
     
    EdwardHamHam and Primus like this.
  4. EdwardHamHam

    EdwardHamHam Skeleton

    Messages:
    962
    GitHub:
    edwardhamham
    If all of the separate plugins you'd have if you don't use a core use the same, or close to the same, total resources together as the core would then no it would not make a big, if any difference. Although that depends on your style of programming and what you'd want the core to do.
    That being said if the features you're creating plugins for need the different plugins to work together then I would think they'd use slightly more resources to call each other, whereas if they were all in a core then the code would already be there (Admittedly this point is a guess and I haven't tested this myself before, so take it with a grain of salt).
     
    minijaham and Primus like this.
  5. minijaham

    minijaham Skeleton

    Messages:
    801
    GitHub:
    minijaham
    Thank you! That solves my question. Appreciate it!
     
    Primus and EdwardHamHam like this.
  6. EdwardHamHam

    EdwardHamHam Skeleton

    Messages:
    962
    GitHub:
    edwardhamham
    No problem!
     
    minijaham and Primus like this.
  7. Primus

    Primus Zombie Pigman

    Messages:
    749
    Also because it's "hip" and makes everything "professional"
     
    minijaham likes this.
  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.