Commit 33ddc46a authored by 任建锋's avatar 任建锋

--

parent b8fc171e
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -319,7 +319,7 @@
"uuid": "4cf8cf2d-6adf-4f87-843b-617a35e35477"
}
],
"disabled": true
"disabled": false
},
{
"name": "ScenePlay",
......@@ -364,7 +364,8 @@
"check_1": "entity|e4918819-07ed-4023-9cb5-7790865674c5",
"check_2": "entity|df4c7f2b-f693-43da-9b0b-bda88203620a",
"check_3": "entity|2e80cbfa-ef64-4383-acf9-6bd51183cadb",
"check_4": "entity|499f5470-a73f-46f4-bbcf-eff5192c9edf"
"check_4": "entity|499f5470-a73f-46f4-bbcf-eff5192c9edf",
"getOrderStatus": "dynamic|API|getOrderStatus"
}
},
{
......@@ -387,6 +388,27 @@
}
]
}
},
{
"script": "./scripts/api/SamplePollingApi",
"properties": {
"name": "getOrderStatus",
"uri": "/hdtool/recon/getOrderStatus",
"onError": [
{
"entity": "entity|5bc2f6aa-a570-46cf-bf4e-b2fb1b749bee",
"component": 1,
"method": "onError_orderStatus"
}
],
"onResponse": [
{
"entity": "entity|5bc2f6aa-a570-46cf-bf4e-b2fb1b749bee",
"component": 1,
"method": "onResponse_orderStatus"
}
]
}
}
],
"uuid": "5bc2f6aa-a570-46cf-bf4e-b2fb1b749bee",
......
......@@ -13,6 +13,7 @@ import {createTween, ease} from "scilla";
export default class ScenePlay extends InteractComponent implements INavigatorViewBase {
doJoinData: dynamic;
getNgameStartStatus: dynamic;
getOrderStatus: dynamic;
bg1: Entity;
bg2: Entity;
......@@ -292,7 +293,7 @@ export default class ScenePlay extends InteractComponent implements INavigatorVi
this["check_"+this.checkpoint]["Transform"].alpha=1;
if(this.checkpoint>=3){
this["check_"+4]["Transform"].alpha=1;
this.onResponse_ngameSubmit()
this.onGameOver()
}
}
......@@ -333,9 +334,27 @@ export default class ScenePlay extends InteractComponent implements INavigatorVi
}
onResponse_ngameSubmit() {
const param: any = {
orderId: this.doJoinData,
};
this.broadcast('callApi', 1, 'getOrderStatus', param);
}
onError_ngameSubmit() {
}
onResponse_orderStatus() {
//this.bubbling('showDialog', 'GameOver');
console.log(1)
console.log(this.getOrderStatus)
this.bubbling('showDialog', 'GameOver');
}
onError_orderStatus() {
console.log(2)
}
onGameLose() {
this.bubbling('showDialog', 'GameLose');
}
......@@ -430,10 +449,6 @@ export default class ScenePlay extends InteractComponent implements INavigatorVi
}
}
onError_ngameSubmit() {
}
onDidLeave(next: string, action: alien.NavigatorAction, parameters: any): void {
this.entity.enabled = false;
}
......
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