Examples of Fireball


Examples of me.ashtheking.dragons.meta.Fireball

        {
        double d5 = targetedEntity.posX - dragonHead.posX;
        double d6 = (targetedEntity.boundingBox.minY + (double) (targetedEntity.height / 2.0F))
            - (dragonHead.posY + (double) (dragonHead.height / 2.0F) - 10);
        double d7 = targetedEntity.posZ - dragonHead.posZ;
        Fireball entityfireball = new Fireball(worldObj, this, d5, d6,
            d7);
        double d8 = 2D;
        Vec3D vec3d = getLook(1.0F);
        entityfireball.posX = dragonHead.posX + vec3d.xCoord * d8;
        entityfireball.posY = dragonHead.posY - 2;
          //  + (double) (dragonHead.height / 2.0F) + 0.5D;
        entityfireball.posZ = dragonHead.posZ + vec3d.zCoord * d8;
        for (int x = 0; x < 3; x++)
          entityfireball.onUpdate();
       
        entityfireball.motionX *= 2;
        entityfireball.motionY *= 2;
        entityfireball.motionZ *= 2;
     
View Full Code Here

Examples of org.bukkit.entity.Fireball

    }
   
    Player player = (Player) sender;
    Location eye = player.getEyeLocation().add(0.5, 0.5, 0.5);
    Vector v = eye.getDirection().multiply(2);
    Fireball entity = player.getWorld().spawn(eye.add(v.getX(), v.getY(), v.getZ()), (!smallFireball ? Fireball.class : SmallFireball.class));
    entity.setShooter(player);
    entity.setVelocity(eye.getDirection().multiply(2));
   
    LogHelper.showInfo("fireballSuccess", sender);
    return true;
  }
View Full Code Here

Examples of org.bukkit.entity.Fireball

      }
    }
   
    // normal fireball
    if (killer instanceof Fireball){
      Fireball fireball = (Fireball) killer;
      // check if ghast
      if (fireball.getShooter() instanceof Ghast){
        message = replacements(config.getString("deathGhast"), victim);
      }
     
      // check if blaze
      if (fireball.getShooter() instanceof Blaze){
        message = replacements(config.getString("deathBlaze"), victim);
      }
    }
   
    if (message != null){
View Full Code Here

Examples of org.bukkit.entity.Fireball

    for (final Object shooter : shooters.getArray(e)) {
      for (final EntityData<?> d : types.getArray(e)) {
        if (shooter instanceof LivingEntity) {
          final Vector vel = dir.getDirection(((LivingEntity) shooter).getLocation()).multiply(v.doubleValue());
          if (Fireball.class.isAssignableFrom(d.getType())) {// fireballs explode in the shooter's face by default
            final Fireball projectile = (Fireball) ((LivingEntity) shooter).getWorld().spawn(((LivingEntity) shooter).getEyeLocation().add(vel.clone().normalize().multiply(0.5)), d.getType());
            ProjectileUtils.setShooter(projectile, shooter);
            projectile.setVelocity(vel);
            lastSpawned = projectile;
          } else if (Projectile.class.isAssignableFrom(d.getType())) {
            final Projectile projectile = ((LivingEntity) shooter).launchProjectile((Class<? extends Projectile>) d.getType());
            set(projectile, d);
            projectile.setVelocity(vel);
            lastSpawned = projectile;
          } else {
            final Location loc = ((LivingEntity) shooter).getLocation();
            loc.setY(loc.getY() + ((LivingEntity) shooter).getEyeHeight() / 2);
            final Entity projectile = d.spawn(loc);
            if (projectile != null)
              projectile.setVelocity(vel);
            lastSpawned = projectile;
          }
        } else {
          final Vector vel = dir.getDirection((Location) shooter).multiply(v.doubleValue());
          final Entity projectile = d.spawn((Location) shooter);
          if (projectile != null)
            projectile.setVelocity(vel);
          lastSpawned = projectile;
        }
      }
    }
  }
View Full Code Here

Examples of spells.FireBall

  public static BufferedImage ranbowLazer2=null;
  public static void LoadPictures(){
    try {
      //populate map!!!
      effectiveMap=new ConcurrentHashMap<Integer,Entity>();
      effectiveMap.put(FireBall.type, new FireBall(-100,0,0,null));
      effectiveMap.put(BasicTestUnit.type, new BasicTestUnit(-100,0,null));
      effectiveMap.put(RainbowCannon.type, new RainbowCannon(0,0,0,null));
      //if char select put certain char
      ranbowLazer1=ImageIO.read(new File("rainbowLazer1.png"));
      ranbowLazer2=ImageIO.read(new File("rainbowLazer3.png"));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.