WickedProduction
9/27/2019 - 11:16 PM

Entities

For Episode 13:

@EventHandler
    public void onMove(PlayerMoveEvent e){
        Player player = e.getPlayer();

        //Spawn using the player
        player.getWorld().spawnEntity(player.getLocation(), EntityType.GIANT);
        
        //Spawn using bukkit directly
        Entity entity = Bukkit.getWorld("world").spawnEntity(new Location(player.getWorld(), 97, 81, 627), EntityType.SKELETON);
        //Some things you can do to the entity
        entity.setGravity(false);
        entity.setGlowing(true);
        entity.setInvulnerable(true);
        entity.setCustomName("Daddy Skeletons");
        entity.setCustomNameVisible(true);


    }