|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import plugin from'../../lib/plugins/plugin.js' |
|
import{segment}from'oicq' |
|
import cfg from'../../lib/config/config.js' |
|
import common from'../../lib/common/common.js' |
|
const path=process.cwd() |
|
|
|
|
|
|
|
let reply_text = 0.15 |
|
let reply_img = 0.67 |
|
let reply_voice = 0.00 |
|
let mutepick = 0.02 |
|
let example = 0.08 |
|
|
|
|
|
|
|
|
|
const chuo_path=path+'/resources/chuochuo/'; |
|
|
|
|
|
const chuo_path2=path+'/resources/chuochuo2/' |
|
|
|
|
|
let jpg_number = 915 |
|
let gif_number = 2 |
|
|
|
|
|
let wav_number = 1 |
|
|
|
|
|
|
|
let word_list=['戳一次保底一次,嘻嘻', |
|
'痛QAQ...', |
|
'不要戳戳…', |
|
'旅行者,你深渊12层能一次过吗?', |
|
'快带我去玩!(打滚)', |
|
'哇,你这个人!', |
|
'我真的是栓Q', |
|
'(◦`~´◦)你个老六', |
|
'【保底七七概率+10%】', |
|
'【保底天空之卷概率+10%】', |
|
'【保底迪卢克概率+10%】', |
|
'【保底莫娜概率+10%】', |
|
'【保底琴概率+10%】', |
|
'【保底刻晴概率+10%】', |
|
'【保底风鹰剑概率+10%】', |
|
'【保底狼末概率+10%】', |
|
'【保底迪卢克概率+10%】', |
|
'【保底天空之刃概率+10%】', |
|
'【保底提纳里概率+10%】', |
|
'【保底阿莫斯之弓概率+10%】', |
|
'【保底和璞鸢概率+10%】', |
|
'【保底天空之脊概率+10%】', |
|
'【保底天空之傲概率+10%】', |
|
'【保底天空之翼概率+10%】', |
|
'【保底四风原典概率+10%】', |
|
'是哪个笨蛋在戳我?', |
|
'奖励你一只甜甜花酿鸡', |
|
'干点正事吧!', |
|
'这破群我是一点也待不下去了!', |
|
'可恶!', |
|
'囊哒哟~', |
|
'达咩!', |
|
'呜哇!', |
|
'你个坏蛋~', |
|
'(摇头)', |
|
'(后空翻)', |
|
'(劈叉)', |
|
'(惊醒)', |
|
'(楞)', |
|
'(眨眼)', |
|
'?', |
|
'气气!', |
|
'过分分!', |
|
'走开啦!', |
|
'੭ ᐕ)੭*⁾⁾', |
|
'`⌒´メ', |
|
'o(´^`)o', |
|
'(。’▽’。)♡', |
|
'(〟-_・)ン?', |
|
'Σ(°Д°;', |
|
'⋟﹏⋞', |
|
'◦˙▽˙◦', |
|
'ξ( ✿>◡❛)', |
|
'_(:3 ⌒゙)_', |
|
'(╯‵□′)╯︵┴─┴', |
|
'呜哇!我要给你起个难听的绰号!', |
|
'(宵宫拿走了旅行者仓库里的一把五星武器)', |
|
'【强化圣遗物时小防御拉满】', |
|
'【强化圣遗物时小生命拉满】', |
|
'【强化圣遗物时精通拉满】', |
|
'【强化圣遗物时小攻击拉满】', |
|
'【强化圣遗物时暴击率拉满】', |
|
'【强化圣遗物时暴击伤害拉满】', |
|
'吃我一拳!', |
|
'饿饿...', |
|
'讨厌!', |
|
'坏坏!', |
|
'哒咩,别戳了!', |
|
'呜哇!主人救命!', |
|
'你欺负我!', |
|
'充电的时候不可以戳啊,万一漏电了怎么办?', |
|
'QAQ呜哇啊啊啊啊啊!', |
|
'【旅行者命之座-1】', |
|
'【旅行者保底次数+1】', |
|
'【纠缠之缘-10】', |
|
'【空月祝福-30】', |
|
'【大冒险家的经验-100】', |
|
'【摩拉-300w】', |
|
'【原石-1600】', |
|
'(宵宫偷偷拿走了你3000w摩拉,买了甜甜花酿鸡)', |
|
'(宵宫想要拿走你的原石,但失败了...)', |
|
'(宵宫拿走了你背包里10个相遇之缘)', |
|
'QAQ..这个人欺负我…', |
|
'呜呜,要变笨啦!', |
|
'呜呜呜...你还戳QAQ', |
|
'再戳哭给你看!', |
|
'只给你戳一小会儿~', |
|
'虽然戳不坏,但我也是有脾气哒!', |
|
'别戳了别戳了><', |
|
'QAQ', |
|
'你怎么又戳我,气气!', |
|
]; |
|
|
|
|
|
export class chuo extends plugin{ |
|
constructor(){ |
|
super({ |
|
name: '戳一戳', |
|
dsc: '戳一戳机器人触发效果', |
|
event: 'notice.group.poke', |
|
priority: 50, |
|
rule: [ |
|
{ |
|
|
|
fnc: 'chuoyichuo' |
|
} |
|
] |
|
} |
|
) |
|
} |
|
|
|
|
|
async chuoyichuo (e){ |
|
logger.info('[戳一戳生效]') |
|
if(e.target_id == cfg.qq){ |
|
|
|
let random_type = Math.random() |
|
|
|
|
|
if(random_type < reply_text){ |
|
let text_number = Math.ceil(Math.random() * word_list['length']) |
|
await e.reply(word_list[text_number-1]) |
|
} |
|
|
|
|
|
|
|
else if(random_type < (reply_text + reply_img)){ |
|
|
|
let photo_number = Math.ceil(Math.random() * (jpg_number + gif_number)) |
|
|
|
if(photo_number<=jpg_number){ |
|
e.reply(segment.image('file:///' + path + '/resources/chuochuo/'+ photo_number + '.jpg')) |
|
} |
|
else{ |
|
photo_number = photo_number - jpg_number |
|
e.reply(segment.image('file:///' + path + '/resources/chuochuo/'+ photo_number + '.gif')) |
|
} |
|
|
|
} |
|
|
|
|
|
else if(random_type < (reply_text + reply_img + reply_voice)){ |
|
|
|
let voice_number = Math.ceil(Math.random() * (wav_number)) |
|
|
|
if(voice_number<=wav_number){ |
|
e.reply(segment.record('file:///' + path + '/resources/chuochuo2/'+ voice_number + '.wav')) |
|
} |
|
} |
|
|
|
else if(random_type < (reply_text + reply_img + reply_voice + mutepick)){ |
|
|
|
let mutetype = Math.ceil(Math.random() * 2) |
|
if(mutetype == 1){ |
|
e.reply('说了不要戳了!') |
|
await common.sleep(1000) |
|
await e.group.muteMember(e.operator_id,60); |
|
await common.sleep(3000) |
|
e.reply('啧') |
|
|
|
|
|
} |
|
else if (mutetype == 2){ |
|
e.reply('不!!') |
|
await common.sleep(500); |
|
e.reply('准!!') |
|
await common.sleep(500); |
|
e.reply('戳!!') |
|
await common.sleep(1000); |
|
await e.group.muteMember(e.operator_id,60) |
|
} |
|
} |
|
|
|
|
|
else if(random_type < (reply_text + reply_img + reply_voice + mutepick + example)){ |
|
await e.reply(await segment.image(`http://ovooa.com/API/face_pat/?QQ=${e.operator_id}`)) |
|
} |
|
|
|
|
|
else { |
|
e.reply('反击!') |
|
await common.sleep(1000) |
|
await e.group.pokeMember(e.operator_id) |
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |