Search in sources :

Example 6 with ArenaInitializer1_9_R1

use of pl.plajer.villagedefense3.arena.ArenaInitializer1_9_R1 in project Village_Defense by Plajer.

the class DogFriendKit method giveKitItems.

@Override
public void giveKitItems(Player player) {
    player.getInventory().addItem(WeaponHelper.getUnBreakingSword(WeaponHelper.ResourceType.STONE, 10));
    ArmorHelper.setArmor(player, ArmorHelper.ArmorType.LEATHER);
    player.getInventory().addItem(new ItemStack(Material.GRILLED_PORK, 8));
    player.getInventory().addItem(new ItemStack(Material.SADDLE));
    Arena arena = ArenaRegistry.getArena(player);
    if (arena == null)
        return;
    if (plugin.is1_8_R3()) {
        ArenaInitializer1_8_R3 initializer = (ArenaInitializer1_8_R3) arena;
        initializer.spawnWolf(initializer.getStartLocation(), player);
        initializer.spawnWolf(initializer.getStartLocation(), player);
        initializer.spawnWolf(initializer.getStartLocation(), player);
    } else if (plugin.is1_9_R1()) {
        ArenaInitializer1_9_R1 initializer = (ArenaInitializer1_9_R1) arena;
        initializer.spawnWolf(initializer.getStartLocation(), player);
        initializer.spawnWolf(initializer.getStartLocation(), player);
        initializer.spawnWolf(initializer.getStartLocation(), player);
    } else if (plugin.is1_11_R1()) {
        ArenaInitializer1_11_R1 initializer = (ArenaInitializer1_11_R1) arena;
        initializer.spawnWolf(initializer.getStartLocation(), player);
        initializer.spawnWolf(initializer.getStartLocation(), player);
        initializer.spawnWolf(initializer.getStartLocation(), player);
    } else if (plugin.is1_12_R1()) {
        ArenaInitializer1_12_R1 initializer = (ArenaInitializer1_12_R1) arena;
        initializer.spawnWolf(initializer.getStartLocation(), player);
        initializer.spawnWolf(initializer.getStartLocation(), player);
        initializer.spawnWolf(initializer.getStartLocation(), player);
    }
}
Also used : ArenaInitializer1_11_R1(pl.plajer.villagedefense3.arena.ArenaInitializer1_11_R1) ArenaInitializer1_9_R1(pl.plajer.villagedefense3.arena.ArenaInitializer1_9_R1) ArenaInitializer1_8_R3(pl.plajer.villagedefense3.arena.ArenaInitializer1_8_R3) ItemStack(org.bukkit.inventory.ItemStack) ArenaInitializer1_12_R1(pl.plajer.villagedefense3.arena.ArenaInitializer1_12_R1) Arena(pl.plajer.villagedefense3.arena.Arena)

Example 7 with ArenaInitializer1_9_R1

use of pl.plajer.villagedefense3.arena.ArenaInitializer1_9_R1 in project Village_Defense by Plajer.

the class DogFriendKit method reStock.

@Override
public void reStock(Player player) {
    Arena arena = ArenaRegistry.getArena(player);
    if (arena == null)
        return;
    if (plugin.is1_8_R3()) {
        ArenaInitializer1_8_R3 initializer = (ArenaInitializer1_8_R3) arena;
        initializer.spawnWolf(initializer.getStartLocation(), player);
    } else if (plugin.is1_9_R1()) {
        ArenaInitializer1_9_R1 initializer = (ArenaInitializer1_9_R1) arena;
        initializer.spawnWolf(initializer.getStartLocation(), player);
    } else if (plugin.is1_11_R1()) {
        ArenaInitializer1_11_R1 initializer = (ArenaInitializer1_11_R1) arena;
        initializer.spawnWolf(initializer.getStartLocation(), player);
    } else if (plugin.is1_12_R1()) {
        ArenaInitializer1_12_R1 initializer = (ArenaInitializer1_12_R1) arena;
        initializer.spawnWolf(initializer.getStartLocation(), player);
    }
}
Also used : ArenaInitializer1_11_R1(pl.plajer.villagedefense3.arena.ArenaInitializer1_11_R1) ArenaInitializer1_9_R1(pl.plajer.villagedefense3.arena.ArenaInitializer1_9_R1) ArenaInitializer1_8_R3(pl.plajer.villagedefense3.arena.ArenaInitializer1_8_R3) ArenaInitializer1_12_R1(pl.plajer.villagedefense3.arena.ArenaInitializer1_12_R1) Arena(pl.plajer.villagedefense3.arena.Arena)

Aggregations

Arena (pl.plajer.villagedefense3.arena.Arena)7 ArenaInitializer1_11_R1 (pl.plajer.villagedefense3.arena.ArenaInitializer1_11_R1)7 ArenaInitializer1_12_R1 (pl.plajer.villagedefense3.arena.ArenaInitializer1_12_R1)7 ArenaInitializer1_8_R3 (pl.plajer.villagedefense3.arena.ArenaInitializer1_8_R3)7 ArenaInitializer1_9_R1 (pl.plajer.villagedefense3.arena.ArenaInitializer1_9_R1)7 FileConfiguration (org.bukkit.configuration.file.FileConfiguration)2 ItemStack (org.bukkit.inventory.ItemStack)2 ArrayList (java.util.ArrayList)1 Block (org.bukkit.block.Block)1 Sign (org.bukkit.block.Sign)1 Player (org.bukkit.entity.Player)1 EventHandler (org.bukkit.event.EventHandler)1 ClickType (org.bukkit.event.inventory.ClickType)1 ShopManager (pl.plajer.villagedefense3.handlers.ShopManager)1 SetupInventory (pl.plajer.villagedefense3.utils.SetupInventory)1