This commit is contained in:
in0finite 2022-01-30 01:06:45 +01:00
parent fa933411d0
commit fe61e9898f
10 changed files with 15 additions and 15 deletions

View file

@ -128,7 +128,7 @@ namespace SanAndreasUnity.Behaviours.Audio
audioSource.Play();
// destroy game object when sound is finished playing
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
Destroy( audioSource.gameObject, clip.length );
return audioSource;

View file

@ -44,7 +44,7 @@ namespace SanAndreasUnity.Behaviours.World
info.TargetInterior),
Quaternion.identity);
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
gameObject.SetActive(false);
gameObject.isStatic = true;

View file

@ -138,7 +138,7 @@ namespace SanAndreasUnity.Behaviours.World
this.SetDrawDistance(ObjectDefinition?.DrawDist ?? 0);
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
gameObject.SetActive(false);
gameObject.isStatic = true;
}
@ -299,7 +299,7 @@ namespace SanAndreasUnity.Behaviours.World
private bool NeedsFading()
{
if (F.IsAppInEditTime)
if (F.IsAppInEditMode)
return false;
if (F.IsInHeadlessMode)

View file

@ -176,7 +176,7 @@ namespace SanAndreasUnity.Editor
if (this.IsExportingFromGameFiles)
{
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
{
EditorUtility.DisplayDialog("", "This type of export can only run in edit-mode.", "Ok");
yield break;

View file

@ -21,7 +21,7 @@ namespace SanAndreasUnity.Editor
static void EditorUpdate()
{
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
return;
if (Loader.IsLoading)
@ -39,7 +39,7 @@ namespace SanAndreasUnity.Editor
{
EditorUtility.ClearProgressBar();
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
return;
if (Loader.HasLoaded)
@ -51,7 +51,7 @@ namespace SanAndreasUnity.Editor
[MenuItem(EditorCore.MenuName + "/" + "Load game data")]
static void MenuItemLoadGameData()
{
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
{
EditorUtility.DisplayDialog("", "This can only be used in edit mode.", "Ok");
return;
@ -74,7 +74,7 @@ namespace SanAndreasUnity.Editor
[MenuItem(EditorCore.MenuName + "/" + "Change path to GTA")]
static void MenuItemChangePath()
{
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
{
EditorUtility.DisplayDialog("", "Exit play mode first.", "Ok");
return;

View file

@ -46,7 +46,7 @@ namespace SanAndreasUnity.Net
void OnLoaderFinished()
{
if (F.IsAppInEditTime)
if (F.IsAppInEditMode)
return;
if (NetStatus.IsServer) // don't do anything on server

View file

@ -104,7 +104,7 @@ namespace SanAndreasUnity.UI
void OnLoaderFinished()
{
if (F.IsAppInEditTime)
if (F.IsAppInEditMode)
return;
// assign textures to movement buttons' arrows

View file

@ -19,7 +19,7 @@ namespace SanAndreasUnity.Utilities
static void EditorUpdate()
{
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
return;
m_coroutineRunner.Update();

View file

@ -421,7 +421,7 @@ namespace SanAndreasUnity.Utilities
public static void DestroyEvenInEditMode(Object obj)
{
if (F.IsAppInEditTime)
if (F.IsAppInEditMode)
Object.DestroyImmediate(obj, false);
else
Object.Destroy(obj);
@ -1063,7 +1063,7 @@ namespace SanAndreasUnity.Utilities
}
}
public static bool IsAppInEditTime
public static bool IsAppInEditMode
{
get
{

View file

@ -26,7 +26,7 @@ namespace SanAndreasUnity.Utilities
{
get
{
if (!F.IsAppInEditTime)
if (!F.IsAppInEditMode)
{
return s_cachedSingleton;
}