Skip to content
This repository was archived by the owner on May 9, 2025. It is now read-only.

Commit 5429a68

Browse files
Moved stacktrace functions into an editor-only section
1 parent 6b141da commit 5429a68

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Assets/SO Architecture/Events/Game Events/GameEventBase.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ public abstract class GameEventBase<T> : SOArchitectureBaseObject, IGameEvent<T>
1111
#if UNITY_EDITOR
1212
[SerializeField]
1313
protected T _debugValue;
14-
#endif
1514

1615
public void AddStackTrace()
1716
{
@@ -21,6 +20,7 @@ public void AddStackTrace(object value)
2120
{
2221
_stackTraces.Insert(0, StackTraceEntry.Create(value));
2322
}
23+
#endif
2424
public void Raise(T value)
2525
{
2626
AddStackTrace(value);
@@ -46,6 +46,7 @@ public abstract class GameEventBase : SOArchitectureBaseObject, IGameEvent, ISta
4646
public List<StackTraceEntry> StackTraces { get { return _stackTraces; } }
4747
private List<StackTraceEntry> _stackTraces = new List<StackTraceEntry>();
4848

49+
#if UNITY_EDITOR
4950
public void AddStackTrace()
5051
{
5152
_stackTraces.Insert(0, StackTraceEntry.Create());
@@ -54,6 +55,8 @@ public void AddStackTrace(object value)
5455
{
5556
_stackTraces.Insert(0, StackTraceEntry.Create(value));
5657
}
58+
#endif
59+
5760
public void Raise()
5861
{
5962
AddStackTrace();

0 commit comments

Comments
 (0)