GunRage.java :  » Java-2D » plar » res » elements » Java Open Source

Java Open Source » Java 2D » plar 
plar » res » elements » GunRage.java
/*  
  PlAr is Platform Arena: a 2D multiplayer shooting game
  Copyright (c) 2010, Antonio Ragagnin <spocchio@gmail.com>
    All rights reserved.
*/

package res.elements;

import org.jbox2d.common.Vec2;

import plar.core.Gun;

import plar.core.ElementBullet;

public class GunRage extends Gun {

  public GunRage() {
    super();
    gunName = "Rage Gun";
    gunUseAmmo = 1;

  }

  public void createBullet() {

    ElementBullet shoot = new ElementBullet();
    shoot.hitDamage = 100;
    shoot.setSpeed(new Vec2(100 * D().x, 100 * D().y));
    initializeShoot(shoot);
    addAmmo(-gunUseAmmo);

  }

}
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.