-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathEarthTower.java
More file actions
31 lines (27 loc) · 839 Bytes
/
EarthTower.java
File metadata and controls
31 lines (27 loc) · 839 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
*Creates a Earth Tower, and changes mutates the characteristics of a generic <br>
* tower when constructed. All actions are done within the superclass.
*
* @author (Terence Lai)
*/
public class EarthTower extends Tower
{
public EarthTower()
{
fileName = "Towers/e";
setImage("Towers/e1.png");
attackRate = 20; // rate at which it attak
range = 500; // maxiumum range of the tower
speed = 15;// speed of the projectile
power = 2;
counter = attackRate;
element = 4;
elementString = "earth";
name = "Earth Tower";
cost = 10;
desc.add ("A long range tower");
desc.add ("Low damage,");
desc.add ("Medium attack rate");
}
}