changeFloor symmetry point
This commit is contained in:
1 parent
22f8927708
commit
a57771d1bf
4 files changed
+31
-9
No files matched your search
+12
-1
@@ -548,8 +548,19 @@ events.prototype._changeFloor_getHeroLoc = function (floorId, stair, heroLoc) {
|
||||
if (!heroLoc)
|
||||
heroLoc = core.clone(core.status.hero.loc);
|
||||
if (stair) {
|
||||
// --- 对称
|
||||
if (stair == ':now')
|
||||
heroLoc = core.clone(core.status.hero.loc);
|
||||
else if (stair == ':symmetry') {
|
||||
heroLoc.x = core.bigmap.width - 1 - core.getHeroLoc('x');
|
||||
heroLoc.y = core.bigmap.height - 1 - core.getHeroLoc('y');
|
||||
}
|
||||
else if (stair == ':symmetry_x')
|
||||
heroLoc.x = core.bigmap.width - 1 - core.getHeroLoc('x');
|
||||
else if (stair == ':symmetry_y')
|
||||
heroLoc.y = core.bigmap.height - 1 - core.getHeroLoc('y');
|
||||
// 检查该层地图的 upFloor & downFloor
|
||||
if (core.status.maps[floorId][stair]) {
|
||||
else if (core.status.maps[floorId][stair]) {
|
||||
heroLoc.x = core.status.maps[floorId][stair][0];
|
||||
heroLoc.y = core.status.maps[floorId][stair][1];
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user