fix save not include simulation resources
This commit is contained in:
53
.json
53
.json
@@ -1,52 +1 @@
|
|||||||
[
|
[]
|
||||||
{
|
|
||||||
"prefabName": "RoboArm",
|
|
||||||
"modelName": "RoboArm_1",
|
|
||||||
"modelType": "Resource",
|
|
||||||
"modelID": "",
|
|
||||||
"nodeID": "",
|
|
||||||
"position": "(-2.93, 0.00, -16.20)",
|
|
||||||
"rotation": "(0.00000, 0.00000, 0.00000, 1.00000)",
|
|
||||||
"scale": "(1.00, 1.00, 1.00)"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"prefabName": "RoboArm",
|
|
||||||
"modelName": "RoboArm_0",
|
|
||||||
"modelType": "Resource",
|
|
||||||
"modelID": "",
|
|
||||||
"nodeID": "",
|
|
||||||
"position": "(-0.12, 0.00, -9.08)",
|
|
||||||
"rotation": "(0.00000, 0.00000, 0.00000, 1.00000)",
|
|
||||||
"scale": "(1.00, 1.00, 1.00)"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"prefabName": "AssemblyLine",
|
|
||||||
"modelName": "AssemblyLine_0",
|
|
||||||
"modelType": "Move",
|
|
||||||
"modelID": "",
|
|
||||||
"nodeID": "",
|
|
||||||
"position": "(1.99, 0.00, -18.60)",
|
|
||||||
"rotation": "(0.00000, 0.00000, 0.00000, 1.00000)",
|
|
||||||
"scale": "(1.00, 1.00, 1.00)"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"prefabName": "ForkLift",
|
|
||||||
"modelName": "ForkLift_0",
|
|
||||||
"modelType": "Move",
|
|
||||||
"modelID": "",
|
|
||||||
"nodeID": "product_generator_0_47f91e67-41ad-434c-bb7f-e983c143a840",
|
|
||||||
"position": "(-3.44, 0.00, -11.70)",
|
|
||||||
"rotation": "(0.15745, -0.41944, -0.83088, -0.33002)",
|
|
||||||
"scale": "(1.00, 1.00, 1.00)"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"prefabName": "Pallet",
|
|
||||||
"modelName": "Pallet_0",
|
|
||||||
"modelType": "Source",
|
|
||||||
"modelID": "",
|
|
||||||
"nodeID": "",
|
|
||||||
"position": "(-1.52, 0.00, -17.98)",
|
|
||||||
"rotation": "(0.00000, 0.00000, 0.00000, 1.00000)",
|
|
||||||
"scale": "(1.00, 1.00, 1.00)"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
@@ -18,7 +18,7 @@ public class MQTTDataBase : MonoBehaviour
|
|||||||
|
|
||||||
public void AddDict(string key, string value)
|
public void AddDict(string key, string value)
|
||||||
{
|
{
|
||||||
//Debug.Log("#### : " + key + " : " + value);
|
Debug.Log("#### : " + key + " : " + value);
|
||||||
JObject json = JObject.Parse(value);
|
JObject json = JObject.Parse(value);
|
||||||
var queue = mqttData.GetOrAdd(key, _ => new ConcurrentQueue<JObject>());
|
var queue = mqttData.GetOrAdd(key, _ => new ConcurrentQueue<JObject>());
|
||||||
queue.Enqueue(json);
|
queue.Enqueue(json);
|
||||||
|
|||||||
@@ -40,6 +40,9 @@ public class SaveLoadmanager : MonoBehaviour
|
|||||||
|
|
||||||
foreach (var item in simulationModels)
|
foreach (var item in simulationModels)
|
||||||
{
|
{
|
||||||
|
if (item is SimulationModelProduct)
|
||||||
|
continue;
|
||||||
|
|
||||||
var tmpSimulationModelInfo = new SimulationModelInfo();
|
var tmpSimulationModelInfo = new SimulationModelInfo();
|
||||||
|
|
||||||
tmpSimulationModelInfo.prefabName = item.gameObject.name.Replace("(Clone)", "");
|
tmpSimulationModelInfo.prefabName = item.gameObject.name.Replace("(Clone)", "");
|
||||||
|
|||||||
Reference in New Issue
Block a user