Minecraft Plugin Tutorial (in Kotlin) | Project Setup
Vložit
- čas přidán 8. 06. 2024
- Learn how to make a 1.19/1.18 plugin for Minecraft Paper/Spigot/Bukkit servers... with Kotlin (or Java, if you want)! You'll make a small "hello world" program and set up an empty project in IntelliJ IDEA.
INSTRUCTIONS FOR NEWER VERSIONS (1.19+):
At 9:05: Use the latest version from here papermc.io/using-the-api
At 7:14: Change the api-version to your desired version (e.g. 1.19)
Don't forget to reload Maven!
If you're curious about Java vs. Kotlin, here's a comparison from the Kotlin website: kotlinlang.org/docs/compariso...
Patreon: / legitimoose
Discord: / discord
Twitter: / legitimoose
IntelliJ Idea: www.jetbrains.com/idea/download/
Java's Package Name Rules: docs.oracle.com/javase/specs/...
Latest Paper API Version: papermc.io/using-the-api
=== Timestamps ===
0:00 - Intro
0:21 - Download IntelliJ IDEA
0:38 - Create a Project
1:43 - What are GroupId and ArtifactId?
2:58 - More Project Settings
3:57 - How to Hello World
4:52 - How to Build a Plugin .JAR
6:45 - Changing Name/Settings After Creation
7:26 - Finished Project in Java
7:32 - Converting to Kotlin
8:28 - Updating to the Latest Version
10:21 - I make a mistake (for educational purposes)
10:46 - Unsolved Mysteries of Java Versioning?
11:24 - Finish Converting to Kotlin
In this video, you'll learn how to do project setup, set up a project, in IntelliJ IDEA for a Minecraft plugin/server-side mod. Bukkit plugins, spigot plugins, and paper plugins are for the most part, identical. Only slight feature changes have occured. Bukkit isn't used anymore, but its name lives on in the community. Spigot is older and not used very often in modern servers. It's what the newer, slicker, PaperSpigot is based on. PaperSpigot/PaperMC/Just Plain Ol Paper is what I use in this tutorial, and it's what you should always use (in most situations). This video serves to help you do the hardest part of plugin development, set up a project. Setting up a development environment for Paper plugins is very hard, and finding one for Kotlin in English is even harder (there are an abundance in German though, which is pretty funny). I actually watched one of those german tutorials to learn this. With auto-translate and everything lol. This is not keyword optimization, and idk why you'd be reading this far, so this story doesn't belong here, it's just funny. Ahem- Kotlin and Java are compatible with eachother, and this is a minecraft java plugin tutorial, as well as a minecraft plugin tutorial kotlin, as the cool kids might say. Kotlin is much more fun to write, and is great for mods and plugins. Wondering how to write a minecraft plugin in kotlin? You've come to the right place. Looking for a minecraft plugin tutorial in IntelliJ? Also the right place. Good luck on your minecraft plugin making journey, in version 1.18, 1.19, 1.20? This tutorial is from 2022 and still works. It should work for a long time and I'll update you if it doesn't. Hope you enjoy this minecraft plugin coding tutorial and that you learn how to make a plugin for minecraft 1.19/1.18. ~Metadata Soupsmith - Hry
1:08
"today we're making a plugin, a spigot plugin, that's why we're going to select, paper"
-Legitimoose 2022
Paper is based on spigot
@@brainnotwrkin ik but they are not the same thing, it's like saying "mobile phones are based on fixed telephones", that's true but the are not the same thing
@@GGGamesXDlolit's exactly the same wtf is u yapping about
it takes ZERO effort to make a google search before saying something that doesn't make sense@@qanti6582
@@qanti6582 no, they are not. moose explained it in the video.
For those of you who are coming to this video in 2023, you will need to change the platform from "Sponge" to "Bukkit" and select Paper as the initial screen with all the options for the platform is gone now
was abouta comment that myself, thank you good sir
i am coming in 2024....
best plugin tutorial i've ever seen in my life! I would follow each tutorial he makes.
agreed
Finally another video! I would like to see more videos about minecraft shaders, I think it offers a lot more!
Yes
I wouldn't say that. That's just a visual change. Plugins can really change your gameplay, that's how you can play on a hypixel server without downloading any client side mods. It's all plugins.
Recently, I decided "Hey, I want to make plugins for a very funny server idea" (because the skript plugin just isn't it for me) and remembered this channel, lo and behold, I found this video. Overall, really great tutorial, enjoyed how you explained each step. Keep up the good work!
this man made me interested in coding only by himself huge fan
OHMYGOD
Legitemoose teaching us things nobody else wants to
Thank you so much
I hate myself for giving a chance to -Java- Kotlin
@@danielrdrigues bro kotlin is basically shit
I never thought a tutorial could be so fun to watch! I would love to see some more of these, maybe about how to make a command work or something
At 9:05: Use the latest version from here papermc.io/using-the-api
At 7:14: Change the api-version to your desired version (e.g. 1.19)
Don't forget to reload Maven!
Plz bring more episodes like building other types of plugin and more knowledge
bro finally i can find a tutorial of kotlin plugins for minecraft that isn't in german
Why don't just use Visual Studio?
@@privatechannel1272 like he said in the video since jetbrains made kotlin the easiest way to convert java to kotlin while coding is with jetbrain's Intelij
@@vithrn123 except not cause he just says to figure it out yourself in the end smh
My guy is back! These videos really help me! Keep it going buddy!😀
Love how your able to teach but yet make it entertaining so that it doesn't sound like a robot teaching or showing how to do the lesson.
you make the most fun and entertaining coding tutorials i've ever seen, keep it up :DDD
Thanks to you, I was able to add new features to and existing plugin, compile it and contribute to the main repo ✨
As a software developer myself but someone who has never tried developing a Minecraft plugin before, I'm definitely digging that sense of humour you've got going there. 😁 Java was the first language I ever learned, but haven't touched it in over 10 years, so this should be err... fun?
welp I learned to code Java last summer, coded some fabric mods, but once I realized how easy coding a datapack is, lets just say that I haven't used intellij in a long time
please a new tutorial that is updated in intellij idea please
To everyone watching this without any knowledge of java: I would recommend to learn little bit of java. Things such as project managers and some code syntax and also how IDE wok.
Best up to date tutorial for Minecraft Plugins & Java In General Thank you ♥
Hope to see some more videos on Minecraft modding with Kotlin! Great work
modding?
I looked for a video like this for 2 weeks.. thank you so much
changing the java version in the pom.xml file allows the use of newer java features
This video is great. Would like to see another one where you show how to make a simple plugin like adding a command or something :)
how long i've waited for this
This is why I am subbed to this dude
love the charisma coming out of you my friend! 😂
Wow I am amazed by how this tutorial is good
sir i have no idea who you are and how you appeared in my recommendeds, but ive already subscribed to you, keep up the good work 👍
This only video was better than the 19283827382 other guides in CZcams together XD
Started learning code in Java... I will probably never choose to use that language again! 😅Great tutorial!
I love how I'm just opening the app when legitimoose is putting the plugin on the server
I like this guy. Made coding fun with his energy
could you do more videos on plugins as well as datapacks? you're very good at explaining btw
ur channel is very underrated
Thanks legitimoose, very cool
Me alegra mejorar mi nivel de inglés, así descubro joyas como este canal XD
I just tried to watch a video before this with the same program, this is SOOO much easier
Legitimoose uploaded 😱
Hey mate, thanks for all the awesome videos! Wondering if u can make a loot table and advancement video for datapacks.
There is a great loot table tutorial by someone named Sir Roman
i love this content and ily
sooo much underrated ngl
I'm 90% sure the reason stuff breaks when you use a space in the actual file name is because windows/whatever program you're using doesn't recognize it as a valid directory, for example:
To access a folder on your desktop named "Funny Project" you basically have to think about it as if you were using a terminal- **cd C:\Users\User\Desktop\Funny Project**
And if you've ever tried that, you would get an error. ("The system cannot find the path specified.")
That's why you might see people use quotes after **cd**, so **cd "C:\Users\User\Desktop\Funny Project"** actually works.
This is also implemented into tab completion in terminals, if you try writing **cd(space)** and then pressed tab you can occasionally get directories surrounded in quotes.
Hope this helped!
Can you pls make a forge/fabric mod tutorial?
Btw I have watched your videos since you had like 8k subs so congratulations!
you should really use fabric
@@drakefruit right
BRO SAVED MY LIFE
About the "Unsolved Mysteries of Java Versioning".
My understanding is that newer Java JVMs are backwards compatible. So for example a JVM with Java version 17 can run code written for Java version "1.8". Although a JVM with the version 1.8 can't run code written for newer Java versions, because it lacks the new features.
This might not be a 100% correct, because I just wrote that of the top of my head.
Thanks! 🥰
Bruh I literally just searched for coding Minecraft stuff in kotlin out of interest and I noticed you uploaded a vid on that
Just create more plugin tutorials, when u made the datapack tutorials, i loved it so yes more plugin tutorials like on HOW to make the player fly or smth
to anyone struggling to find the community edition, IntelliJ sort of hid it on their webpage, you need to click show other versions on the download link provided
thank you
Or on the main download page just scroll down a little
do i want to make a plugin: no
am i watching: yes
can you make a plugin on basic gui opener but pls make more other plugin tutorials too
Thx for helping! But what about to explain how to detect some of events player? Just like for flying (double jump)?
Hey thank you so much I had to past with python no I can learn kotlin this will be good for plugins because I checked there was a script plugin for JavaScript and python or many people said it was laggy and it lacks the features
yessir plugin tutorial
pretty sure the pom.xml java version is useful when you are building via maven, to do so you would need to delegate build and run tasks to maven in intellij, however these steps are not required in this case everything works, and if everything works then there is no need to mess with it
thanks man!!
please do more ! please is possible to make something where you take an open-source project and contribute to it ? thanks for any answer!!!
wouldve loved to see a plugin made i got it all setup but theres no tutorials out there for paper kotlin syntax development (that are in english anyway that i can find) i was hoping to build a /fly plugin for my sever to test this but now i'm lost with a hello world plugin that i cant even see in game
Thank you
BRUUUUH!!! Why this video is underrated? It shouldn't be like that(
Haiya peep, just wondering if you could possibly make a extension to this video talking about how to make something simple like an object that gives you speed when you right click on it. I found this video really helpful and was wondering if you could do that if it's not too much trouble and such. Thankes!
Well instead of setting up an IDEA artifact you could've just expanded the maven goals on the right and double-click package. This will create a new maven run that will package your jar for you and is more universal than IDEA artifacts
Kotlin yes finally
you can build the artifact in the maven tab
We need more
the moose is back again
so what is the extreme fly part??? i dont know java
yeah I am out on 4:42 . In my case "msg" is red and is flagged as an error.
I want to know about finding entity positions and replacing blocks
i want to smash my head seeing this and how hard and remember it is to know
Sir
Thank you
Bruh my subscription box hates me, I asked for this and you made it and CZcams didn’t even send it in the subscription box I looked at your channel right now and I found out I didn’t see two videos 💀
9:19 this gave me a mental breakdown
Please may you make a tutorial on adding custom music discs and, if you watch MCC, you will know that they have custom songs for each game. That is what I really want.
i’m pretty sure you can do that with resource packs
there's already a plugin for that search something like custom music disc plugin
I am trying to code my first minecraft plugin but all the videos I watch seem outdated. When using the minecraft developers plugin it never gives the option to use paper and go through the steps as shown in the video. Any help would be appreciated!!
Hi, if you still need help in order to select paper you neeed to select bukkit then you chose betwen paper and spigot, hope this helped
How do i download the JDK when i did like you said it says it dosent work, or specificly "Failed to prepare JDK installation to C:\Users\_____\.jdks\temurin-20.0.1" How do i fix this?
Yeah I have no idea what to do from here so please make another
Im wanting to get into making MC plugins, can you please make more amazing tutorials like this one?
welp hes dead :(
Is there any documentation on Paper/Spigot in Kotlin? Or any way to know how the java is converted without just guessing?
If you copy/paste complete java code into a Kotlin file, it will automatically ask if you want to convert it!
Can you teach us how to make custom enchantments?
just to be clear, the java.version is only for some configuration if it was public, the jvm target tmk is also useless. i like to change it anyway cuz im a fan of doing dumb things
Im not even started it but i feel the pain like im coding in C# Json and fabric (a mod running thing like forge)and its still looks like super strange to me
Can u make tutorial how to make plugin play music
Will it work for 1.16.5?
part 2? no one else made a tutorial for kotlin and papermc. they're all for spigot
can you create new items by using this?
Does anyone know why the actual name of the project is in camelCase?
oh thats nice
Where s the maven? You can setup the maven to install through
how do i make extremeplugin.class writeable.
it says that it couldn't loadthe plugin lol, maybe it's because i've put only a gigabite of rom
Absolutely loved your video! But I have a question. I searched the web for paper docs on Kotlin but there weren’t any that I could find. Could you tell me where I could find one? And also, can you just convert java code that’s in the docs to Kotlin and use it?
Paper is written in Java, so there are not Kotlin docs available. _However!_ Kotlin is meant to be interoperable with Java, so the answer to your second question is yes! You can use the Java docs, and the IDE will usually help you convert things to Kotlin. You can even copy/paste entire snippets into IDEA and it will automatically convert it to Kotlin. Hope this helps!
@@Legitimoose wow thanks!
Please explain how to make commands in kotlin am beg
Can you do a tutorial about a mod in wich you make a mob
Y E E B O IIIIIIIIIIII
PLUGIN TUTORIAL
1:20 Oh yeah - if you like redstone.. choose neither and learn fabric. (or choose paper but paper still makes redstone a bit jank)
Hi, KotlinEnjoyer here, I totally agree you saying Java is weird, especially setting up a hello world, you have to remember class public static void main String args, but in Kotlin, you only have to remember fun main, Kotlin is better then Java
Exactly
@@meidy3795 yes
do you have to use kotlin?
Do you know, how it is possible, to execute code every tick in a plugin
Yes, you can "schedule" a BukkitRunnable to run every tick! Look up how BukkitRunnables/Runnables work and you should be good to go. (If you're trying to detect something like in a datapack though, you should use events for that instead.)
It would be nice to see how an experienced person goes through the documentation because it can be really confusing for people who don't know what they're doing (people like me)
that's a good idea lol. knowing how to read documentation is obviously very important, and people rarely show how to do it. maybe some kind of "let's code" could work, or just a good ol tutorial. thanks for the suggestion! (no promises I'll make it tho ;) )
Isn’t it like normal to have a domain?
HELP! i cna't convert it to kotlin