Commit 4a5688e9 authored by Roque's avatar Roque

[WEB-WORKER] [WIP] move all game logic into one file (WIP)

parent 27591e7d
...@@ -244,7 +244,7 @@ ...@@ -244,7 +244,7 @@
</item> </item>
<item> <item>
<key> <string>serial</string> </key> <key> <string>serial</string> </key>
<value> <string>1003.16062.13191.49442</string> </value> <value> <string>1003.17389.58791.46523</string> </value>
</item> </item>
<item> <item>
<key> <string>state</string> </key> <key> <string>state</string> </key>
...@@ -262,7 +262,7 @@ ...@@ -262,7 +262,7 @@
</tuple> </tuple>
<state> <state>
<tuple> <tuple>
<float>1664305860.06</float> <float>1664385697.54</float>
<string>UTC</string> <string>UTC</string>
</tuple> </tuple>
</state> </state>
......
...@@ -59,7 +59,7 @@ var MapManager = /** @class */ (function () { ...@@ -59,7 +59,7 @@ var MapManager = /** @class */ (function () {
this._lGoal.material = lGoalMat; this._lGoal.material = lGoalMat;
this._lGoal.computeWorldMatrix(true); this._lGoal.computeWorldMatrix(true);
//base is now a boat (special object) //base is now a boat (special object)
ObstacleManager.Prefab.rotation = new BABYLON.Vector3(20.4, 0, 0); /*ObstacleManager.Prefab.rotation = new BABYLON.Vector3(20.4, 0, 0);
ObstacleManager.Prefab.scaling = new BABYLON.Vector3(15, 15, 15); ObstacleManager.Prefab.scaling = new BABYLON.Vector3(15, 15, 15);
goalPart1 = new ObstacleManager("goal_1", scene); goalPart1 = new ObstacleManager("goal_1", scene);
goalPart1.setStartingPosition(goal_x, goal_y, goal_z); goalPart1.setStartingPosition(goal_x, goal_y, goal_z);
...@@ -74,7 +74,7 @@ var MapManager = /** @class */ (function () { ...@@ -74,7 +74,7 @@ var MapManager = /** @class */ (function () {
}, scene); }, scene);
goalPart3.position = new BABYLON.Vector3(goal_x + 2.5, goal_y + 1.5, goal_z + 1.5); goalPart3.position = new BABYLON.Vector3(goal_x + 2.5, goal_y + 1.5, goal_z + 1.5);
goalPart3.rotation = new BABYLON.Vector3(0, 0, 0); goalPart3.rotation = new BABYLON.Vector3(0, 0, 0);
goalPart3.scaling = new BABYLON.Vector3(1.5, 3.5, 1.5); goalPart3.scaling = new BABYLON.Vector3(1.5, 3.5, 1.5);*/
// Obstacles // Obstacles
var count = 0; var count = 0;
...@@ -99,12 +99,12 @@ var MapManager = /** @class */ (function () { ...@@ -99,12 +99,12 @@ var MapManager = /** @class */ (function () {
'diameterZ': obs.scale.z 'diameterZ': obs.scale.z
}, scene); }, scene);
break; break;
case "boat": /*case "boat":
ObstacleManager.Prefab.rotation = new BABYLON.Vector3(obs.rotation.x, obs.rotation.y, obs.rotation.z); ObstacleManager.Prefab.rotation = new BABYLON.Vector3(obs.rotation.x, obs.rotation.y, obs.rotation.z);
ObstacleManager.Prefab.scaling = new BABYLON.Vector3(obs.scale.x * 2, obs.scale.y * 2, obs.scale.z * 2); ObstacleManager.Prefab.scaling = new BABYLON.Vector3(obs.scale.x * 2, obs.scale.y * 2, obs.scale.z * 2);
newObj = new ObstacleManager("obs_" + count, scene); newObj = new ObstacleManager("obs_" + count, scene);
newObj.setStartingPosition(obs.position.x, obs.position.y, obs.position.z); newObj.setStartingPosition(obs.position.x, obs.position.y, obs.position.z);
break; break;*/
default: default:
return; return;
} }
......
...@@ -244,7 +244,7 @@ ...@@ -244,7 +244,7 @@
</item> </item>
<item> <item>
<key> <string>serial</string> </key> <key> <string>serial</string> </key>
<value> <string>1002.54126.42371.36932</string> </value> <value> <string>1002.59720.6150.16674</string> </value>
</item> </item>
<item> <item>
<key> <string>state</string> </key> <key> <string>state</string> </key>
...@@ -262,7 +262,7 @@ ...@@ -262,7 +262,7 @@
</tuple> </tuple>
<state> <state>
<tuple> <tuple>
<float>1662993125.49</float> <float>1664385627.49</float>
<string>UTC</string> <string>UTC</string>
</tuple> </tuple>
</state> </state>
......
...@@ -25,7 +25,6 @@ self.document = { ...@@ -25,7 +25,6 @@ self.document = {
importScripts('babylon.js', 'babylon.gui.js'); importScripts('babylon.js', 'babylon.gui.js');
importScripts('rsvp.js', importScripts('rsvp.js',
'DroneManager.js',
'MapManager.js', 'MapManager.js',
'ObstacleManager.js', 'ObstacleManager.js',
'gadget_erp5_page_game_logic.js'); 'gadget_erp5_page_game_logic.js');
......
...@@ -244,7 +244,7 @@ ...@@ -244,7 +244,7 @@
</item> </item>
<item> <item>
<key> <string>serial</string> </key> <key> <string>serial</string> </key>
<value> <string>1003.16039.18174.58350</string> </value> <value> <string>1003.16063.16360.1689</string> </value>
</item> </item>
<item> <item>
<key> <string>state</string> </key> <key> <string>state</string> </key>
...@@ -262,7 +262,7 @@ ...@@ -262,7 +262,7 @@
</tuple> </tuple>
<state> <state>
<tuple> <tuple>
<float>1664305874.93</float> <float>1664306211.61</float>
<string>UTC</string> <string>UTC</string>
</tuple> </tuple>
</state> </state>
......
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