-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathEquipment.java
56 lines (46 loc) · 1.07 KB
/
Equipment.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
56
/**
* You can name you equipment anything that you want and then use the name
* as a test. So if you create a key, you could say if(equipment1.name.equals("Key")
* open door.
*/
public class Equipment {
public String name;
public int weight;
/**
* Create a new Equipment.
* @param name
* @param weight
*/
public Equipment(String name, int weight) {
this.name = name;
this.weight = weight;
}
/**
* Return a name of the item.
* @return the name
*/
public String getName() {
return name;
}
/**
* Define the name of the item.
* @param name the name to set
*/
public void setName(String name) {
this.name = name;
}
/**
* Return a description of the item. *
* @return the description
*/
public int getWeight() {
return weight;
}
/**
* Define the description of the item.
* @param description the description to set
*/
public void setWeight(int weight) {
this.weight = weight;
}
}