Window_Base.prototype.drawActorHp = function(actor, wx, wy, ww) {
ww = ww || 186;
var color1 = this.hpGaugeColor1();
var color2 = this.hpGaugeColor2();
if (actor.barrierPoints() > 0) {//如果有护盾,则绘制护盾状态
color1 = this.textColor(8);//如果有护盾则改变血条颜色1
color2 = this.textColor(7);//如果有护盾则改变血条颜色2
this.drawGauge(wx, wy, ww, actor.hpRate(), color1, color2);
this.drawBarrierGauge(actor, wx+5, wy+45, ww);//绘制护盾图标,wx和wy是位置
}else{
this.drawGauge(wx, wy, ww, actor.hpRate(), color1, color2);
}
this.changeTextColor(this.systemColor());
var c1 = this.hpColor(actor);
var c2 = this.normalColor();
this.drawCurrentAndMax(actor.hp, actor.mhp, wx, wy+10, ww, c1, c2);
};
Window_Base.prototype.drawBarrierGauge = function(actor, wx, wy, ww) {
var ph = Window_Base._iconHeight;
this.drawIcon(90,wx,wy-ph);
this.drawText(actor.barrierPoints(), wx, wy-ph-3, 32,'center');
}
Window_Base.prototype.drawActorHp = function(actor, wx, wy, ww) {
ww = ww || 186;
var color1 = this.hpGaugeColor1();
var color2 = this.hpGaugeColor2();
if (actor.barrierPoints() > 0) {//如果有护盾,则绘制护盾状态
color1 = this.textColor(8);//如果有护盾则改变血条颜色1
color2 = this.textColor(7);//如果有护盾则改变血条颜色2
this.drawGauge(wx, wy, ww, actor.hpRate(), color1, color2);
this.drawBarrierGauge(actor, wx+5, wy+45, ww);//绘制护盾图标,wx和wy是位置
}else{
this.drawGauge(wx, wy, ww, actor.hpRate(), color1, color2);
}
this.changeTextColor(this.systemColor());
var c1 = this.hpColor(actor);
var c2 = this.normalColor();
this.drawCurrentAndMax(actor.hp, actor.mhp, wx, wy+10, ww, c1, c2);
};
Window_Base.prototype.drawBarrierGauge = function(actor, wx, wy, ww) {
var ph = Window_Base._iconHeight;
this.drawIcon(90,wx,wy-ph);
this.drawText(actor.barrierPoints(), wx, wy-ph-3, 32,'center');
}