赞 | 17 |
VIP | 0 |
好人卡 | 0 |
积分 | 53 |
经验 | 0 |
最后登录 | 2024-11-17 |
在线时间 | 724 小时 |
Lv4.逐梦者
- 梦石
- 0
- 星屑
- 5297
- 在线时间
- 724 小时
- 注册时间
- 2022-11-26
- 帖子
- 323
|
本帖最后由 余杭 于 2023-4-10 23:04 编辑
这样可以满足条件二,你这个要求心电图的样式我没见过,也不知道怎么做。
用这个需要在插件里安装 Drill 大佬的 Drill_CoreOfColor.js 插件才能用。
color123 的 [] 里面的数字就是 Drill_CoreOfColor 中的颜色。
想要去掉血量数字的话就把最后 drawCurrentAndMax 那一行注释掉或者删掉。
Window_Base.prototype.drawGaugeHHPP = function(x, y, width, rate, color1, color2, color3) { var fillW = Math.floor(width * 1); var gaugeY = y + this.lineHeight() - 18; this.contents.fillRect(x, gaugeY, width, 16, this.gaugeBackColor()); if (rate <=0.25) { this.contents.gradientFillRect(x, gaugeY, fillW, 16, color1, color1); } else if (rate <= 0.75) { this.contents.gradientFillRect(x, gaugeY, fillW, 16, color2, color2); } else { this.contents.gradientFillRect(x, gaugeY, fillW, 16, color3, color3); } }; Window_Base.prototype.drawActorHp = function(actor, x, y, width) { width = width || 186; var DrillColors = DrillUp.g_COC_color_list; var color1 = DrillColors[1].color; var color2 = DrillColors[2].color; var color3 = DrillColors[3].color; this.drawGaugeHHPP(x, y, width, actor.hpRate(), color1, color2, color3); // this.drawGauge(x, y, width, actor.hpRate(), color1, color2); this.changeTextColor(this.systemColor()); this.drawText(TextManager.hpA, x, y, 44); this.drawCurrentAndMax(actor.hp, actor.mhp, x, y, width, this.hpColor(actor), this.normalColor()); };
Window_Base.prototype.drawGaugeHHPP = function(x, y, width, rate, color1, color2, color3) {
var fillW = Math.floor(width * 1);
var gaugeY = y + this.lineHeight() - 18;
this.contents.fillRect(x, gaugeY, width, 16, this.gaugeBackColor());
if (rate <=0.25) {
this.contents.gradientFillRect(x, gaugeY, fillW, 16, color1, color1);
} else if (rate <= 0.75) {
this.contents.gradientFillRect(x, gaugeY, fillW, 16, color2, color2);
} else {
this.contents.gradientFillRect(x, gaugeY, fillW, 16, color3, color3);
}
};
Window_Base.prototype.drawActorHp = function(actor, x, y, width) {
width = width || 186;
var DrillColors = DrillUp.g_COC_color_list;
var color1 = DrillColors[1].color;
var color2 = DrillColors[2].color;
var color3 = DrillColors[3].color;
this.drawGaugeHHPP(x, y, width, actor.hpRate(), color1, color2, color3);
// this.drawGauge(x, y, width, actor.hpRate(), color1, color2);
this.changeTextColor(this.systemColor());
this.drawText(TextManager.hpA, x, y, 44);
this.drawCurrentAndMax(actor.hp, actor.mhp, x, y, width, this.hpColor(actor), this.normalColor());
};
|
|