Ejemplo n.º 1
0
        public static void OpenWelcomeWindow()
        {
            var window = GetWindow <PlayMakerWelcomeWindow>(true);

            window.SetPage(Page.Welcome);
            PlayMakerAddonManager.ResetView();
        }
        public static void OpenWelcomeWindow()
        {
            var window = GetWindow <PlayMakerWelcomeWindow>(true);

            window.SetPage(Page.Welcome);
            PlayMakerAddonManager.ResetView();

            // give window a chance to draw first:
            EditorApplication.update += CheckUnityVersion;
        }
        public void OnEnable()
        {
#if UNITY_PRE_5_1
            title = "Welcome To PlayMaker";
#else
            titleContent = new GUIContent("Welcome To PlayMaker");
#endif
            maxSize = new Vector2(windowWidth, windowHeight);
            minSize = maxSize;

            // Try to get current playmaker version if installed
            GetPlayMakerVersion();

            // Is this the install for the student version?
            isStudentVersion = AssetGUIDs.IsStudentVersionInstall();

            // Init add-ons manager
            PlayMakerAddonManager.Init();

            // Setup pages

            currentPageRect = new Rect(0, pageTop, windowWidth, windowHeight - pagePadding);
            nextPageRect    = new Rect(0, pageTop, windowWidth, windowHeight - pagePadding);
            headerRect      = new Rect(0, 0, windowWidth, 60);
            backButtonRect  = new Rect(0, windowHeight - 24, 123, 24);

            // Save page to survive recompile...?
            currentPage = (Page)EditorPrefs.GetInt(editorPrefsSavedPage, (int)Page.Welcome);

            //currentPage = Page.Welcome;

            // We want to show the Upgrade Guide after installing

            /*
             * if (EditorStartupPrefs.ShowUpgradeGuide)
             * {
             *  //currentPage = Page.UpgradeGuide; //TODO: This was problematic
             *  EditorStartupPrefs.ShowUpgradeGuide = false; // reset
             *  EditorUtility.DisplayDialog("PlayMaker",
             *      "Please check the Upgrade Guide for more information on this release.",
             *      "OK");
             * }*/

            SetPage(currentPage);
            Update();
        }
 private static void DoAddonsPage()
 {
     PlayMakerAddonManager.OnGUI();
 }
 protected void OnDisable()
 {
     PlayMakerAddonManager.SaveSettings();
 }