涩图模块:图源改成regular,减少图片大小

管理员模块:支持this关键词标识本群
This commit is contained in:
2022-04-17 15:47:12 +08:00
parent 10fd1d6863
commit 4dfbee6d08
3 changed files with 10 additions and 6 deletions

View File

@@ -44,15 +44,15 @@ public class GetSeTu extends Model {
if (isRun) {
Log.i(event.getSource().getFromId() + " > " + msg);
String key = msg.replace("来点", "").replace("色图", "").replace("涩图", "");
String url = "https://api.lolicon.app/setu/v2?r18=0";
String url = "https://api.lolicon.app/setu/v2?r18=0&size=regular";
if (isR18) {
url = "https://api.lolicon.app/setu/v2?r18=1";
url = "https://api.lolicon.app/setu/v2?r18=1&size=regular";
}
if (!StringUtils.isEmpty(key)) {
if (isR18) {
url = "https://api.lolicon.app/setu/v2?tag=" + URLEncoder.encode(key, StandardCharsets.UTF_8) + "&r18=1";
url = "https://api.lolicon.app/setu/v2?tag=" + URLEncoder.encode(key, StandardCharsets.UTF_8) + "&r18=1&size=regular";
} else {
url = "https://api.lolicon.app/setu/v2?tag=" + URLEncoder.encode(key, StandardCharsets.UTF_8) + "&r18=0";
url = "https://api.lolicon.app/setu/v2?tag=" + URLEncoder.encode(key, StandardCharsets.UTF_8) + "&r18=0&size=regular";
}
}
String ret = HttpTools.get(url);