1.16.5 Help me! i just got started!

Discussion in 'Spigot Plugin Development' started by Ruiyan, Jun 30, 2021.

  1. Hi, guys, hope you see my thread. The problem is that i just go started with coding using eclipse, don't suggest me IntelliJ, since I chose eclipse. The thingy is that I don't really know what to do right now. I did the plugin.yml thing fine, as this page said, also, i will copy everything in it here after the link.



    LINK: https://bukkit.fandom.com/wiki/Plugin_YAML


    plugin.yml:
    name: SkywarsCore
    version: 0.01
    description: Ask the owner of this plugin befoure updating! I will accept every tested updates, if there is nothing wrong.
    author: sub2_firebird (first mc name: Akseli_yt)
    authors: Only me in this version yet
    website: (Will be released soon)
    main: me.sub2_firebird.skywarscore
    database: false
    depend: bedwars plugin on spigot website, bedwarslost plugin on spigot website
    commands:
    flagrate:
    description: Its the base plugin for the skywars menu of my new server.
    permission: skywars.admin.mod.baseplugin
    usage: Umm, i think you wrote the command wrong. Try instead: /skywars <start/stop>
    description: Its the base plugin for the skywars menu of my new server.
    permission: skywarscore.adminchangeskywars
    usage: |
    /&lskywars ; [start/stop; on/off]
    Example: /&lskywars - base plugin for skywars core
    Example: /&lskywars on - turns it on, and off or stop turns it off, also start turns it on.
    permissions:
    skywarscore.*:
    description: Gives access to all Inferno commands
    children:
    skywarscore.onoroff: true
    skywarscore.startorstop: true
    inferno.burningdeaths.others: flase
    skywarscore.onoroff:
    description: use on or off
    default: false
    skywarscore.startorstop:
    description: use start or stop
    default: false
    inferno.burningdeaths.others:
    description: Allows you to see how many times others have burned to death
    default: op
    children:
    inferno.burningdeaths: true




    Anyway, I don't know how to continue anymore, so because I read few webpages about how to code a plugin, i got here, but what do I do? Create new thing? Use something? Copy files? Use Mojang? Please help, BTW i will also put a image of my plugin eclipse page where I have ready file if I have anything wrong or that you know what do I need to create. Thanks for reading and please reply.

    Image:
    Under this link (i don't know is this link there forever, if it is broken, please tell me.)

    https://ibb.co/Z6nRLh5





    Soooo... This is pretty much it, please tell me. I have coded mods for fabric, so if that can help, anyway, please help me and please send me Images if you can to help me step by step, I putted my images under a link in this website, so just do like my example tutorial.

    Example tutorial:
    First palapilipulupiii like: ibb.co/123456ABCD
    Then do jfiejfiejfiuhfiedjfihfie like: ibb.co/ABBC98765
    Finally, do feifjdiejdihfie just like: ibb.co/JDIEJFEFN


    This was just an example, so do something like this, because for me, more complex tutorials are too much for my dum brain. Anyways, so basicly please help me to continue, just watch the image to see where am I, and thank you so much! Have a niceday, byyyyyyee!

    So please reply for this poor littely donkey, which is me, dum guy, anyways, thanks for helping if you can, and thanks for reading if you can't.
     
    #1 Ruiyan, Jun 30, 2021
    Last edited by a moderator: Jul 1, 2021
  2. So the page of images was ibb.co i guess if I dint say so.
     
  3. Barbadosian

    Barbadosian Previously Aaron_Mao

    Would really help if you learn java beforehand. You cannot properly code a plugin without knowing how to properly code in java.
     
    • Like Like x 1
  4. Eh you can learn both at the same time, aslong as you know what a variable and what a method is I think you'll be fine
     
    • Agree Agree x 1
    • Optimistic Optimistic x 1
  5. First, welcome to the coding community!
    Second, if you just started and you only want to code for Minecraft then I have a suggestion: check out CodedRed's channel.
    He's really good - explains everything as if it's your first day coding.
    It's hard to know what to do from the start if you have no basis, so at least this will give you something.
    You can watch the 1.15.x videos, they're just as relevant to newer versions.
    Start from his playlist 1.15 Spigot Plugin Development for Beginners! (don't mind that it's 1.15 - it's still relevant).
    His series starts from the very beginning and advances to more complex stuff ("advanced coding") at a pretty good rate imo.
    There are plenty of guides and channels that teach you how to code, even ones specific to Minecraft, I just like this channel and recommend it.
    If you have questions about specific stuff you can always ask here in the forums, but the most important thing to remember: you need to put a LOT of elbow grease into this - don't expect (actually, you shouldn't even want) people to write the code for you, always strive to improve your code's performance, and do stuff that you like - invent new wacky projects and create them to learn and improve your coding.
    Good luck!
     
  6. Umm
    Can u send the video here, i cant really reach youtube with my working pc cuz VPN, and for security reasons, i cannot turn it off, so please OuO
     
  7. And u 2, please, I cannot reeach youtube because VPNs limit, please could you please send the most useful vids here, i hope you all do, here is a great place to download the vids:
    https://y2mate.is/en2/
    thnx
     
  8. IK java, since i use it, but idk what to do, like right now i have made progress, look, wait
     
  9. So here is what i have done! I still chose IntelliJ afterall, cuz I fount an useful plugin of Minecraft Developing! And it is helpful, though, i am stuck again lol OnO, let me tell you why.
     

    Attached Files:

  10. #setExecutor receives JavaPlugin as its variable, so in your case replace "new maincommand()" with "this"
     
  11. Here was the picture.

    I am stuck! Where? Here, basicly, i am making my first ever command, I am going to make like a basic skywars core plugin, like where we have a gamestarter and ender, also an deadbox where to spectate else people, a simple one. Anyway I am making a command for admins or me to start or stop the core plugin, also this will effect to later api plugins for this. Anyway, lets say that im stuck again that how do I amke a output for my command, IK how commands work, and I use the basic one where u package, overide, import commandsender, executer, chatcolor and command itself, then u like use the command where u list these and usage of these. Then u do the output part.
     
  12. so, basicly, idk y, it gives me like six errors while building.
     
  13. Please explain a little more, like where, cuz my question and my brain isnt really matching that, could u please explain?
     
  14. Didnt u read my message? i said i know how to code fabric, its just a logic and what first what second thing.
     
  15. OK so here's what you need to do:
    1)
    How: on line 11, that starts with "getCommand..." you have "new maincommand()" in parentheses at the end. Replace it with "this". Just write the word "this" instead of it.
    2) The #setExecutor sets an executor to the command (shocking, I know...), but for it to set an executor what you need to pass it is a CommandExecutor variable. Meaning you need to make your main be of class CommandExecutor. How you do this: on line 5 (that starts with "public final..." - you can remove final btw, not a must) you add at this at the end (after "JavaPlugin)": " implements CommandExecutor" (yes, you need the space).
    3) After that, you need to add the function that will tell the system what to do when that command is run. You do this by adding this function:
    Code (Java):
    public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
        // What to do when the command is run
        // Don't forget to return a value!!! This function returns a boolean!
    }
    That's pretty much it - now just fill its inside with what to do and continue coding.
     
  16. 1, i wrote [this] and replaced the maincommand. Is that what u meant?
     
  17. So, u helped me there, i understood, but now the main problem is on this page, maincommand.java page, i want to get the output after [say] command, though IK its not working. I have a main question that can I somehow use console in the plugin. It would be so nice, i could use say, fill... commands. It'll be so good if I could, please could you tell me how or is it possible?
     

    Attached Files:

  18. Copy-paste the entire code here please, I can't know what the problem is just from that