Skip to content

Commit 8d1590c

Browse files
committed
Removed unneccessary calls to initmonoevaluator.
1 parent 0f52aae commit 8d1590c

File tree

1 file changed

+1
-13
lines changed

1 file changed

+1
-13
lines changed

Runtime/DevConsoleMono.cs

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1160,6 +1160,7 @@ private void Awake()
11601160
InitBuiltInCommands();
11611161
InitBuiltInParsers();
11621162
InitAttributes();
1163+
InitMonoEvaluator();
11631164

11641165
// Enable the console by default if in editor or a development build
11651166
if (Debug.isDebugBuild)
@@ -1177,11 +1178,6 @@ private void Awake()
11771178
_init = false;
11781179
}
11791180

1180-
private void Start()
1181-
{
1182-
InitMonoEvaluator();
1183-
}
1184-
11851181
private void Update()
11861182
{
11871183
if (!ConsoleIsEnabled || !ConsoleIsShowing)
@@ -2322,7 +2318,6 @@ void logChildren(GameObject obj, int tabAmount)
23222318
Parameter.Create("expression", "The expression to evaluate"),
23232319
input =>
23242320
{
2325-
InitMonoEvaluator();
23262321
try
23272322
{
23282323
if (!input.EndsWith(";"))
@@ -2360,7 +2355,6 @@ void logChildren(GameObject obj, int tabAmount)
23602355
Parameter.Create("statement", "The statement to execute"),
23612356
input =>
23622357
{
2363-
InitMonoEvaluator();
23642358
try
23652359
{
23662360
if (!input.EndsWith(";"))
@@ -2390,8 +2384,6 @@ void logChildren(GameObject obj, int tabAmount)
23902384
"Display a list of all active using statements",
23912385
() =>
23922386
{
2393-
InitMonoEvaluator();
2394-
23952387
string usings = _monoEvaluator.GetUsing();
23962388

23972389
if (string.IsNullOrEmpty(usings))
@@ -2412,8 +2404,6 @@ void logChildren(GameObject obj, int tabAmount)
24122404
"Display a list of all local variables defined",
24132405
() =>
24142406
{
2415-
InitMonoEvaluator();
2416-
24172407
string vars = _monoEvaluator.GetVars();
24182408

24192409
if (string.IsNullOrEmpty(vars))
@@ -2436,8 +2426,6 @@ void logChildren(GameObject obj, int tabAmount)
24362426
Parameter.Create("enabled", "Whether the using statement is automatically included upon starting the developer console"),
24372427
(usingName, enabled) =>
24382428
{
2439-
InitMonoEvaluator();
2440-
24412429
if (enabled)
24422430
{
24432431
if (_includedUsings.Contains(usingName))

0 commit comments

Comments
 (0)