add WoodenFish.java

This commit is contained in:
Yutousama 2022-11-04 10:25:17 +08:00
parent 0de499fb57
commit 85fbce9f4f
2 changed files with 37 additions and 1 deletions

View File

@ -0,0 +1,34 @@
package com.yutou.qqbot.models.Commands;
import com.yutou.qqbot.Annotations.UseModel;
import com.yutou.qqbot.QQBotManager;
import com.yutou.qqbot.models.Model;
import net.mamoe.mirai.event.events.MessageEvent;
import static com.yutou.qqbot.models.Model.QQGroupCommands.QQ_WOODEN;
@UseModel
public class WoodenFish extends Model {
@Override
public boolean isUserPublic() {
return false;
}
@Override
public String[] getUsePowers() {
return new String[]{QQ_WOODEN};
}
@Override
public String getModelName() {
return "电子木鱼";
}
@Override
public void onMessage(Long qq, MessageEvent event, boolean isGroup) {
super.onMessage(qq, event, isGroup);
if("地狱笑话".equals(msg)){
QQBotManager.getInstance().sendMessage(qq,"功德+1");
}
}
}

View File

@ -38,9 +38,11 @@ public abstract class Model implements ModelInterface {
public final static String BILI_LIVE_DANMU_SEND="!b站签到";
public final static String BILI_LIVE_DANMU_DEL="!b站签到删除";
public final static String QQ_WOODEN="!电子木鱼";
}
public static class QQFromCommands {
public static class QQFromCommands {
public static final String TURNIP_PROPHET = "大头菜";
public static final String TSDM_PAY = "!tsdm";
public static final String BAIDU_DOWN = "!bd";