-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathWarrior.java
55 lines (44 loc) · 1004 Bytes
/
Warrior.java
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
//Minh Thao
public abstract class Warrior
{
protected String name;
protected int IQ;
protected int strength;
protected String clique;
public Warrior(String n, String sc)
{
name = n;
clique = sc;
generateStats();
clique.toLowerCase();
}
public abstract void generateStats();
public abstract void victory();
public boolean errorCheck()
{
if(clique.equals("freak") || clique.equals("thug") || clique.equals("prep") || clique.equals("jock") || clique.equals("nerd"))
{
return true;
}
else
{
return false;
}
}
public String getName()
{
return name;
}
public int getStrength()
{
return strength;
}
public int getIQ()
{
return IQ;
}
public String toString()
{
return "Name:" + name + " Clique:" + clique + " IQ:" + IQ + " Strength:" + strength;
}
}