File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ Random pick music, smart play
44### Idea:💡
55| - | Love Story | 东风破 | Refrain | Tassel| - |
66| -------| :----------:| -------:| -------:| ------:| -----------:|
7- | 次序 | weight | weight | weight | weight| picked |
7+ | sequence | weight | weight | weight | weight| picked |
88| 1 | 1 | 1 | 1 | 1 | 东风破 |
99| 2 | 2 | 0 | 2 | 2 | Love Story |
1010| 3 | 0 | 1 | 3 | 3 | Refrain |
@@ -17,5 +17,24 @@ Random pick music, smart play
1717| 10 | 1 | 2 | 6 | 0 | ... |
1818...
1919
20+ ### Demo
2021![ RandomPicker] ( https://raw.githubusercontent.com/XunMengWinter/source/master/gif/RandomPicker.gif )
2122
23+ ### How to use
24+ Quick start:
25+ ```
26+ RandomPicker randomPicker = new RandomPicker(12);
27+ int nextPos = randomPicker.next();
28+ ```
29+ More function:
30+ ```
31+ randomPicker.setMultiplyNumber(3);
32+ randomPicker.setAddNumber(2);
33+ randomPicker.setNextPick(5);
34+ randomPicker.add();
35+ randomPicker.changeOriginWeight(0,3);
36+ randomPicker.getHistoryList();
37+ ```
38+ More more function:
39+ download this repo and watch the code.
40+
You can’t perform that action at this time.
0 commit comments