The FabulousCore gives to you create a SignGUI, WorldBorder, cooldowns, minigame, interactable objects, chain based item creating and send sound & colored/timed message(s) to player(s) with easy way.
<repositories>
<repository>
<id>jitpack</id>
<url>https://jitpack.io/</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>com.github.FabulousProject.FabulousCore</groupId>
<artifactId>bukkit</artifactId>
<version>${version}</version>
</dependency>
</dependencies>
<builds>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.3.1-SNAPSHOT</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<minimizeJar>true</minimizeJar>
<createDependencyReducedPom>false</createDependencyReducedPom>
<!-- Relocations(Optional)
<relocations>
<relocation>
<pattern>me.alpho320.fabulous.core</pattern>
<shadedPattern>[YOUR_PLUGIN_PACKAGE].shade</shadedPattern>
</relocation>
</relocations>
-->
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</builds>
plugins {
id "com.github.johnrengelman.shadow" version "7.0.0"
}
repositories {
maven {
url "https://jitpack.io"
}
}
dependencies {
implementation("com.github.FabulousProject.FabulousCore:${version}")
}
final class MyPlugin extends JavaPlugin {
private BukkitCore core;
@Override
public void onEnable() {
this.core = new BukkitCore(this);
this.core.init(); //then you can access with BukkitCore.instance().foo();
new SomeClassesThatNeedBukkitCore(this.core).foo();
new SomeOtherClasses(this.core).foo();
}
}
SignGUI sign = BukkitCore.instance().sign()
.create() // creates a new instance.
.setType(SignGUI.SignType.OAK) // Types: OAK, ACACIA, BIRCH, SPRUCE, CRIMSON, DARK_OAK, JUNGLE.
.withLines("Hi!", "how are u?", "must be four", "lines!")
.whenOpen(strings -> {
player.sendMessage("opened!");
}
)
.whenClose(strings -> {
player.sendMessage("closed!");
}
)
.open(player);
ItemStack item = new BukkitItemCreator()
.type(Material.IRON_SWORD)
.name(BukkitCore.instance().message().colored("&6&lAMAZING SWORD!"))
.amount(3)
.damage(1)
.lore(
"awsome lore",
"really!"
)
.enchant(Enchantment.DAMAGE_ALL, 10)
.modelData(20)
.flag(ItemFlag.HIDE_ATTRIBUTES)
.glow()
.create();
BukkitCore.instance().sound().send(
player,
Sound.ENTITY_PLAYER_LEVELUP
);
BukkitCore.instance().location().serialize(
player.getLocation()
);
BukkitCore.instance().location().deserialize(
mySerializedString
);
T randomElement = new RandomSelect<>(myList).choose();
Player target = new RandomSelect<>(playerList).choose();