mirror of
https://github.com/wassname/phaser-plugin-isometric.git
synced 2026-09-09 11:28:50 +08:00
Added back z calculation into depth sorting, though it's still not quite right.
This commit is contained in:
Vendored
+2
-2
@@ -53,7 +53,7 @@ Phaser.Plugin.Isometric = function (game, parent) {
|
||||
Phaser.Plugin.Isometric.prototype = Object.create(Phaser.Plugin.prototype);
|
||||
Phaser.Plugin.Isometric.prototype.constructor = Phaser.Plugin.Isometric;
|
||||
|
||||
Phaser.Plugin.Isometric.VERSION = '0.7.3';
|
||||
Phaser.Plugin.Isometric.VERSION = '0.7.4';
|
||||
|
||||
// Directional consts
|
||||
Phaser.Plugin.Isometric.UP = 0;
|
||||
@@ -829,7 +829,7 @@ Object.defineProperty(Phaser.Plugin.Isometric.IsoSprite.prototype, "isoPosition"
|
||||
Object.defineProperty(Phaser.Plugin.Isometric.IsoSprite.prototype, "depth", {
|
||||
get: function () {
|
||||
if (this._depthChanged === true) {
|
||||
this._depth = (this._isoPosition.x + this._isoPosition.y);
|
||||
this._depth = (this._isoPosition.x + this._isoPosition.y) + (this._isoPosition.z * 0.95);
|
||||
this._depthChanged = false;
|
||||
}
|
||||
return this._depth;
|
||||
|
||||
Vendored
+2
-2
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user