You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Tooltip("When the measurements should be taken.\n\nManual should only be selected if the user is calling the RecordRow method either from another script or a custom Tracker class.")]
58
+
[Tooltip("When the measurements should be taken."+
59
+
"\n\nManual should only be selected if the user is calling the RecordRow method"+
60
+
" either from another script or a custom Tracker class.")]
"Tracker measurements cannot be taken when not recording!");
84
88
85
89
UXFDataRownewRow=GetCurrentValues();
86
90
newRow.Add(("time",Time.time));
@@ -92,43 +96,40 @@ public void RecordRow()
92
96
/// </summary>
93
97
publicvoidStartRecording()
94
98
{
95
-
if(currentState==TrackerState.On)
99
+
if(currentState==TrackerState.Recording)
96
100
{
97
-
Debug.LogWarning($"Start command received for tracker in state: '{TrackerState.On}'."+
98
-
$" This will dump exisiting data! "+
99
-
"If you want to restart a paused tracker, use 'ResumeRecording()' instead.");
101
+
Utilities.UXFDebugLogWarning($"Start command received for tracker in state: '{TrackerState.Recording}'."+
102
+
" This will dump exisiting data! "+
103
+
$"If you want to restart a paused tracker, use '{nameof(ResumeRecording)}()' instead.");
100
104
}
101
105
varheader=baseHeaders.Concat(CustomHeader);
102
106
Data=newUXFDataTable(header.ToArray());
103
-
recording=true;
104
-
currentState=TrackerState.On;
107
+
currentState=TrackerState.Recording;
105
108
}
106
109
107
110
/// <summary>
108
111
/// Stops recording.
109
112
/// </summary>
110
113
publicvoidStopRecording()
111
114
{
112
-
if(currentState!=TrackerState.On)
115
+
if(currentState!=TrackerState.Recording)
113
116
{
114
-
Debug.LogWarning($"Stop command received for tracker in state: '{currentState}'."+
115
-
$" This should only be called when tracker is in state '{TrackerState.On}'");
117
+
Utilities.UXFDebugLogWarning($"Stop command received for tracker in state: '{currentState}'."+
118
+
$" This should only be called when tracker is in state '{TrackerState.Recording}'");
116
119
}
117
-
recording=false;
118
-
currentState=TrackerState.Off;
120
+
currentState=TrackerState.Stopped;
119
121
}
120
122
121
123
/// <summary>
122
124
/// Pauses recording.
123
125
/// </summary>
124
126
publicvoidPauseRecording()
125
127
{
126
-
if(currentState!=TrackerState.On)
128
+
if(currentState!=TrackerState.Recording)
127
129
{
128
-
Debug.LogWarning($"Pause command received for tracker in state: '{currentState}'."+
129
-
$"This should only be called when tracker is in state '{TrackerState.On}'");
130
+
Utilities.UXFDebugLogWarning($"Pause command received for tracker in state: '{currentState}'."+
131
+
$"This should only be called when tracker is in state '{TrackerState.Recording}'");
130
132
}
131
-
recording=false;
132
133
currentState=TrackerState.Paused;
133
134
}
134
135
@@ -139,11 +140,10 @@ public void ResumeRecording()
139
140
{
140
141
if(currentState!=TrackerState.Paused)
141
142
{
142
-
Debug.LogWarning($"Resume command received for tracker in state: '{currentState}'."+
143
+
Utilities.UXFDebugLogWarning($"Resume command received for tracker in state: '{currentState}'."+
143
144
$"This should only be called when tracker is in state '{TrackerState.Paused}'");
144
145
}
145
-
recording=true;
146
-
currentState=TrackerState.On;
146
+
currentState=TrackerState.Recording;
147
147
}
148
148
149
149
/// <summary>
@@ -155,7 +155,9 @@ public void ResumeRecording()
155
155
}
156
156
157
157
/// <summary>
158
-
/// When the tracker should collect new measurements. Manual should only be selected if the user is calling the RecordRow method either from another script or a custom Tracker class.
158
+
/// When the tracker should collect new measurements.
159
+
/// Manual should only be selected if the user is calling the RecordRow method
160
+
/// either from another script or a custom Tracker class.
0 commit comments