using UnityEngine;
using System.Collections;
#if UNITY_EDITOR
using UnityEditor;
#endif
namespace AC
{
public class SetFullWindowedScreenMode : Action
{
// Declare variables here
public bool isFullscreen ;
public SetFullWindowedScreenMode ()
{
this.isDisplayed = true;
category = ActionCategory.Custom;
title = "Set FullScreen or Windowed";
description = "Set FullScreen or Windowed";
}
override public float Run ()
{
isFullscreen = GlobalVariables.GetBooleanValue (your Variable id);
if (isFullscreen == false)
{
// Set to fullscreen
Screen.SetResolution (1366, 768, true);
GlobalVariables.SetBooleanValue(your Variable id, true);
}
else
{
Screen.SetResolution (1366, 768, false);
GlobalVariables.SetBooleanValue(your Variable id, false);
}
return 0f;
}
}
}
It looks like you're new here. If you want to get involved, click one of these buttons!