Revize 04839796
Přidáno uživatelem Oto Šťáva před téměř 4 roky(ů)
deltarobot-vr/Assets/DeltaRobotVr/ActuatorScript.cs | ||
---|---|---|
1 |
using UnityEngine; |
|
2 |
|
|
3 |
namespace DeltaRobotVr |
|
4 |
{ |
|
5 |
public class ActuatorScript : MonoBehaviour |
|
6 |
{ |
|
7 |
public const float LerpParam = 0.5f; |
|
8 |
|
|
9 |
private Transform _transform; |
|
10 |
|
|
11 |
void Start() |
|
12 |
{ |
|
13 |
_transform = GetComponent<Transform>(); |
|
14 |
} |
|
15 |
|
|
16 |
void Update() |
|
17 |
{ |
|
18 |
if (Client.Instance.IsConnected) |
|
19 |
{ |
|
20 |
var actPosition = Client.Instance.ActuatorPosition; |
|
21 |
var newPosition = Single3Utils.ToVector3(actPosition.X, actPosition.Y, actPosition.Z); |
|
22 |
_transform.position = Vector3.Lerp(_transform.position, newPosition, LerpParam); |
|
23 |
} |
|
24 |
} |
|
25 |
} |
|
26 |
} |
deltarobot-vr/Assets/DeltaRobotVr/ActuatorScript.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: cfafba4e0e8b6e0adb6dda9dbc5076f8 |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/ArrowScript.cs | ||
---|---|---|
1 |
using UnityEngine; |
|
2 |
|
|
3 |
namespace DeltaRobotVr |
|
4 |
{ |
|
5 |
public abstract class ArrowScript : MonoBehaviour |
|
6 |
{ |
|
7 |
public float lengthMultiplier = 2; |
|
8 |
void Start() |
|
9 |
{ |
|
10 |
} |
|
11 |
|
|
12 |
void Update() |
|
13 |
{ |
|
14 |
if (Client.Instance.IsConnected) |
|
15 |
{ |
|
16 |
var vector = GetVector(); |
|
17 |
|
|
18 |
Vector3 v = Single3Utils.ToVector3(vector); |
|
19 |
this.transform.rotation = Quaternion.FromToRotation(Vector3.forward, v); |
|
20 |
this.transform.localScale = new Vector3(1, 1, v.magnitude * lengthMultiplier); |
|
21 |
} |
|
22 |
} |
|
23 |
|
|
24 |
protected abstract Single3 GetVector(); |
|
25 |
} |
|
26 |
} |
deltarobot-vr/Assets/DeltaRobotVr/ArrowScript.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: e8091905fe5149d40a4fb2711bb82b8b |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/Client.cs | ||
---|---|---|
8 | 8 |
|
9 | 9 |
namespace DeltaRobotVr |
10 | 10 |
{ |
11 |
public readonly struct Single3 |
|
12 |
{ |
|
13 |
public float X { get; } |
|
14 |
public float Y { get; } |
|
15 |
public float Z { get; } |
|
16 |
|
|
17 |
public Single3(float x, float y, float z) |
|
18 |
{ |
|
19 |
X = x; |
|
20 |
Y = y; |
|
21 |
Z = z; |
|
22 |
} |
|
23 |
|
|
24 |
public override string ToString() => "Single3[ " + X + " " + Y + " " + Z + " ]"; |
|
25 |
} |
|
26 |
|
|
11 |
|
|
12 |
/// <summary> |
|
13 |
/// Singleton class responsible for communication with the Deltarobot server. |
|
14 |
/// </summary> |
|
27 | 15 |
public sealed class Client |
28 | 16 |
{ |
29 | 17 |
// singleton instance |
... | ... | |
79 | 67 |
private long _curveCounter = 0; |
80 | 68 |
|
81 | 69 |
private volatile bool _isConnected; |
82 |
private volatile string _eotMsg = string.Empty;
|
|
70 |
private volatile string _eotReason = string.Empty;
|
|
83 | 71 |
|
84 | 72 |
private readonly object _reconnectTimeLock = new object(); |
85 | 73 |
private DateTime _reconnectTime = DateTime.Now; |
... | ... | |
92 | 80 |
{ |
93 | 81 |
} |
94 | 82 |
|
83 |
/// <summary> |
|
84 |
/// Starts the client thread and connects to the server. |
|
85 |
/// </summary> |
|
95 | 86 |
public void Start() |
96 | 87 |
{ |
97 | 88 |
IsRunning = true; |
... | ... | |
99 | 90 |
_thread.Start(); |
100 | 91 |
} |
101 | 92 |
|
93 |
/// <summary> |
|
94 |
/// Gracefully stops the client thread. Blocks until the thread actually stops. |
|
95 |
/// </summary> |
|
102 | 96 |
public void Stop() |
103 | 97 |
{ |
104 | 98 |
IsRunning = false; |
... | ... | |
109 | 103 |
} |
110 | 104 |
} |
111 | 105 |
|
112 |
public string EotMsg |
|
106 |
/// <summary> |
|
107 |
/// Contains a reason received in an end-of-transmission message. |
|
108 |
/// </summary> |
|
109 |
public string EotReason |
|
113 | 110 |
{ |
114 |
get => _eotMsg;
|
|
115 |
private set => _eotMsg = value;
|
|
111 |
get => _eotReason;
|
|
112 |
private set => _eotReason = value;
|
|
116 | 113 |
} |
117 | 114 |
|
115 |
/// <summary> |
|
116 |
/// Whether the client is currently maintaining an active connection to the server. |
|
117 |
/// </summary> |
|
118 | 118 |
public bool IsConnected |
119 | 119 |
{ |
120 | 120 |
get => _isConnected; |
121 | 121 |
private set => _isConnected = value; |
122 | 122 |
} |
123 | 123 |
|
124 |
/// <summary> |
|
125 |
/// Current position of the actuator (in server's world space). |
|
126 |
/// </summary> |
|
124 | 127 |
public Single3 ActuatorPosition |
125 | 128 |
{ |
126 | 129 |
get |
... | ... | |
139 | 142 |
} |
140 | 143 |
} |
141 | 144 |
|
142 |
public Single3 CurrentDirectionVector |
|
145 |
/// <summary> |
|
146 |
/// The actual direction the actuator is currently moving in. |
|
147 |
/// </summary> |
|
148 |
public Single3 ActualDirectionVector |
|
143 | 149 |
{ |
144 | 150 |
get |
145 | 151 |
{ |
... | ... | |
157 | 163 |
} |
158 | 164 |
} |
159 | 165 |
|
160 |
public Single3 DesiredDirectionVector |
|
166 |
/// <summary> |
|
167 |
/// The target direction the actuator should be moving in so that it draws the curve. |
|
168 |
/// </summary> |
|
169 |
public Single3 TargetDirectionVector |
|
161 | 170 |
{ |
162 | 171 |
get |
163 | 172 |
{ |
... | ... | |
175 | 184 |
} |
176 | 185 |
} |
177 | 186 |
|
187 |
/// <summary> |
|
188 |
/// The current exercise curve. |
|
189 |
/// </summary> |
|
178 | 190 |
public Single3[] Curve |
179 | 191 |
{ |
180 | 192 |
get |
... | ... | |
193 | 205 |
} |
194 | 206 |
} |
195 | 207 |
|
208 |
/// <summary> |
|
209 |
/// A counter used to determine whether the curve has changed. The curve remains the same while the counter is |
|
210 |
/// the same. |
|
211 |
/// </summary> |
|
196 | 212 |
public long CurveCounter |
197 | 213 |
{ |
198 | 214 |
get |
... | ... | |
211 | 227 |
} |
212 | 228 |
} |
213 | 229 |
|
230 |
/// <summary> |
|
231 |
/// Whether the client thread should keep on reading data from the server. |
|
232 |
/// </summary> |
|
214 | 233 |
public bool IsRunning |
215 | 234 |
{ |
216 | 235 |
get { |
... | ... | |
228 | 247 |
} |
229 | 248 |
} |
230 | 249 |
|
250 |
/// <summary> |
|
251 |
/// The time at which the client will attempt to reconnect to the server again. |
|
252 |
/// </summary> |
|
231 | 253 |
public DateTime ReconnectTime |
232 | 254 |
{ |
233 | 255 |
get |
... | ... | |
246 | 268 |
} |
247 | 269 |
} |
248 | 270 |
|
271 |
/// <summary> |
|
272 |
/// The client thread function. |
|
273 |
/// </summary> |
|
249 | 274 |
private void ThreadProcedure() |
250 | 275 |
{ |
251 | 276 |
while (IsRunning) |
... | ... | |
315 | 340 |
ProcessEot(reader); |
316 | 341 |
break; |
317 | 342 |
case CurrentActuatorPositionId: |
318 |
ProcessCurrentActuatorPosition(reader);
|
|
343 |
ProcessActuatorPosition(reader); |
|
319 | 344 |
break; |
320 | 345 |
case CurrentDirectionVectorId: |
321 |
ProcessCurrentDirectionVector(reader);
|
|
346 |
ProcessActualDirectionVector(reader);
|
|
322 | 347 |
break; |
323 | 348 |
case DesiredDirectionVectorId: |
324 |
ProcessDesiredDirectionVector(reader);
|
|
349 |
ProcessTargetDirectionVector(reader);
|
|
325 | 350 |
break; |
326 | 351 |
case CurveId: |
327 | 352 |
ProcessCurve(reader); |
... | ... | |
394 | 419 |
reader.ReadBytes((int) numberOfBytes); |
395 | 420 |
} |
396 | 421 |
|
397 |
private void ProcessCurrentActuatorPosition(BinaryReader reader)
|
|
422 |
private void ProcessActuatorPosition(BinaryReader reader) |
|
398 | 423 |
{ |
399 | 424 |
var x = reader.ReadSingle(); |
400 | 425 |
var y = reader.ReadSingle(); |
... | ... | |
404 | 429 |
ActuatorPosition = new Single3(x, y, z); |
405 | 430 |
} |
406 | 431 |
|
407 |
private void ProcessCurrentDirectionVector(BinaryReader reader)
|
|
432 |
private void ProcessActualDirectionVector(BinaryReader reader)
|
|
408 | 433 |
{ |
409 | 434 |
var x = reader.ReadSingle(); |
410 | 435 |
var y = reader.ReadSingle(); |
411 | 436 |
var z = reader.ReadSingle(); |
412 | 437 |
reader.ReadSingle(); // skip unused |
413 | 438 |
|
414 |
CurrentDirectionVector = new Single3(x, y, z);
|
|
439 |
ActualDirectionVector = new Single3(x, y, z);
|
|
415 | 440 |
} |
416 | 441 |
|
417 |
private void ProcessDesiredDirectionVector(BinaryReader reader)
|
|
442 |
private void ProcessTargetDirectionVector(BinaryReader reader)
|
|
418 | 443 |
{ |
419 | 444 |
var x = reader.ReadSingle(); |
420 | 445 |
var y = reader.ReadSingle(); |
421 | 446 |
var z = reader.ReadSingle(); |
422 | 447 |
reader.ReadSingle(); // skip unused |
423 | 448 |
|
424 |
DesiredDirectionVector = new Single3(x, y, z);
|
|
449 |
TargetDirectionVector = new Single3(x, y, z);
|
|
425 | 450 |
} |
426 | 451 |
|
427 | 452 |
private void ProcessCurve(BinaryReader reader) |
... | ... | |
449 | 474 |
{ |
450 | 475 |
UInt32 numberOfBytes = reader.ReadUInt32(); |
451 | 476 |
Byte[] buffer = reader.ReadBytes((int) numberOfBytes); |
452 |
EotMsg = Encoding.ASCII.GetString(buffer);
|
|
477 |
EotReason = Encoding.ASCII.GetString(buffer);
|
|
453 | 478 |
IsConnected = false; |
454 | 479 |
} |
455 | 480 |
|
deltarobot-vr/Assets/DeltaRobotVr/Components.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: fc6bedc3421d40129835f279dbc661e2 |
|
3 |
timeCreated: 1621693639 |
deltarobot-vr/Assets/DeltaRobotVr/Components/AbstractArrow.cs | ||
---|---|---|
1 |
using UnityEngine; |
|
2 |
|
|
3 |
namespace DeltaRobotVr.Components |
|
4 |
{ |
|
5 |
/// <summary> |
|
6 |
/// A generic implementation of vector visualization. The vector is determined by the <c>GetVector</c> method. |
|
7 |
/// </summary> |
|
8 |
public abstract class AbstractArrow : MonoBehaviour |
|
9 |
{ |
|
10 |
public float lengthMultiplier = 2; |
|
11 |
|
|
12 |
void Update() |
|
13 |
{ |
|
14 |
if (Client.Instance.IsConnected) |
|
15 |
{ |
|
16 |
Vector3 v = Single3Utils.ToVector3(GetVector()); |
|
17 |
|
|
18 |
var t = transform; |
|
19 |
t.rotation = Quaternion.FromToRotation(Vector3.forward, v); |
|
20 |
t.localScale = new Vector3(1, 1, v.magnitude * lengthMultiplier); |
|
21 |
} |
|
22 |
} |
|
23 |
|
|
24 |
/// <summary> |
|
25 |
/// Gets the vector that this component renders. |
|
26 |
/// </summary> |
|
27 |
protected abstract Single3 GetVector(); |
|
28 |
} |
|
29 |
} |
deltarobot-vr/Assets/DeltaRobotVr/Components/AbstractArrow.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: e8091905fe5149d40a4fb2711bb82b8b |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/Components/ActualDirectionArrow.cs | ||
---|---|---|
1 |
namespace DeltaRobotVr.Components |
|
2 |
{ |
|
3 |
|
|
4 |
/// <summary> |
|
5 |
/// This arrow visualizes the actual direction the actuator is currently moving in. |
|
6 |
/// </summary> |
|
7 |
public class ActualDirectionArrow : AbstractArrow |
|
8 |
{ |
|
9 |
protected override Single3 GetVector() => Client.Instance.ActualDirectionVector; |
|
10 |
} |
|
11 |
} |
deltarobot-vr/Assets/DeltaRobotVr/Components/ActualDirectionArrow.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 7d92319639667d643a9722c4c835a70b |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/Components/Actuator.cs | ||
---|---|---|
1 |
using UnityEngine; |
|
2 |
|
|
3 |
namespace DeltaRobotVr.Components |
|
4 |
{ |
|
5 |
public class Actuator : MonoBehaviour |
|
6 |
{ |
|
7 |
public const float LerpParam = 0.5f; |
|
8 |
|
|
9 |
private Transform _transform; |
|
10 |
|
|
11 |
void Start() |
|
12 |
{ |
|
13 |
_transform = GetComponent<Transform>(); |
|
14 |
} |
|
15 |
|
|
16 |
void Update() |
|
17 |
{ |
|
18 |
if (Client.Instance.IsConnected) |
|
19 |
{ |
|
20 |
var actPosition = Client.Instance.ActuatorPosition; |
|
21 |
var newPosition = Single3Utils.ToVector3(actPosition.X, actPosition.Y, actPosition.Z); |
|
22 |
_transform.position = Vector3.Lerp(_transform.position, newPosition, LerpParam); |
|
23 |
} |
|
24 |
} |
|
25 |
} |
|
26 |
} |
deltarobot-vr/Assets/DeltaRobotVr/Components/Actuator.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: cfafba4e0e8b6e0adb6dda9dbc5076f8 |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/Components/Curve.cs | ||
---|---|---|
1 |
using UnityEngine; |
|
2 |
|
|
3 |
namespace DeltaRobotVr.Components |
|
4 |
{ |
|
5 |
public class Curve : MonoBehaviour |
|
6 |
{ |
|
7 |
private long _currentCounter; |
|
8 |
private LineRenderer _lineRenderer; |
|
9 |
|
|
10 |
void Start() |
|
11 |
{ |
|
12 |
_currentCounter = Client.Instance.CurveCounter; |
|
13 |
_lineRenderer = GetComponent<LineRenderer>(); |
|
14 |
} |
|
15 |
|
|
16 |
void Update() |
|
17 |
{ |
|
18 |
if (Client.Instance.IsConnected) |
|
19 |
{ |
|
20 |
var counter = Client.Instance.CurveCounter; |
|
21 |
if(counter != _currentCounter && Client.Instance.Curve != null) |
|
22 |
{ |
|
23 |
_lineRenderer.positionCount = Client.Instance.Curve.Length; |
|
24 |
_lineRenderer.SetPositions(Single3Utils.ToVector3(Client.Instance.Curve)); |
|
25 |
} |
|
26 |
} |
|
27 |
} |
|
28 |
} |
|
29 |
} |
deltarobot-vr/Assets/DeltaRobotVr/Components/Curve.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: bb50b983128c52b48ae66147e4978d5f |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/Components/StatusDisplay.cs | ||
---|---|---|
1 |
using System.Collections; |
|
2 |
using System.Collections.Generic; |
|
3 |
using UnityEngine; |
|
4 |
using UnityEngine.UI; |
|
5 |
using DeltaRobotVr; |
|
6 |
|
|
7 |
public class StatusDisplay : MonoBehaviour |
|
8 |
{ |
|
9 |
private const string STATUS = "Status:\n"; |
|
10 |
private const string CONNECTED = "<color=green>Connected</color>"; |
|
11 |
private const string CONNECTING = "<color=red>Connecting...</color>"; |
|
12 |
private Text _textComp; |
|
13 |
// Start is called before the first frame update |
|
14 |
void Start() |
|
15 |
{ |
|
16 |
_textComp = GetComponent<Text>(); |
|
17 |
} |
|
18 |
|
|
19 |
// Update is called once per frame |
|
20 |
void Update() |
|
21 |
{ |
|
22 |
if (Client.Instance.IsConnected) |
|
23 |
{ |
|
24 |
_textComp.text = STATUS + CONNECTED; |
|
25 |
} |
|
26 |
else |
|
27 |
{ |
|
28 |
if (Client.Instance.EotReason.Length == 0) |
|
29 |
{ |
|
30 |
_textComp.text = STATUS + CONNECTING; |
|
31 |
} |
|
32 |
else |
|
33 |
{ |
|
34 |
_textComp.text = STATUS + CONNECTING + "\n" + Client.Instance.EotReason; |
|
35 |
} |
|
36 |
} |
|
37 |
} |
|
38 |
} |
deltarobot-vr/Assets/DeltaRobotVr/Components/StatusDisplay.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 3dfc99055443ed24597abf07afc16604 |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/Components/TargetDirectionArrow.cs | ||
---|---|---|
1 |
namespace DeltaRobotVr.Components |
|
2 |
{ |
|
3 |
|
|
4 |
/// <summary> |
|
5 |
/// This arrow visualizes the target direction the actuator should be moving in, in order to draw the curve. |
|
6 |
/// </summary> |
|
7 |
public class TargetDirectionArrow : AbstractArrow |
|
8 |
{ |
|
9 |
protected override Single3 GetVector() => Client.Instance.TargetDirectionVector; |
|
10 |
} |
|
11 |
} |
deltarobot-vr/Assets/DeltaRobotVr/Components/TargetDirectionArrow.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 0405dab141f621d4aae1935de042ed9d |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/CurrentDirectionArrow.cs | ||
---|---|---|
1 |
namespace DeltaRobotVr |
|
2 |
{ |
|
3 |
public class CurrentDirectionArrow : ArrowScript |
|
4 |
{ |
|
5 |
protected override Single3 GetVector() => Client.Instance.CurrentDirectionVector; |
|
6 |
} |
|
7 |
} |
deltarobot-vr/Assets/DeltaRobotVr/CurrentDirectionArrow.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 7d92319639667d643a9722c4c835a70b |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/CurveScript.cs | ||
---|---|---|
1 |
using UnityEngine; |
|
2 |
|
|
3 |
namespace DeltaRobotVr |
|
4 |
{ |
|
5 |
public class CurveScript : MonoBehaviour |
|
6 |
{ |
|
7 |
private long _curentCounter; |
|
8 |
private LineRenderer lr; |
|
9 |
void Start() |
|
10 |
{ |
|
11 |
_curentCounter = Client.Instance.CurveCounter; |
|
12 |
lr = GetComponent<LineRenderer>(); |
|
13 |
} |
|
14 |
|
|
15 |
void Update() |
|
16 |
{ |
|
17 |
if (Client.Instance.IsConnected) |
|
18 |
{ |
|
19 |
var _counter = Client.Instance.CurveCounter; |
|
20 |
if(_counter != _curentCounter && Client.Instance.Curve != null) |
|
21 |
{ |
|
22 |
lr.positionCount = Client.Instance.Curve.Length; |
|
23 |
lr.SetPositions(Single3Utils.ToVector3(Client.Instance.Curve)); |
|
24 |
} |
|
25 |
} |
|
26 |
} |
|
27 |
} |
|
28 |
} |
deltarobot-vr/Assets/DeltaRobotVr/CurveScript.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: bb50b983128c52b48ae66147e4978d5f |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/DesiredDirectionArrow.cs | ||
---|---|---|
1 |
namespace DeltaRobotVr |
|
2 |
{ |
|
3 |
public class DesiredDirectionArrow : ArrowScript |
|
4 |
{ |
|
5 |
protected override Single3 GetVector() => Client.Instance.DesiredDirectionVector; |
|
6 |
} |
|
7 |
} |
deltarobot-vr/Assets/DeltaRobotVr/DesiredDirectionArrow.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 0405dab141f621d4aae1935de042ed9d |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/DeltaRobotVr/MainScript.cs | ||
---|---|---|
1 |
using System; |
|
2 |
using UnityEngine; |
|
3 |
using UnityEngine.SceneManagement; |
|
4 |
|
|
5 |
namespace DeltaRobotVr |
|
6 |
{ |
|
7 |
public class MainScript : MonoBehaviour |
|
8 |
{ |
|
9 |
private void Start() |
|
10 |
{ |
|
11 |
SceneManager.LoadScene("BasicRoomScene", LoadSceneMode.Additive); |
|
12 |
Client.Instance.Start(); |
|
13 |
} |
|
14 |
|
|
15 |
private void OnDestroy() |
|
16 |
{ |
|
17 |
Client.Instance.Stop(); |
|
18 |
} |
|
19 |
} |
|
1 |
using UnityEngine; |
|
2 |
using UnityEngine.SceneManagement; |
|
3 |
|
|
4 |
namespace DeltaRobotVr |
|
5 |
{ |
|
6 |
|
|
7 |
/// <summary> |
|
8 |
/// Global script for the main scene. |
|
9 |
/// </summary> |
|
10 |
public class MainScript : MonoBehaviour |
|
11 |
{ |
|
12 |
private void Start() |
|
13 |
{ |
|
14 |
SceneManager.LoadScene("BasicRoomScene", LoadSceneMode.Additive); |
|
15 |
Client.Instance.Start(); |
|
16 |
} |
|
17 |
|
|
18 |
private void OnDestroy() |
|
19 |
{ |
|
20 |
Client.Instance.Stop(); |
|
21 |
} |
|
22 |
} |
|
20 | 23 |
} |
deltarobot-vr/Assets/DeltaRobotVr/Single3.cs | ||
---|---|---|
1 |
namespace DeltaRobotVr |
|
2 |
{ |
|
3 |
|
|
4 |
/// <summary> |
|
5 |
/// A simple 3D float vector. |
|
6 |
/// </summary> |
|
7 |
public readonly struct Single3 |
|
8 |
{ |
|
9 |
public float X { get; } |
|
10 |
public float Y { get; } |
|
11 |
public float Z { get; } |
|
12 |
|
|
13 |
public Single3(float x, float y, float z) |
|
14 |
{ |
|
15 |
X = x; |
|
16 |
Y = y; |
|
17 |
Z = z; |
|
18 |
} |
|
19 |
|
|
20 |
public override string ToString() => "Single3[ " + X + " " + Y + " " + Z + " ]"; |
|
21 |
} |
|
22 |
} |
deltarobot-vr/Assets/DeltaRobotVr/Single3.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 5e77e12132de42cdb006c02000deb1b1 |
|
3 |
timeCreated: 1621783853 |
deltarobot-vr/Assets/DeltaRobotVr/Single3Utils.cs | ||
---|---|---|
2 | 2 |
|
3 | 3 |
namespace DeltaRobotVr |
4 | 4 |
{ |
5 |
|
|
6 |
/// <summary> |
|
7 |
/// Utilities for the <c>Single3</c> struct. |
|
8 |
/// </summary> |
|
5 | 9 |
public class Single3Utils |
6 | 10 |
{ |
7 | 11 |
public const float PositionScale = 0.001f; |
deltarobot-vr/Assets/DeltaRobotVr/StatusScript.cs | ||
---|---|---|
1 |
using System.Collections; |
|
2 |
using System.Collections.Generic; |
|
3 |
using UnityEngine; |
|
4 |
using UnityEngine.UI; |
|
5 |
using DeltaRobotVr; |
|
6 |
|
|
7 |
public class StatusScript : MonoBehaviour |
|
8 |
{ |
|
9 |
private const string STATUS = "Status:\n"; |
|
10 |
private const string CONNECTED = "<color=green>Connected</color>"; |
|
11 |
private const string CONNECTING = "<color=red>Connecting...</color>\n"; |
|
12 |
private Text _textComp; |
|
13 |
// Start is called before the first frame update |
|
14 |
void Start() |
|
15 |
{ |
|
16 |
_textComp = GetComponent<Text>(); |
|
17 |
} |
|
18 |
|
|
19 |
// Update is called once per frame |
|
20 |
void Update() |
|
21 |
{ |
|
22 |
if (Client.Instance.IsConnected) |
|
23 |
{ |
|
24 |
_textComp.text = STATUS + CONNECTED; |
|
25 |
} |
|
26 |
else |
|
27 |
{ |
|
28 |
_textComp.text = STATUS + CONNECTING + Client.Instance.EotMsg; |
|
29 |
} |
|
30 |
} |
|
31 |
} |
deltarobot-vr/Assets/DeltaRobotVr/StatusScript.cs.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 3dfc99055443ed24597abf07afc16604 |
|
3 |
MonoImporter: |
|
4 |
externalObjects: {} |
|
5 |
serializedVersion: 2 |
|
6 |
defaultReferences: [] |
|
7 |
executionOrder: 0 |
|
8 |
icon: {instanceID: 0} |
|
9 |
userData: |
|
10 |
assetBundleName: |
|
11 |
assetBundleVariant: |
deltarobot-vr/Assets/Materials/ActualDirectionMaterial.mat | ||
---|---|---|
1 |
%YAML 1.1 |
|
2 |
%TAG !u! tag:unity3d.com,2011: |
|
3 |
--- !u!21 &2100000 |
|
4 |
Material: |
|
5 |
serializedVersion: 6 |
|
6 |
m_ObjectHideFlags: 0 |
|
7 |
m_CorrespondingSourceObject: {fileID: 0} |
|
8 |
m_PrefabInstance: {fileID: 0} |
|
9 |
m_PrefabAsset: {fileID: 0} |
|
10 |
m_Name: ActualDirectionMaterial |
|
11 |
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} |
|
12 |
m_ShaderKeywords: |
|
13 |
m_LightmapFlags: 4 |
|
14 |
m_EnableInstancingVariants: 0 |
|
15 |
m_DoubleSidedGI: 0 |
|
16 |
m_CustomRenderQueue: -1 |
|
17 |
stringTagMap: {} |
|
18 |
disabledShaderPasses: [] |
|
19 |
m_SavedProperties: |
|
20 |
serializedVersion: 3 |
|
21 |
m_TexEnvs: |
|
22 |
- _BumpMap: |
|
23 |
m_Texture: {fileID: 0} |
|
24 |
m_Scale: {x: 1, y: 1} |
|
25 |
m_Offset: {x: 0, y: 0} |
|
26 |
- _DetailAlbedoMap: |
|
27 |
m_Texture: {fileID: 0} |
|
28 |
m_Scale: {x: 1, y: 1} |
|
29 |
m_Offset: {x: 0, y: 0} |
|
30 |
- _DetailMask: |
|
31 |
m_Texture: {fileID: 0} |
|
32 |
m_Scale: {x: 1, y: 1} |
|
33 |
m_Offset: {x: 0, y: 0} |
|
34 |
- _DetailNormalMap: |
|
35 |
m_Texture: {fileID: 0} |
|
36 |
m_Scale: {x: 1, y: 1} |
|
37 |
m_Offset: {x: 0, y: 0} |
|
38 |
- _EmissionMap: |
|
39 |
m_Texture: {fileID: 0} |
|
40 |
m_Scale: {x: 1, y: 1} |
|
41 |
m_Offset: {x: 0, y: 0} |
|
42 |
- _MainTex: |
|
43 |
m_Texture: {fileID: 0} |
|
44 |
m_Scale: {x: 1, y: 1} |
|
45 |
m_Offset: {x: 0, y: 0} |
|
46 |
- _MetallicGlossMap: |
|
47 |
m_Texture: {fileID: 0} |
|
48 |
m_Scale: {x: 1, y: 1} |
|
49 |
m_Offset: {x: 0, y: 0} |
|
50 |
- _OcclusionMap: |
|
51 |
m_Texture: {fileID: 0} |
|
52 |
m_Scale: {x: 1, y: 1} |
|
53 |
m_Offset: {x: 0, y: 0} |
|
54 |
- _ParallaxMap: |
|
55 |
m_Texture: {fileID: 0} |
|
56 |
m_Scale: {x: 1, y: 1} |
|
57 |
m_Offset: {x: 0, y: 0} |
|
58 |
m_Floats: |
|
59 |
- _BumpScale: 1 |
|
60 |
- _Cutoff: 0.5 |
|
61 |
- _DetailNormalMapScale: 1 |
|
62 |
- _DstBlend: 0 |
|
63 |
- _GlossMapScale: 1 |
|
64 |
- _Glossiness: 0.5 |
|
65 |
- _GlossyReflections: 1 |
|
66 |
- _Metallic: 0 |
|
67 |
- _Mode: 0 |
|
68 |
- _OcclusionStrength: 1 |
|
69 |
- _Parallax: 0.02 |
|
70 |
- _SmoothnessTextureChannel: 0 |
|
71 |
- _SpecularHighlights: 1 |
|
72 |
- _SrcBlend: 1 |
|
73 |
- _UVSec: 0 |
|
74 |
- _ZWrite: 1 |
|
75 |
m_Colors: |
|
76 |
- _Color: {r: 1, g: 0, b: 0, a: 1} |
|
77 |
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1} |
|
78 |
m_BuildTextureStacks: [] |
deltarobot-vr/Assets/Materials/ActualDirectionMaterial.mat.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 306843c96e6ccc5e292e116d1d3418a6 |
|
3 |
NativeFormatImporter: |
|
4 |
externalObjects: {} |
|
5 |
mainObjectFileID: 2100000 |
|
6 |
userData: |
|
7 |
assetBundleName: |
|
8 |
assetBundleVariant: |
deltarobot-vr/Assets/Materials/ActuatorMaterial.mat | ||
---|---|---|
1 |
%YAML 1.1 |
|
2 |
%TAG !u! tag:unity3d.com,2011: |
|
3 |
--- !u!21 &2100000 |
|
4 |
Material: |
|
5 |
serializedVersion: 6 |
|
6 |
m_ObjectHideFlags: 0 |
|
7 |
m_CorrespondingSourceObject: {fileID: 0} |
|
8 |
m_PrefabInstance: {fileID: 0} |
|
9 |
m_PrefabAsset: {fileID: 0} |
|
10 |
m_Name: ActuatorMaterial |
|
11 |
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} |
|
12 |
m_ShaderKeywords: |
|
13 |
m_LightmapFlags: 4 |
|
14 |
m_EnableInstancingVariants: 0 |
|
15 |
m_DoubleSidedGI: 0 |
|
16 |
m_CustomRenderQueue: -1 |
|
17 |
stringTagMap: {} |
|
18 |
disabledShaderPasses: [] |
|
19 |
m_SavedProperties: |
|
20 |
serializedVersion: 3 |
|
21 |
m_TexEnvs: |
|
22 |
- _BumpMap: |
|
23 |
m_Texture: {fileID: 0} |
|
24 |
m_Scale: {x: 1, y: 1} |
|
25 |
m_Offset: {x: 0, y: 0} |
|
26 |
- _DetailAlbedoMap: |
|
27 |
m_Texture: {fileID: 0} |
|
28 |
m_Scale: {x: 1, y: 1} |
|
29 |
m_Offset: {x: 0, y: 0} |
|
30 |
- _DetailMask: |
|
31 |
m_Texture: {fileID: 0} |
|
32 |
m_Scale: {x: 1, y: 1} |
|
33 |
m_Offset: {x: 0, y: 0} |
|
34 |
- _DetailNormalMap: |
|
35 |
m_Texture: {fileID: 0} |
|
36 |
m_Scale: {x: 1, y: 1} |
|
37 |
m_Offset: {x: 0, y: 0} |
|
38 |
- _EmissionMap: |
|
39 |
m_Texture: {fileID: 0} |
|
40 |
m_Scale: {x: 1, y: 1} |
|
41 |
m_Offset: {x: 0, y: 0} |
|
42 |
- _MainTex: |
|
43 |
m_Texture: {fileID: 0} |
|
44 |
m_Scale: {x: 1, y: 1} |
|
45 |
m_Offset: {x: 0, y: 0} |
|
46 |
- _MetallicGlossMap: |
|
47 |
m_Texture: {fileID: 0} |
|
48 |
m_Scale: {x: 1, y: 1} |
|
49 |
m_Offset: {x: 0, y: 0} |
|
50 |
- _OcclusionMap: |
|
51 |
m_Texture: {fileID: 0} |
|
52 |
m_Scale: {x: 1, y: 1} |
|
53 |
m_Offset: {x: 0, y: 0} |
|
54 |
- _ParallaxMap: |
|
55 |
m_Texture: {fileID: 0} |
|
56 |
m_Scale: {x: 1, y: 1} |
|
57 |
m_Offset: {x: 0, y: 0} |
|
58 |
m_Floats: |
|
59 |
- _BumpScale: 1 |
|
60 |
- _Cutoff: 0.5 |
|
61 |
- _DetailNormalMapScale: 1 |
|
62 |
- _DstBlend: 0 |
|
63 |
- _GlossMapScale: 1 |
|
64 |
- _Glossiness: 0.5 |
|
65 |
- _GlossyReflections: 1 |
|
66 |
- _Metallic: 0 |
|
67 |
- _Mode: 0 |
|
68 |
- _OcclusionStrength: 1 |
|
69 |
- _Parallax: 0.02 |
|
70 |
- _SmoothnessTextureChannel: 0 |
|
71 |
- _SpecularHighlights: 1 |
|
72 |
- _SrcBlend: 1 |
|
73 |
- _UVSec: 0 |
|
74 |
- _ZWrite: 1 |
|
75 |
m_Colors: |
|
76 |
- _Color: {r: 0, g: 0.61987686, b: 1, a: 1} |
|
77 |
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1} |
|
78 |
m_BuildTextureStacks: [] |
deltarobot-vr/Assets/Materials/ActuatorMaterial.mat.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: c14ddb25b53d5c1d38abd988a0ff268e |
|
3 |
NativeFormatImporter: |
|
4 |
externalObjects: {} |
|
5 |
mainObjectFileID: 2100000 |
|
6 |
userData: |
|
7 |
assetBundleName: |
|
8 |
assetBundleVariant: |
deltarobot-vr/Assets/Materials/CDArrowMaterial.mat | ||
---|---|---|
1 |
%YAML 1.1 |
|
2 |
%TAG !u! tag:unity3d.com,2011: |
|
3 |
--- !u!21 &2100000 |
|
4 |
Material: |
|
5 |
serializedVersion: 6 |
|
6 |
m_ObjectHideFlags: 0 |
|
7 |
m_CorrespondingSourceObject: {fileID: 0} |
|
8 |
m_PrefabInstance: {fileID: 0} |
|
9 |
m_PrefabAsset: {fileID: 0} |
|
10 |
m_Name: CDArrowMaterial |
|
11 |
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} |
|
12 |
m_ShaderKeywords: |
|
13 |
m_LightmapFlags: 4 |
|
14 |
m_EnableInstancingVariants: 0 |
|
15 |
m_DoubleSidedGI: 0 |
|
16 |
m_CustomRenderQueue: -1 |
|
17 |
stringTagMap: {} |
|
18 |
disabledShaderPasses: [] |
|
19 |
m_SavedProperties: |
|
20 |
serializedVersion: 3 |
|
21 |
m_TexEnvs: |
|
22 |
- _BumpMap: |
|
23 |
m_Texture: {fileID: 0} |
|
24 |
m_Scale: {x: 1, y: 1} |
|
25 |
m_Offset: {x: 0, y: 0} |
|
26 |
- _DetailAlbedoMap: |
|
27 |
m_Texture: {fileID: 0} |
|
28 |
m_Scale: {x: 1, y: 1} |
|
29 |
m_Offset: {x: 0, y: 0} |
|
30 |
- _DetailMask: |
|
31 |
m_Texture: {fileID: 0} |
|
32 |
m_Scale: {x: 1, y: 1} |
|
33 |
m_Offset: {x: 0, y: 0} |
|
34 |
- _DetailNormalMap: |
|
35 |
m_Texture: {fileID: 0} |
|
36 |
m_Scale: {x: 1, y: 1} |
|
37 |
m_Offset: {x: 0, y: 0} |
|
38 |
- _EmissionMap: |
|
39 |
m_Texture: {fileID: 0} |
|
40 |
m_Scale: {x: 1, y: 1} |
|
41 |
m_Offset: {x: 0, y: 0} |
|
42 |
- _MainTex: |
|
43 |
m_Texture: {fileID: 0} |
|
44 |
m_Scale: {x: 1, y: 1} |
|
45 |
m_Offset: {x: 0, y: 0} |
|
46 |
- _MetallicGlossMap: |
|
47 |
m_Texture: {fileID: 0} |
|
48 |
m_Scale: {x: 1, y: 1} |
|
49 |
m_Offset: {x: 0, y: 0} |
|
50 |
- _OcclusionMap: |
|
51 |
m_Texture: {fileID: 0} |
|
52 |
m_Scale: {x: 1, y: 1} |
|
53 |
m_Offset: {x: 0, y: 0} |
|
54 |
- _ParallaxMap: |
|
55 |
m_Texture: {fileID: 0} |
|
56 |
m_Scale: {x: 1, y: 1} |
|
57 |
m_Offset: {x: 0, y: 0} |
|
58 |
m_Floats: |
|
59 |
- _BumpScale: 1 |
|
60 |
- _Cutoff: 0.5 |
|
61 |
- _DetailNormalMapScale: 1 |
|
62 |
- _DstBlend: 0 |
|
63 |
- _GlossMapScale: 1 |
|
64 |
- _Glossiness: 0.5 |
|
65 |
- _GlossyReflections: 1 |
|
66 |
- _Metallic: 0 |
|
67 |
- _Mode: 0 |
|
68 |
- _OcclusionStrength: 1 |
|
69 |
- _Parallax: 0.02 |
|
70 |
- _SmoothnessTextureChannel: 0 |
|
71 |
- _SpecularHighlights: 1 |
|
72 |
- _SrcBlend: 1 |
|
73 |
- _UVSec: 0 |
|
74 |
- _ZWrite: 1 |
|
75 |
m_Colors: |
|
76 |
- _Color: {r: 1, g: 0, b: 0, a: 1} |
|
77 |
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1} |
|
78 |
m_BuildTextureStacks: [] |
deltarobot-vr/Assets/Materials/CDArrowMaterial.mat.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: ba5e94541fd24e84d8a7cef22c83d162 |
|
3 |
NativeFormatImporter: |
|
4 |
externalObjects: {} |
|
5 |
mainObjectFileID: 2100000 |
|
6 |
userData: |
|
7 |
assetBundleName: |
|
8 |
assetBundleVariant: |
deltarobot-vr/Assets/Materials/CubeMaterial.mat | ||
---|---|---|
1 |
%YAML 1.1 |
|
2 |
%TAG !u! tag:unity3d.com,2011: |
|
3 |
--- !u!21 &2100000 |
|
4 |
Material: |
|
5 |
serializedVersion: 6 |
|
6 |
m_ObjectHideFlags: 0 |
|
7 |
m_CorrespondingSourceObject: {fileID: 0} |
|
8 |
m_PrefabInstance: {fileID: 0} |
|
9 |
m_PrefabAsset: {fileID: 0} |
|
10 |
m_Name: CubeMaterial |
|
11 |
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} |
|
12 |
m_ShaderKeywords: |
|
13 |
m_LightmapFlags: 4 |
|
14 |
m_EnableInstancingVariants: 0 |
|
15 |
m_DoubleSidedGI: 0 |
|
16 |
m_CustomRenderQueue: -1 |
|
17 |
stringTagMap: {} |
|
18 |
disabledShaderPasses: [] |
|
19 |
m_SavedProperties: |
|
20 |
serializedVersion: 3 |
|
21 |
m_TexEnvs: |
|
22 |
- _BumpMap: |
|
23 |
m_Texture: {fileID: 0} |
|
24 |
m_Scale: {x: 1, y: 1} |
|
25 |
m_Offset: {x: 0, y: 0} |
|
26 |
- _DetailAlbedoMap: |
|
27 |
m_Texture: {fileID: 0} |
|
28 |
m_Scale: {x: 1, y: 1} |
|
29 |
m_Offset: {x: 0, y: 0} |
|
30 |
- _DetailMask: |
|
31 |
m_Texture: {fileID: 0} |
|
32 |
m_Scale: {x: 1, y: 1} |
|
33 |
m_Offset: {x: 0, y: 0} |
|
34 |
- _DetailNormalMap: |
|
35 |
m_Texture: {fileID: 0} |
|
36 |
m_Scale: {x: 1, y: 1} |
|
37 |
m_Offset: {x: 0, y: 0} |
|
38 |
- _EmissionMap: |
|
39 |
m_Texture: {fileID: 0} |
|
40 |
m_Scale: {x: 1, y: 1} |
|
41 |
m_Offset: {x: 0, y: 0} |
|
42 |
- _MainTex: |
|
43 |
m_Texture: {fileID: 0} |
|
44 |
m_Scale: {x: 1, y: 1} |
|
45 |
m_Offset: {x: 0, y: 0} |
|
46 |
- _MetallicGlossMap: |
|
47 |
m_Texture: {fileID: 0} |
|
48 |
m_Scale: {x: 1, y: 1} |
|
49 |
m_Offset: {x: 0, y: 0} |
|
50 |
- _OcclusionMap: |
|
51 |
m_Texture: {fileID: 0} |
|
52 |
m_Scale: {x: 1, y: 1} |
|
53 |
m_Offset: {x: 0, y: 0} |
|
54 |
- _ParallaxMap: |
|
55 |
m_Texture: {fileID: 0} |
|
56 |
m_Scale: {x: 1, y: 1} |
|
57 |
m_Offset: {x: 0, y: 0} |
|
58 |
m_Floats: |
|
59 |
- _BumpScale: 1 |
|
60 |
- _Cutoff: 0.5 |
|
61 |
- _DetailNormalMapScale: 1 |
|
62 |
- _DstBlend: 0 |
|
63 |
- _GlossMapScale: 1 |
|
64 |
- _Glossiness: 0.5 |
|
65 |
- _GlossyReflections: 1 |
|
66 |
- _Metallic: 0 |
|
67 |
- _Mode: 0 |
|
68 |
- _OcclusionStrength: 1 |
|
69 |
- _Parallax: 0.02 |
|
70 |
- _SmoothnessTextureChannel: 0 |
|
71 |
- _SpecularHighlights: 1 |
|
72 |
- _SrcBlend: 1 |
|
73 |
- _UVSec: 0 |
|
74 |
- _ZWrite: 1 |
|
75 |
m_Colors: |
|
76 |
- _Color: {r: 0, g: 0.61987686, b: 1, a: 1} |
|
77 |
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1} |
|
78 |
m_BuildTextureStacks: [] |
deltarobot-vr/Assets/Materials/CubeMaterial.mat.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 62f2cab33e7d65346be49f4912bdd9ee |
|
3 |
NativeFormatImporter: |
|
4 |
externalObjects: {} |
|
5 |
mainObjectFileID: 2100000 |
|
6 |
userData: |
|
7 |
assetBundleName: |
|
8 |
assetBundleVariant: |
deltarobot-vr/Assets/Materials/CurveMaterial 1.mat | ||
---|---|---|
1 |
%YAML 1.1 |
|
2 |
%TAG !u! tag:unity3d.com,2011: |
|
3 |
--- !u!21 &2100000 |
|
4 |
Material: |
|
5 |
serializedVersion: 6 |
|
6 |
m_ObjectHideFlags: 0 |
|
7 |
m_CorrespondingSourceObject: {fileID: 0} |
|
8 |
m_PrefabInstance: {fileID: 0} |
|
9 |
m_PrefabAsset: {fileID: 0} |
|
10 |
m_Name: CurveMaterial 1 |
|
11 |
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} |
|
12 |
m_ShaderKeywords: |
|
13 |
m_LightmapFlags: 4 |
|
14 |
m_EnableInstancingVariants: 0 |
|
15 |
m_DoubleSidedGI: 0 |
|
16 |
m_CustomRenderQueue: -1 |
|
17 |
stringTagMap: {} |
|
18 |
disabledShaderPasses: [] |
|
19 |
m_SavedProperties: |
|
20 |
serializedVersion: 3 |
|
21 |
m_TexEnvs: |
|
22 |
- _BumpMap: |
|
23 |
m_Texture: {fileID: 0} |
|
24 |
m_Scale: {x: 1, y: 1} |
|
25 |
m_Offset: {x: 0, y: 0} |
|
26 |
- _DetailAlbedoMap: |
|
27 |
m_Texture: {fileID: 0} |
|
28 |
m_Scale: {x: 1, y: 1} |
|
29 |
m_Offset: {x: 0, y: 0} |
|
30 |
- _DetailMask: |
|
31 |
m_Texture: {fileID: 0} |
|
32 |
m_Scale: {x: 1, y: 1} |
|
33 |
m_Offset: {x: 0, y: 0} |
|
34 |
- _DetailNormalMap: |
|
35 |
m_Texture: {fileID: 0} |
|
36 |
m_Scale: {x: 1, y: 1} |
|
37 |
m_Offset: {x: 0, y: 0} |
|
38 |
- _EmissionMap: |
|
39 |
m_Texture: {fileID: 0} |
|
40 |
m_Scale: {x: 1, y: 1} |
|
41 |
m_Offset: {x: 0, y: 0} |
|
42 |
- _MainTex: |
|
43 |
m_Texture: {fileID: 0} |
|
44 |
m_Scale: {x: 1, y: 1} |
|
45 |
m_Offset: {x: 0, y: 0} |
|
46 |
- _MetallicGlossMap: |
|
47 |
m_Texture: {fileID: 0} |
|
48 |
m_Scale: {x: 1, y: 1} |
|
49 |
m_Offset: {x: 0, y: 0} |
|
50 |
- _OcclusionMap: |
|
51 |
m_Texture: {fileID: 0} |
|
52 |
m_Scale: {x: 1, y: 1} |
|
53 |
m_Offset: {x: 0, y: 0} |
|
54 |
- _ParallaxMap: |
|
55 |
m_Texture: {fileID: 0} |
|
56 |
m_Scale: {x: 1, y: 1} |
|
57 |
m_Offset: {x: 0, y: 0} |
|
58 |
m_Floats: |
|
59 |
- _BumpScale: 1 |
|
60 |
- _Cutoff: 0.5 |
|
61 |
- _DetailNormalMapScale: 1 |
|
62 |
- _DstBlend: 0 |
|
63 |
- _GlossMapScale: 1 |
|
64 |
- _Glossiness: 0.5 |
|
65 |
- _GlossyReflections: 1 |
|
66 |
- _Metallic: 0 |
|
67 |
- _Mode: 0 |
|
68 |
- _OcclusionStrength: 1 |
|
69 |
- _Parallax: 0.02 |
|
70 |
- _SmoothnessTextureChannel: 0 |
|
71 |
- _SpecularHighlights: 1 |
|
72 |
- _SrcBlend: 1 |
|
73 |
- _UVSec: 0 |
|
74 |
- _ZWrite: 1 |
|
75 |
m_Colors: |
|
76 |
- _Color: {r: 1, g: 1, b: 0, a: 1} |
|
77 |
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1} |
|
78 |
m_BuildTextureStacks: [] |
deltarobot-vr/Assets/Materials/CurveMaterial 1.mat.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 4fccf519985fbac4cafe474b1888cf3c |
|
3 |
NativeFormatImporter: |
|
4 |
externalObjects: {} |
|
5 |
mainObjectFileID: 2100000 |
|
6 |
userData: |
|
7 |
assetBundleName: |
|
8 |
assetBundleVariant: |
deltarobot-vr/Assets/Materials/CurveMaterial.mat | ||
---|---|---|
1 |
%YAML 1.1 |
|
2 |
%TAG !u! tag:unity3d.com,2011: |
|
3 |
--- !u!21 &2100000 |
|
4 |
Material: |
|
5 |
serializedVersion: 6 |
|
6 |
m_ObjectHideFlags: 0 |
|
7 |
m_CorrespondingSourceObject: {fileID: 0} |
|
8 |
m_PrefabInstance: {fileID: 0} |
|
9 |
m_PrefabAsset: {fileID: 0} |
|
10 |
m_Name: CurveMaterial |
|
11 |
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} |
|
12 |
m_ShaderKeywords: |
|
13 |
m_LightmapFlags: 4 |
|
14 |
m_EnableInstancingVariants: 0 |
|
15 |
m_DoubleSidedGI: 0 |
|
16 |
m_CustomRenderQueue: -1 |
|
17 |
stringTagMap: {} |
|
18 |
disabledShaderPasses: [] |
|
19 |
m_SavedProperties: |
|
20 |
serializedVersion: 3 |
|
21 |
m_TexEnvs: |
|
22 |
- _BumpMap: |
|
23 |
m_Texture: {fileID: 0} |
|
24 |
m_Scale: {x: 1, y: 1} |
|
25 |
m_Offset: {x: 0, y: 0} |
|
26 |
- _DetailAlbedoMap: |
|
27 |
m_Texture: {fileID: 0} |
|
28 |
m_Scale: {x: 1, y: 1} |
|
29 |
m_Offset: {x: 0, y: 0} |
|
30 |
- _DetailMask: |
|
31 |
m_Texture: {fileID: 0} |
|
32 |
m_Scale: {x: 1, y: 1} |
|
33 |
m_Offset: {x: 0, y: 0} |
|
34 |
- _DetailNormalMap: |
|
35 |
m_Texture: {fileID: 0} |
|
36 |
m_Scale: {x: 1, y: 1} |
|
37 |
m_Offset: {x: 0, y: 0} |
|
38 |
- _EmissionMap: |
|
39 |
m_Texture: {fileID: 0} |
|
40 |
m_Scale: {x: 1, y: 1} |
|
41 |
m_Offset: {x: 0, y: 0} |
|
42 |
- _MainTex: |
|
43 |
m_Texture: {fileID: 0} |
|
44 |
m_Scale: {x: 1, y: 1} |
|
45 |
m_Offset: {x: 0, y: 0} |
|
46 |
- _MetallicGlossMap: |
|
47 |
m_Texture: {fileID: 0} |
|
48 |
m_Scale: {x: 1, y: 1} |
|
49 |
m_Offset: {x: 0, y: 0} |
|
50 |
- _OcclusionMap: |
|
51 |
m_Texture: {fileID: 0} |
|
52 |
m_Scale: {x: 1, y: 1} |
|
53 |
m_Offset: {x: 0, y: 0} |
|
54 |
- _ParallaxMap: |
|
55 |
m_Texture: {fileID: 0} |
|
56 |
m_Scale: {x: 1, y: 1} |
|
57 |
m_Offset: {x: 0, y: 0} |
|
58 |
m_Floats: |
|
59 |
- _BumpScale: 1 |
|
60 |
- _Cutoff: 0.5 |
|
61 |
- _DetailNormalMapScale: 1 |
|
62 |
- _DstBlend: 0 |
|
63 |
- _GlossMapScale: 1 |
|
64 |
- _Glossiness: 0.5 |
|
65 |
- _GlossyReflections: 1 |
|
66 |
- _Metallic: 0 |
|
67 |
- _Mode: 0 |
|
68 |
- _OcclusionStrength: 1 |
|
69 |
- _Parallax: 0.02 |
|
70 |
- _SmoothnessTextureChannel: 0 |
|
71 |
- _SpecularHighlights: 1 |
|
72 |
- _SrcBlend: 1 |
|
73 |
- _UVSec: 0 |
|
74 |
- _ZWrite: 1 |
|
75 |
m_Colors: |
|
76 |
- _Color: {r: 1, g: 1, b: 0, a: 1} |
|
77 |
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1} |
|
78 |
m_BuildTextureStacks: [] |
deltarobot-vr/Assets/Materials/CurveMaterial.mat.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 4fccf519985fbac4cafe474b1888cf3c |
|
3 |
NativeFormatImporter: |
|
4 |
externalObjects: {} |
|
5 |
mainObjectFileID: 2100000 |
|
6 |
userData: |
|
7 |
assetBundleName: |
|
8 |
assetBundleVariant: |
deltarobot-vr/Assets/Materials/DDArrowMaterial.mat | ||
---|---|---|
1 |
%YAML 1.1 |
|
2 |
%TAG !u! tag:unity3d.com,2011: |
|
3 |
--- !u!21 &2100000 |
|
4 |
Material: |
|
5 |
serializedVersion: 6 |
|
6 |
m_ObjectHideFlags: 0 |
|
7 |
m_CorrespondingSourceObject: {fileID: 0} |
|
8 |
m_PrefabInstance: {fileID: 0} |
|
9 |
m_PrefabAsset: {fileID: 0} |
|
10 |
m_Name: DDArrowMaterial |
|
11 |
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} |
|
12 |
m_ShaderKeywords: |
|
13 |
m_LightmapFlags: 4 |
|
14 |
m_EnableInstancingVariants: 0 |
Také k dispozici: Unified diff
Re #8906 - Server and client refactor