Пример #1
0
        public ScenesWindow(Rect rect, GUIStyle style, params GUILayoutOption[] options)
            : base(rect, new GUIContent(TC.get("Element.Name1")), style, options)
        {
            var content = new GUIContent();

            // Button
            content.image = (Texture2D)Resources.Load("EAdventureData/img/icons/scenes", typeof(Texture2D));
            content.text  = TC.get("Element.Name1");
            ButtonContent = content;

            // Windows
            scenesWindowActiveAreas = new ScenesWindowActiveAreas(rect,
                                                                  new GUIContent(TC.get("ActiveAreasList.Title")), "Window");
            scenesWindowAppearance = new ScenesWindowAppearance(rect, new GUIContent(TC.get("Scene.LookPanelTitle")),
                                                                "Window");
            scenesWindowDocumentation = new ScenesWindowDocumentation(rect,
                                                                      new GUIContent(TC.get("Scene.DocPanelTitle")), "Window");
            scenesWindowElementReference = new ScenesWindowElementReference(rect,
                                                                            new GUIContent(TC.get("ItemReferencesList.Title")), "Window");
            scenesWindowExits = new ScenesWindowExits(rect, new GUIContent(TC.get("Element.Name3")), "Window");

            scenesWindowBarriers       = new ScenesWindowBarriers(rect, new GUIContent(TC.get("BarriersList.Title")), "Window");
            scenesWindowPlayerMovement = new ScenesWindowPlayerMovement(rect, new GUIContent(TC.get("Trajectory.Title")), "Window");


            selectedButtonSkin = (GUISkin)Resources.Load("Editor/ButtonSelected", typeof(GUISkin));

            GenerateToggleList();
        }
Пример #2
0
        public void ShowItemWindowView(int s)
        {
            GameRources.GetInstance().selectedSceneIndex = s;
            isConcreteItemVisible = true;
            // Generate new toogle list - maybe user already created new scenes?
            GenerateToggleList();

            // Reload windows for newly selected scene
            scenesWindowActiveAreas = new ScenesWindowActiveAreas(m_Rect, new GUIContent(TC.get("ActiveAreasList.Title")),
                                                                  "Window");
            scenesWindowAppearance = new ScenesWindowAppearance(m_Rect, new GUIContent(TC.get("Scene.LookPanelTitle")),
                                                                "Window");
            scenesWindowDocumentation = new ScenesWindowDocumentation(m_Rect,
                                                                      new GUIContent(TC.get("Scene.DocPanelTitle")), "Window");
            scenesWindowElementReference = new ScenesWindowElementReference(m_Rect,
                                                                            new GUIContent(TC.get("ItemReferencesList.Title")), "Window");
            scenesWindowExits = new ScenesWindowExits(m_Rect, new GUIContent(TC.get("Element.Name3")), "Window");

            // Only visible for 3rd person
            if (Controller.getInstance().playerMode() == DescriptorData.MODE_PLAYER_3RDPERSON)
            {
                scenesWindowBarriers       = new ScenesWindowBarriers(m_Rect, new GUIContent(TC.get("BarriersList.Title")), "Window");
                scenesWindowPlayerMovement = new ScenesWindowPlayerMovement(m_Rect, new GUIContent(TC.get("Trajectory.Title")), "Window");
            }
        }