-
Notifications
You must be signed in to change notification settings - Fork 0
/
SpellPicker.h
70 lines (70 loc) · 1.54 KB
/
SpellPicker.h
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
int spellPicker(int rarity)
{
int sid;
int prob;
prob = rand() % 7 + 1;
if(prob<=3)
{
switch(rarity)
{
case 1:
sid = rand() % 3 + 300;
break;
case 2:
sid = rand() % 3 + 303;
break;
case 3:
sid = rand() % 3 + 306;
break;
case 4:
sid = rand() % 3 + 309;
break;
case 5:
sid = rand() % 3 + 312;
break;
}
}
else if(prob<=5)
{
switch(rarity)
{
case 1:
sid = 315;
break;
case 2:
sid = rand() % 2 + 316;
break;
case 3:
sid = 318;
break;
case 4:
sid = 319;
break;
case 5:
sid = 320;
break;
}
}
else if(prob<=7)
{
switch(rarity)
{
case 1:
sid = rand() % 5 + 321;
break;
case 2:
sid = rand() % 5 + 326;
break;
case 3:
sid = rand() % 5 + 331;
break;
case 4:
sid = rand() % 6 + 336;
break;
case 5:
sid = 342;
break;
}
}
return sid;
}