Merge pull request #18 from ChugerXiao/master

pcr gacha update add at
This commit is contained in:
SiHuan 2020-08-16 20:26:28 +08:00 committed by GitHub
commit 90c4e23538
2 changed files with 5 additions and 3 deletions

2
.gitignore vendored
View file

@ -2,3 +2,5 @@ env
__pycache__ __pycache__
.vscode .vscode
config.py config.py
.idea
test.py

View file

@ -320,7 +320,7 @@ class Ans(StdAns):
resultStar.append(2) resultStar.append(2)
resultName.append(choice(star2)) resultName.append(choice(star2))
stones = 0 stones = 0
colors = '' colors = '[CQ:at,qq={}]\n'.format(self.uid)
for each in range(len(resultStar)): for each in range(len(resultStar)):
if resultStar[each] == 3: if resultStar[each] == 3:
stones = stones + 50 stones = stones + 50
@ -335,7 +335,7 @@ class Ans(StdAns):
else:colors = colors + color + ' ' else:colors = colors + color + ' '
name = '' name = ''
for each in range(len(resultName)): for each in range(len(resultName)):
if each == 4:name = name + resultName[each] + '\n' if each == 4: name = name + resultName[each] + '\n'
else:name = name + resultName[each] + ' ' else:name = name + resultName[each] + ' '
name = name + '\n母猪石 +{} [CQ:face,id=108]'.format(stones) name = name + '\n母猪石 +{} [CQ:face,id=108]'.format(stones)
self.sendmsg(colors) self.sendmsg(colors)