Quantcast
Channel: Answers for "Start/Stop Playmode from editor script"
Browsing all 23 articles
Browse latest View live

Answer by Sigil

I didn't see a direct call, but this worked in my editor script (dll to be particular): EditorApplication.ExecuteMenuItem("Edit/Play");

View Article



Answer by Bunny83

Well, you can also set [EditorApplication.isPlaying][1] ;) ***edit*** Since there were complaints that "EditorApplication" can't be used in runtime scripts, here's how you **can** use it: //C# public...

View Article

Answer by FiveFingers

Application.isPlaying is read only play state. Accessing the menu works, but only on a editor script. Not on a runtime one. EditorApplicatio can't be used there.

View Article

Answer by salat

isPlaying work only in Editor scripts. in runtime use Debug.Break() to pause (not same as Debug.DebugBreak()) http://docs.unity3d.com/Documentation/ScriptReference/Debug.Break.html

View Article

Answer by Istador

Debug.Break() is pausing the game, not stopping it. Sadly you can't build a standalone version with "UnityEditor.EditorApplication.isPlaying = false;" in your code, because the class is unknown to the...

View Article


Answer by Pawcijo

In Unity 5.x u can change Application.isPlaying to false and it works :) @Pawcijo

View Article

Answer by Dynam1ke

you can also make a Debug.LogError("test") and make the editor pause on error

View Article

Answer by Sigil

I didn't see a direct call, but this worked in my editor script (dll to be particular): EditorApplication.ExecuteMenuItem("Edit/Play");

View Article


Answer by Bunny83

Well, you can also set [EditorApplication.isPlaying][1] ;) ***edit*** Since there were complaints that "EditorApplication" can't be used in runtime scripts, here's how you **can** use it: //C# public...

View Article


Answer by FiveFingers

Application.isPlaying is read only play state. Accessing the menu works, but only on a editor script. Not on a runtime one. EditorApplicatio can't be used there.

View Article

Answer by salat

isPlaying work only in Editor scripts. in runtime use Debug.Break() to pause (not same as Debug.DebugBreak()) http://docs.unity3d.com/Documentation/ScriptReference/Debug.Break.html

View Article

Answer by Istador

Debug.Break() is pausing the game, not stopping it. Sadly you can't build a standalone version with "UnityEditor.EditorApplication.isPlaying = false;" in your code, because the class is unknown to the...

View Article

Answer by Pawcijo

In Unity 5.x u can change Application.isPlaying to false and it works :) @Pawcijo

View Article


Answer by Dynam1ke

you can also make a Debug.LogError("test") and make the editor pause on error

View Article

Answer by Sigil

I didn't see a direct call, but this worked in my editor script (dll to be particular): EditorApplication.ExecuteMenuItem("Edit/Play");

View Article


Answer by Bunny83

Well, you can also set [EditorApplication.isPlaying][1] ;) ***edit*** Since there were complaints that "EditorApplication" can't be used in runtime scripts, here's how you **can** use it: //C# public...

View Article

Answer by FiveFingers

Application.isPlaying is read only play state. Accessing the menu works, but only on a editor script. Not on a runtime one. EditorApplicatio can't be used there.

View Article


Answer by salat

isPlaying work only in Editor scripts. in runtime use Debug.Break() to pause (not same as Debug.DebugBreak()) http://docs.unity3d.com/Documentation/ScriptReference/Debug.Break.html

View Article

Answer by Istador

Debug.Break() is pausing the game, not stopping it. Sadly you can't build a standalone version with "UnityEditor.EditorApplication.isPlaying = false;" in your code, because the class is unknown to the...

View Article

Answer by Pawcijo

In Unity 5.x u can change Application.isPlaying to false and it works :) @Pawcijo

View Article
Browsing all 23 articles
Browse latest View live




Latest Images