blob: 0ce483a20d480915372481e7cea19f9bf9b220b2 (
plain)
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
package bjc.utils.dice;
/**
* Class that produces common polyhedral dice
*
* @author ben
*
*/
public class PolyhedralDice {
/**
* Produce the specified number of 10-sided dice
*
* @param nDice
* The number of ten-sided dice to produce
* @return A group of ten-sided dice of the specified size
*/
public static LazyDice d10(int nDice) {
return new LazyDice(nDice, 10);
}
/**
* Produce the specified number of 100-sided dice
*
* @param nDice
* The number of hundred-sided dice to produce
* @return A group of hundred-sided dice of the specified size
*/
public static LazyDice d100(int nDice) {
return new LazyDice(nDice, 100);
}
/**
* Produce the specified number of 12-sided dice
*
* @param nDice
* The number of twelve-sided dice to produce
* @return A group of twelve-sided dice of the specified size
*/
public static LazyDice d12(int nDice) {
return new LazyDice(nDice, 12);
}
/**
* Produce the specified number of 20-sided dice
*
* @param nDice
* The number of twenty-sided dice to produce
* @return A group of twenty-sided dice of the specified size
*/
public static LazyDice d20(int nDice) {
return new LazyDice(nDice, 20);
}
/**
* Produce the specified number of 10-sided dice
*
* @param nDice
* The number of ten-sided dice to produce
* @return A group of ten-sided dice of the specified size
*/
public static LazyDice d4(int nDice) {
return new LazyDice(nDice, 4);
}
/**
* Produce the specified number of 10-sided dice
*
* @param nDice
* The number of ten-sided dice to produce
* @return A group of ten-sided dice of the specified size
*/
public static LazyDice d6(int nDice) {
return new LazyDice(nDice, 6);
}
/**
* Produce the specified number of 10-sided dice
*
* @param nDice
* The number of ten-sided dice to produce
* @return A group of ten-sided dice of the specified size
*/
public static LazyDice d8(int nDice) {
return new LazyDice(nDice, 8);
}
}
|