65 lines
1.7 KiB
C#
65 lines
1.7 KiB
C#
using Newtonsoft.Json;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
namespace Simulator.Data
|
|
{
|
|
[Serializable]
|
|
public class RackDataClass : ComponentDataBase
|
|
{
|
|
public bool is_unlimited;
|
|
public bool fms_input_enabled;
|
|
public bool fms_output_enabled;
|
|
//public List<string> inputs=new List<string>();
|
|
//public List<string> outputs=new List<string>();
|
|
[JsonConverter(typeof(PolicyConverter))]
|
|
public Policy_Base storage_cost_policy;
|
|
[JsonConverter(typeof(PolicyConverter))]
|
|
public Policy_Base shipping_time_policy;
|
|
[JsonConverter(typeof(PolicyConverter))]
|
|
public Policy_Base receiving_time_policy;
|
|
|
|
public List<InitializeEntry> initialize;
|
|
public rack_layout rack_layout=new rack_layout();
|
|
public int entity_count_per_block;
|
|
public string connected_input_node;
|
|
}
|
|
|
|
[Serializable]
|
|
public class rack_layout
|
|
{
|
|
public event Action onLayoutChanged;
|
|
int _x;
|
|
public int x
|
|
{
|
|
get { return _x; }
|
|
set { if (_x != value) { _x = value; }
|
|
onLayoutChanged?.Invoke();
|
|
}
|
|
}
|
|
int _y;
|
|
public int y
|
|
{
|
|
get { return _y; }
|
|
set
|
|
{
|
|
if (_y != value) { _y = value; }
|
|
onLayoutChanged?.Invoke();
|
|
}
|
|
}
|
|
public int _z;
|
|
public int z
|
|
{
|
|
get { return _z; }
|
|
set
|
|
{
|
|
if (_z != value) { _z = value; }
|
|
onLayoutChanged?.Invoke();
|
|
}
|
|
}
|
|
public float x_length;
|
|
public float y_length;
|
|
public float z_length;
|
|
}
|
|
} |