Commit 75054211 authored by zjz1994's avatar zjz1994

调整图和垃圾桶检测区域

parent 4e6c7a50
This diff is collapsed.
......@@ -18,6 +18,7 @@
inst.source = 'asset://' + engine.getAssetByName(name).uuid;
return inst;
}
//# sourceMappingURL=utils.js.map
var props = {};
function prepareProps() {
......@@ -27,6 +28,7 @@
function injectProps(p) {
engine.injectProp(props, p);
}
//# sourceMappingURL=props.js.map
var Conveyor = (function (_super) {
tslib.__extends(Conveyor, _super);
......@@ -62,6 +64,7 @@
};
return Conveyor;
}(engine.Sprite));
//# sourceMappingURL=Conveyor.js.map
var GarbageTypes;
(function (GarbageTypes) {
......@@ -70,6 +73,7 @@
GarbageTypes["wetWaste"] = "wetWaste";
GarbageTypes["dryWaste"] = "dryWaste";
})(GarbageTypes || (GarbageTypes = {}));
//# sourceMappingURL=GarbageTypes.js.map
var GarbageConfig = (function () {
function GarbageConfig() {
......@@ -128,6 +132,7 @@
];
return GarbageConfig;
}());
//# sourceMappingURL=GarbageConfig.js.map
var transStores = (function (list) {
var tmp = [];
......@@ -187,6 +192,7 @@
return '其他垃圾';
}
};
//# sourceMappingURL=transStores.js.map
var checkHit = (function (view, rect) {
var x = view.x, y = view.y;
......@@ -196,12 +202,14 @@
}
return false;
});
//# sourceMappingURL=checkHit.js.map
var removeChild = (function (d) {
if (d && d.parent) {
d.parent.removeChild(d);
}
});
//# sourceMappingURL=removeChild.js.map
var removeEle = (function (e, arr) {
var index = arr.indexOf(e);
......@@ -209,6 +217,7 @@
arr.splice(index, 1);
}
});
//# sourceMappingURL=removeEle.js.map
var shuffle = (function (arr) {
var _a;
......@@ -219,6 +228,7 @@
}
return arr;
});
//# sourceMappingURL=shuffle.js.map
var WrongTips = (function (_super) {
tslib.__extends(WrongTips, _super);
......@@ -263,6 +273,7 @@
return gameview.recoverableWaste;
}
};
//# sourceMappingURL=WrongTips.js.map
var Conveyors = (function (_super) {
tslib.__extends(Conveyors, _super);
......@@ -532,6 +543,7 @@
};
return Conveyors;
}(engine.Sprite));
//# sourceMappingURL=Conveyors.js.map
var uiConfig = (function () {
return [
......@@ -583,6 +595,7 @@
},
];
});
//# sourceMappingURL=uiConfig.js.map
var getGuideInfo = (function () {
if (!window.localStorage) {
......@@ -594,6 +607,7 @@
if (window.localStorage)
localStorage.setItem('recyclingGuide', '1');
};
//# sourceMappingURL=getGuideInfo.js.map
var createBg = (function (a) {
if (a === void 0) { a = 1; }
......@@ -604,10 +618,12 @@
rect.alpha = a;
return rect;
});
//# sourceMappingURL=createBg.js.map
var createImg = (function (texture) {
return new engine.Sprite(getTextureByName(texture));
});
//# sourceMappingURL=createImg.js.map
var CountDownGroup = (function (_super) {
tslib.__extends(CountDownGroup, _super);
......@@ -691,6 +707,7 @@
};
return CountDownGroup;
}(engine.Sprite));
//# sourceMappingURL=CountDownGroup.js.map
var GuideView = (function (_super) {
tslib.__extends(GuideView, _super);
......@@ -706,8 +723,8 @@
this.addChild(this.guideBg);
this.guideEle = createImg('guideEle');
this.addChild(this.guideEle);
this.guideBg.x = 393;
this.guideBg.y = 552;
this.guideBg.x = 403;
this.guideBg.y = 565;
this.guideEle.x = 361;
this.guideEle.y = 877;
this.guideEle.anchorX = 14;
......@@ -720,7 +737,7 @@
svga.mouseEnabled = svga.mouseChildren = false;
};
GuideView.prototype.checkHit = function (x, y, w, h) {
var rect = new engine.Rectangle(393, 552, 281, 320);
var rect = new engine.Rectangle(403, 565, 252, 297);
if (x > rect.x && y > rect.y && (x + w) < (rect.x + rect.width) && (y + h) < (rect.y + rect.height)) {
return true;
}
......@@ -775,6 +792,7 @@
};
return GuideView;
}(engine.Sprite));
//# sourceMappingURL=guideView.js.map
var RightTips = (function (_super) {
tslib.__extends(RightTips, _super);
......@@ -813,6 +831,7 @@
};
return RightTips;
}(engine.Sprite));
//# sourceMappingURL=RightTips.js.map
var GameView = (function (_super) {
tslib.__extends(GameView, _super);
......@@ -857,10 +876,10 @@
this.addChild(this.rightTips);
};
GameView.prototype.createRects = function () {
this.wetWaste = this.createRect(74, 552, 301, 293, 0xffffff);
this.harmfulWaste = this.createRect(75, 247, 300, 293, 0xff0000);
this.dryWaste = this.createRect(389, 249, 286, 291, 0x000000);
this.recoverableWaste = this.createRect(389, 551, 287, 292, 0x0000ff);
this.wetWaste = this.createRect(104, 565, 252, 297, 0xffffff);
this.harmfulWaste = this.createRect(104, 232, 252, 297, 0xff0000);
this.dryWaste = this.createRect(403, 232, 252, 297, 0x000000);
this.recoverableWaste = this.createRect(403, 565, 252, 297, 0x0000ff);
};
GameView.prototype.createRect = function (x, y, w, h, c) {
var rect = new engine.Rectangle(x, y, w, h);
......@@ -973,6 +992,7 @@
};
return GameView;
}(engine.Container));
//# sourceMappingURL=GameView.js.map
var GameWrapper = (function (_super) {
tslib.__extends(GameWrapper, _super);
......@@ -997,6 +1017,7 @@
};
return GameWrapper;
}(engine.Container));
//# sourceMappingURL=GameWrapper.js.map
function index (props) {
prepareProps();
......@@ -1004,6 +1025,7 @@
var instance = new GameWrapper();
return instance;
}
//# sourceMappingURL=index.js.map
return index;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -16,9 +16,9 @@
},
{
"name": "playBg",
"url": "//yun.duiba.com.cn/aurora/assets/2a5b5087d915c2510f1b96facdb9532798ab59cd.jpg",
"uuid": "1e7dd156-b59a-491d-8154-af2ecf425a8b",
"ext": ".jpg"
"url": "//yun.duiba.com.cn/aurora/assets/7ba8fbc28c05b312c3ac3de607ce6f00bf8ae28d.png",
"uuid": "153eeb1f-056d-4ee8-b887-7c6c3b0ef7af",
"ext": ".png"
},
{
"name": "wrongTips",
......@@ -70,8 +70,8 @@
},
{
"name": "guideBg",
"url": "//yun.duiba.com.cn/aurora/assets/b43a358298c7669dc9f80ea83bc79c74087b82a7.png",
"uuid": "d96da0ff-b188-41e3-8a8b-8a67108c1e65",
"url": "//yun.duiba.com.cn/aurora/assets/68e85e441ba1ef5aff111a9631679febb9e41276.png",
"uuid": "ae92d05b-05ee-42fb-bc10-3e1936c4692f",
"ext": ".png"
},
{
......
......@@ -74,10 +74,10 @@ export default class GameView extends engine.Container {
}
private createRects() {
this.wetWaste = this.createRect(74, 552, 301, 293, 0xffffff);
this.harmfulWaste = this.createRect(75, 247, 300, 293, 0xff0000);
this.dryWaste = this.createRect(389, 249, 286, 291, 0x000000);
this.recoverableWaste = this.createRect(389, 551, 287, 292, 0x0000ff);
this.wetWaste = this.createRect(104, 565, 252, 297, 0xffffff);
this.harmfulWaste = this.createRect(104, 232, 252, 297, 0xff0000);
this.dryWaste = this.createRect(403, 232, 252, 297, 0x000000);
this.recoverableWaste = this.createRect(403, 565, 252, 297, 0x0000ff);
}
createRect(x, y, w, h, c) {
......
......@@ -19,8 +19,8 @@ export default class GuideView extends engine.Sprite {
this.addChild(this.guideBg)
this.guideEle = createImg('guideEle')
this.addChild(this.guideEle)
this.guideBg.x = 393;
this.guideBg.y = 552;
this.guideBg.x = 403;
this.guideBg.y = 565;
this.guideEle.x = 361;
this.guideEle.y = 877;
......@@ -36,7 +36,7 @@ export default class GuideView extends engine.Sprite {
}
checkHit(x, y, w, h) {
const rect = new engine.Rectangle(393, 552, 281, 320)
const rect = new engine.Rectangle(403, 565, 252, 297);
if (x > rect.x && y > rect.y && (x + w) < (rect.x + rect.width) && (y + h) < (rect.y + rect.height)) {
return true
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment