Files
src
build.gradle
settings.gradle
Code
16 1,223
src/main/java/com/kodari/currencyshelfshops/CurrencyShelfShops.java
package com.kodari.currencyshelfshops;
import com.kodari.currencyshelfshops.command.ShelfShopCommand;
import com.kodari.currencyshelfshops.currency.CurrencyManager;
import com.kodari.currencyshelfshops.data.ShopRepository;
import com.kodari.currencyshelfshops.listener.ShopListener;
import com.kodari.currencyshelfshops.shop.ShopManager;
import org.bukkit.Bukkit;
import org.bukkit.plugin.java.JavaPlugin;
public class CurrencyShelfShops extends JavaPlugin {
private ShopRepository shopRepository;
private CurrencyManager currencyManager;
private ShopManager shopManager;
@Override
public void onEnable() {
saveDefaultConfig();
this.shopRepository = new ShopRepository(this);
this.currencyManager = new CurrencyManager(this);
this.shopManager = new ShopManager(this, shopRepository, currencyManager);
Bukkit.getPluginManager().registerEvents(new ShopListener(shopManager), this);
ShelfShopCommand command = new ShelfShopCommand(this, shopManager);
getCommand("shelfshop").setExecutor(command);
getCommand("shelfshop").setTabCompleter(command);
}
public ShopRepository getShopRepository() {
return shopRepository;
}
public CurrencyManager getCurrencyManager() {
return currencyManager;
}
public ShopManager getShopManager() {
return shopManager;
}
}