示例#1
0
            public void DoUI(IObjectUIControl control)
            {
#if ODYSSEY
                control.PlainText(Convert.ToString(area.ScenarioBitField, 2));
#endif
                if (Spotlight.Properties.Settings.Default.AllowIDEdits)
                {
                    area.ID = control.TextInput(area.ID, "Object ID");
                }
                else
                {
                    control.TextInput(area.ID, "Object ID");
                }

                if (area.comment != null)
                {
                    control.TextInput(area.comment, "Comment");
                }

                area.Layer = control.TextInput(area.Layer, "Layer");

                area.ClassName = control.DropDownTextInput("Class Name", area.ClassName, DB_classNames);
                area.ModelName = control.DropDownTextInput("Shape Name", area.ModelName, shapeNames, false);

                area.Priority = (int)control.NumberInput(area.Priority, "Priority");

                control.VerticalSeperator();

                if (WinInput.Keyboard.IsKeyDown(WinInput.Key.LeftShift))
                {
                    area.Position = control.Vector3Input(area.Position, "Position", 1, 16);
                }
                else
                {
                    area.Position = control.Vector3Input(area.Position, "Position", 0.125f, 2);
                }

                if (WinInput.Keyboard.IsKeyDown(WinInput.Key.LeftShift))
                {
                    area.Rotation = control.Vector3Input(area.Rotation, "Rotation", 45, 18);
                }
                else
                {
                    area.Rotation = control.Vector3Input(area.Rotation, "Rotation", 5, 2);
                }

                if (WinInput.Keyboard.IsKeyDown(WinInput.Key.LeftShift))
                {
                    area.Scale = control.Vector3Input(area.Scale, "Scale", 1, 16);
                }
                else
                {
                    area.Scale = control.Vector3Input(area.Scale, "Scale", 0.125f, 2);
                }
            }
            public void DoUI(IObjectUIControl control)
            {
                control.PlainText(scene.SelectedConnection.Source + " to " + scene.SelectedConnection.Dest);

                connectionName = control.DropDownTextInput("Connection Name", connectionName, scene.SelectedConnection.PossibleNames);
                if (control.Button("Reverse Connection"))
                {
                    scene.ChangeSelectedConnection(
                        scene.SelectedConnection.Dest,
                        scene.SelectedConnection.Source,
                        scene.SelectedConnection.Name);

                    scene.GL_Control.Refresh();
                }
            }
示例#3
0
            public void DoUI(IObjectUIControl control)
            {
                text     = control.TextInput(text, "TextInput");
                longText = control.FullWidthTextInput(longText, "Long Text Input");
                number   = control.NumberInput(number, "Number Input");
                control.Link("Just some Link");

                control.DoubleButton("Add", "Remove");
                control.TripleButton("Add", "Remove", "Insert");
                control.QuadripleButton("+", "-", "*", "/");
                enemyType  = (EnemyType)control.ChoicePicker("Enemy1 Type", enemyType, Enum.GetValues(typeof(EnemyType)));
                enemyType2 = (EnemyType)control.ChoicePicker("Enemy2 Type", enemyType2, Enum.GetValues(typeof(EnemyType)));
                control.VerticalSeperator();
                objectType = control.AdvancedTextInput("Object Type", objectType, objectTypes);

                control.Spacing(30);
                control.PlainText("Some Text");
            }
示例#4
0
 public void DoUI(IObjectUIControl control)
 {
     text = control.TextInput(text, "TextInput");
     control.PlainText("I hate people");
 }
 public void DoUI(IObjectUIControl control)
 {
     control.PlainText(objs.Count.ToString());
 }
            public void DoUI(IObjectUIControl control)
            {
#if ODYSSEY
                control.PlainText(Convert.ToString(obj.ScenarioBitField, 2));
#endif
                if (Spotlight.Properties.Settings.Default.AllowIDEdits)
                {
                    obj.ID = control.TextInput(obj.ID, "Object ID");
                }
                else
                {
                    control.TextInput(obj.ID, "Object ID");
                }

                if (obj.comment != null)
                {
                    control.TextInput(obj.comment, "Comment");
                }

                obj.Layer      = control.TextInput(obj.Layer, "Layer");
                obj.ObjectName = control.DropDownTextInput("Object Name", obj.ObjectName, DB_objectNames);

                if (showClassNameInfo)
                {
                    control.SetTooltip(classNameInfo);
                }
                obj.ClassName = control.DropDownTextInput("Class Name", obj.ClassName, DB_classNames);
                if (showClassNameAlias)
                {
                    control.PlainText(classNameAlias);
                }
                control.SetTooltip(null);

                obj.ModelName = control.DropDownTextInput("Model Name", obj.ModelName, DB_modelNames);

                control.VerticalSeperator();

                if (WinInput.Keyboard.IsKeyDown(WinInput.Key.LeftShift))
                {
                    obj.Position = control.Vector3Input(obj.Position, "Position", 1, 16);
                }
                else
                {
                    obj.Position = control.Vector3Input(obj.Position, "Position", 0.125f, 2);
                }

                if (WinInput.Keyboard.IsKeyDown(WinInput.Key.LeftShift))
                {
                    obj.Rotation = control.Vector3Input(obj.Rotation, "Rotation", 45, 18);
                }
                else
                {
                    obj.Rotation = control.Vector3Input(obj.Rotation, "Rotation", 5, 2);
                }

                if (WinInput.Keyboard.IsKeyDown(WinInput.Key.LeftShift))
                {
                    obj.Scale = control.Vector3Input(obj.Scale, "Scale", 1, 16);
                }
                else
                {
                    obj.Scale = control.Vector3Input(obj.Scale, "Scale", 0.125f, 2);
                }

                control.VerticalSeperator();

                if (WinInput.Keyboard.IsKeyDown(WinInput.Key.LeftShift))
                {
                    obj.DisplayTranslation = control.Vector3Input(obj.DisplayTranslation, "Display Position", 1, 16);
                }
                else
                {
                    obj.DisplayTranslation = control.Vector3Input(obj.DisplayTranslation, "Display Position", 0.125f, 2);
                }

                //TODO
            }