-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathNpc1.java
More file actions
51 lines (51 loc) · 1.22 KB
/
Copy pathNpc1.java
File metadata and controls
51 lines (51 loc) · 1.22 KB
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
public class Npc1 extends Npc
{
private static String name = "Walter";
private static Npc1 npc1;
private Npc1()
{
super(name);
}
public static Npc1 getNpc1()
{
if(npc1 == null)
{
npc1 = new Npc1();
}
return npc1;
}
@Override
public void dialogue1()
{
System.out.println("Good morning, Recruits! My name is "+this.name+
" and I am the Town Elder of our fine village.");
}
@Override
public void dialogue2()
{
System.out.println("I'm sure you are all aware of why we are asking "+
"the local community to enlist in the village defense:\n"+
"the rumours that the Witchmaster's army is moving south.\n");
}
@Override
public void dialogue3()
{
System.out.println("A village our size shouldn't be of interest to the Witchmaster,\n"+
"but we cannot be too careful in these perilous times.\n");
}
@Override
public void dialogue4()
{
System.out.println("All of you will get tasks to help defend our village.\n");
}
@Override
public void dialogue5()
{
System.out.println("You there? You can start by visiting Captain Angmar and follow his orders.\n");
}
@Override
public void dialogue6()
{
System.out.println("Good day. Thank you for joining the defense training group.\n");
}
}