Spigot Plugin Development - 7 - Passing the Plugin Instance

Published: 16 November 2021
on channel: Kody Simpson
23,460
517

In this episode of the Spigot MC Plugin series, I show you how to obtain an instance of your plugin's main class in another class. This is something that has to be commonly done for doing things like accessing your config.yml file or scheduling tasks. #Spigot #SpigotTutorial

My code: https://github.com/Spigot-Plugin-Deve...
Join the Community! - https://rebrand.ly/discordlink

Want to Support the Channel?
Become a Member:    / @kodysimpson  
or: https://paypal.me/kodysimpson?locale....

My Socials:
Github: https://github.com/KodySimpson
Instagram:   / kody_a_simpson  
Twitter:   / kodysimp  

0:00 - Introduction
0:50 - Method #1: Static getter method
4:20 - Method #2: Constructor injection
7:01 - Conclusion
8:07 - Outro

More Videos coming soon.
Leave a comment for any future video suggestions.


On this page of the site you can watch the video online Spigot Plugin Development - 7 - Passing the Plugin Instance with a duration of hours minute second in good quality, which was uploaded by the user Kody Simpson 16 November 2021, share the link with friends and acquaintances, this video has already been watched 23,460 times on youtube and it was liked by 517 viewers. Enjoy your viewing!