伤害弹出
This commit is contained in:
parent
e0ed30be3b
commit
9d2c199a1e
@ -1140,7 +1140,8 @@ var data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d =
|
|||||||
"flags": {
|
"flags": {
|
||||||
"itemDetail": true,
|
"itemDetail": true,
|
||||||
"useBetweenLight": true,
|
"useBetweenLight": true,
|
||||||
"__mdef_buff__": 0
|
"__mdef_buff__": 0,
|
||||||
|
"popmove": true
|
||||||
},
|
},
|
||||||
"followers": [],
|
"followers": [],
|
||||||
"steps": 0,
|
"steps": 0,
|
||||||
|
@ -1869,54 +1869,49 @@ var functions_d6ad677b_427a_4623_b50f_a445a3b0ef8a =
|
|||||||
// core.stopAutomaticRoute();
|
// core.stopAutomaticRoute();
|
||||||
},
|
},
|
||||||
"moveDirectly": function (x, y, ignoreSteps) {
|
"moveDirectly": function (x, y, ignoreSteps) {
|
||||||
// 瞬间移动;x,y为要瞬间移动的点;ignoreSteps为减少的步数,可能之前已经被计算过
|
// 瞬间移动;x,y为要瞬间移动的点;ignoreSteps为减少的步数,可能之前已经被计算过
|
||||||
// 返回true代表成功瞬移,false代表没有成功瞬移
|
// 返回true代表成功瞬移,false代表没有成功瞬移
|
||||||
|
|
||||||
// 判定能否瞬移到该点
|
// 判定能否瞬移到该点
|
||||||
if (ignoreSteps == null) ignoreSteps = core.canMoveDirectly(x, y);
|
if (ignoreSteps == null) ignoreSteps = core.canMoveDirectly(x, y);
|
||||||
if (ignoreSteps >= 0) {
|
if (ignoreSteps >= 0) {
|
||||||
// 中毒也允许瞬移
|
// 中毒也允许瞬移
|
||||||
if (core.hasFlag("poison")) {
|
if (core.hasFlag("poison")) {
|
||||||
var damage = ignoreSteps * core.values.poisonDamage;
|
var damage = ignoreSteps * core.values.poisonDamage;
|
||||||
if (damage >= core.status.hero.hp) return false;
|
if (damage >= core.status.hero.hp) return false;
|
||||||
core.status.hero.statistics.poisonDamage += damage;
|
core.status.hero.statistics.poisonDamage += damage;
|
||||||
core.status.hero.hp -= damage;
|
core.status.hero.hp -= damage;
|
||||||
}
|
}
|
||||||
|
|
||||||
core.clearMap("hero");
|
core.clearMap("hero");
|
||||||
if (
|
if (
|
||||||
core.bigmap.width * 32 === core.bigmap.height * 32 &&
|
core.bigmap.width * 32 === core.bigmap.height * 32 &&
|
||||||
core.bigmap.width * 32 === core.__PIXELS__
|
core.bigmap.width * 32 === core.__PIXELS__
|
||||||
)
|
)
|
||||||
core.addPopMove(
|
if (core.getFlag('popmove')) core.addPopMove(32 * core.status.hero.loc.x + 16, 32 * core.status.hero.loc.y + 16, 32 * x + 16, 32 * y + 16);
|
||||||
32 * core.status.hero.loc.x + 16,
|
// 获得勇士最后的朝向
|
||||||
32 * core.status.hero.loc.y + 16,
|
var lastDirection = core.status.route[core.status.route.length - 1];
|
||||||
32 * x + 16,
|
if (["left", "right", "up", "down"].indexOf(lastDirection) >= 0)
|
||||||
32 * y + 16
|
core.setHeroLoc("direction", lastDirection);
|
||||||
);
|
// 设置坐标,并绘制
|
||||||
// 获得勇士最后的朝向
|
core.control._moveDirectyFollowers(x, y);
|
||||||
var lastDirection = core.status.route[core.status.route.length - 1];
|
core.status.hero.loc.x = x;
|
||||||
if (["left", "right", "up", "down"].indexOf(lastDirection) >= 0)
|
core.status.hero.loc.y = y;
|
||||||
core.setHeroLoc("direction", lastDirection);
|
core.drawHero();
|
||||||
// 设置坐标,并绘制
|
// 记录录像
|
||||||
core.control._moveDirectyFollowers(x, y);
|
core.status.route.push("move:" + x + ":" + y);
|
||||||
core.status.hero.loc.x = x;
|
// 统计信息
|
||||||
core.status.hero.loc.y = y;
|
core.status.hero.statistics.moveDirectly++;
|
||||||
core.drawHero();
|
core.status.hero.statistics.ignoreSteps += ignoreSteps;
|
||||||
// 记录录像
|
if (core.hasFlag("poison")) {
|
||||||
core.status.route.push("move:" + x + ":" + y);
|
core.updateStatusBar(false, true);
|
||||||
// 统计信息
|
}
|
||||||
core.status.hero.statistics.moveDirectly++;
|
|
||||||
core.status.hero.statistics.ignoreSteps += ignoreSteps;
|
|
||||||
if (core.hasFlag("poison")) {
|
|
||||||
core.updateStatusBar(false, true);
|
|
||||||
}
|
|
||||||
|
|
||||||
core.checkRouteFolding();
|
core.checkRouteFolding();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
},
|
},
|
||||||
"parallelDo": function (timestamp) {
|
"parallelDo": function (timestamp) {
|
||||||
// 并行事件处理,可以在这里写任何需要并行处理的脚本或事件
|
// 并行事件处理,可以在这里写任何需要并行处理的脚本或事件
|
||||||
// 该函数将被系统反复执行,每次执行间隔视浏览器或设备性能而定,一般约为16.6ms一次
|
// 该函数将被系统反复执行,每次执行间隔视浏览器或设备性能而定,一般约为16.6ms一次
|
||||||
|
2156
project/plugins.js
2156
project/plugins.js
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user