public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Show a dialog to the sim in Stack Object (TSO) or the sole player (TS1). " + "This dialog can either block thread execution for a response, or simply show the dialog and ignore the response."))); switch (PrimID) { case 36: panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("The following strings are sourced from the private STR resource #301."))); break; case 38: panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("The following strings are sourced from the global STR resource #301."))); break; case 39: panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("The following strings are sourced from the semi-global STR resource #301."))); break; } panel.Controls.Add(new OpValueControl(master, escope, Operand, "Title:", "TitleStringID", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Message:", "MessageStringID", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Yes Button:", "YesStringID", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "No Button:", "NoStringID", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Cancel Button:", "CancelStringID", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Icon Name:", "IconNameStringID", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Type:", "Type", new OpStaticNamedPropertyProvider(typeof(VMDialogType)))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Non-blocking", "Continue"), new OpFlag("Use Temp XL", "UseTempXL"), new OpFlag("Use Temp 1", "UseTemp1") })); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Performs the specified expression. Returns the result, which is true only for assignments and true/false for conditionals."))); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "LHS: ", "LhsOwner", "LhsData")); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Operator: ", "Operator", new OpStaticNamedPropertyProvider(OperatorStr.Values.ToArray(), 0))); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "RHS: ", "RhsOwner", "RhsData")); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Refreshes the specified property of the object on demand."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Target Object:", "TargetObject", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(211)))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Property:", "RefreshType", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(212)))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Tracks 'relationship' variables of one object to another. Can be used between both objects and avatars, and can optionally persist relationships in the city server. Returns False on failure if 'Fail if too small' is checked."))); var old = (Operand is VMOldRelationshipOperand); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Get/Set/Adjust:", "SetMode", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(169)))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Mode:", "Mode", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>((ushort)(old ? 170 : 235))))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Relationship Var:", "RelVar", new OpStaticValueBoundsProvider(0, 255))); if (old) { panel.Controls.Add(new OpComboControl(master, escope, Operand, "Target Parameter:", "VarData", new OpStaticNamedPropertyProvider(escope.GetVarScopeDataNames(VMVariableScope.Parameters)))); } else { panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Target Variable:", "VarScope", "VarData")); } panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Fail if too small", "FailIfTooSmall"), new OpFlag("Use Neighbor", "UseNeighbor"), })); if (!old) { panel.Controls.Add(new OpComboControl(master, escope, Operand, "Object in Local:", "Local", new OpStaticNamedPropertyProvider(escope.GetVarScopeDataNames(VMVariableScope.Local)))); } }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Refreshes the specified property of the object on demand."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Target Object:", "TargetObject", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(211)))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Property:", "RefreshType", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(212)))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Allows the stack object to print a string. " + "In FreeSO, this message prints to chat, and can be used to make NPCs talk."))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "STR Table:", "StringTable", new OpStaticValueBoundsProvider(0, 65535))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "String ID:", "StringID", new OpStaticValueBoundsProvider(0, 65535))); }
public OpFlagsControl(BHAVEditor master, EditorScope scope, VMPrimitiveOperand operand, string title, OpFlag[] flags) { InitializeComponent(); this.FlagsPanel.Controls.Clear(); Master = master; Scope = scope; Operand = operand; Flags = flags; FlagChecks = new CheckBox[flags.Length]; int i = 0; foreach (var flag in flags) { var check = new CheckBox(); check.AutoSize = true; check.Margin = new System.Windows.Forms.Padding(3, 0, 3, 0); check.Size = new System.Drawing.Size(195, 17); check.Text = flag.Title; check.UseVisualStyleBackColor = true; check.CheckedChanged += Check_CheckedChanged; FlagChecks[i++] = check; CheckToFlag.Add(check, flag); this.FlagsPanel.Controls.Add(check); } OperandUpdated(); }
public OpLabelControl(BHAVEditor master, EditorScope scope, VMPrimitiveOperand operand, OpTextProvider textP) : this() { Scope = scope; Operand = operand; TextProvider = textP; OperandUpdated(); }
public BHAVEditor OpenEditor(BHAV bhav, GameObject srcobj) { if (bhav == null) { return(null); } BHAVEditor window; if (Editors.ContainsKey(bhav)) { window = Editors[bhav]; var form = (Form)window; if (form.WindowState == FormWindowState.Minimized) { form.WindowState = FormWindowState.Normal; } window.Activate(); return(window); } window = new BHAVEditor(bhav, new EditorComponent.EditorScope(srcobj, bhav)); window.Show(); window.Activate(); Editors.Add(bhav, window); return(window); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { var content = Content.Content.Get(); if (Sprites == null) { Sprites = new IffFile(content.TS1 ? Path.Combine(content.TS1BasePath, "GameData/Sprites.iff") : content.GetPath("objectdata/globals/sprites.iff")); } panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Shows a 'Headline' above the specified object; "))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Category", "Group", new OpStaticNamedPropertyProvider(typeof(VMSetBalloonHeadlineOperandGroup)))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Index", "Index", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Balloon", "Type", new OpStaticNamedPropertyProvider( Enumerable.Range(0, 32) .ToDictionary(x => x, x => Sprites.Get <SPR>((ushort)(GroupOffsets[(int)VMSetBalloonHeadlineOperandGroup.Balloon] + x))?.ChunkLabel) .Where(x => x.Value != null) .ToDictionary(x => x.Key, x => x.Value) ))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Duration", "Duration", new OpStaticValueBoundsProvider(0, 65535))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Algorithmic", "Algorithmic", new OpStaticValueBoundsProvider(0, 0x7FFF))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Of Stack Object", "OfStackOBJ"), new OpFlag("Crossed", "Crossed"), new OpFlag("Animate Backwards", "Backwards"), new OpFlag("Indexed by Temp[0]", "Indexed"), new OpFlag("Duration In Loops", "DurationInLoops"), })); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Changes the Caller's suit to the specified. Can change outfits and add accessories."))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Suit Data: ", "SuitData", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Suit Scope:", "SuitScope", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(227)))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Suit Op:", "Flags", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(228)))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Sleeps for the ticks specified by the chosen parameter, decrementing it towards zero. " + "Can be interrupted by the Notify Out Of Idle primitive."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Ticks in Parameter:", "StackVarToDec", new OpStaticNamedPropertyProvider(escope.GetVarScopeDataNames(VMVariableScope.Parameters)))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Run a TSO specific function. Can use state from this scope to perform an action."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Call:", "Call", new OpStaticNamedPropertyProvider( Content.GameContent.Get.TS1?typeof(VMGenericTS1CallMode):typeof(VMGenericTSOCallMode)))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Creates a new instance of the specified object."))); panel.Controls.Add(new OpObjectControl(master, escope, Operand, "Object Type: ", "GUID")); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Position:", "Position", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(167)))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Position Local: ", "LocalToUse", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Interaction Callback: ", "InteractionCallback", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Pass Object IDs", "PassObjectIds"), new OpFlag("Pass Temp 0 to Main", "PassTemp0"), new OpFlag("Persist in DB", "PersistInDB"), new OpFlag("Return Immediately", "ReturnImmediately"), new OpFlag("Fail if Non-Empty", "FailIfNonEmpty"), new OpFlag("Face StackOBJ Dir", "FaceStackObjDir"), new OpFlag("Use Neighbor (TS1)", "UseNeighbor"), })); panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider( "Pass Object IDs provides the option to pass both the Stack Object and the Caller Object to the newly " + "created object's main routine, as its Stack Object and Temp 0 (ID) respectively.\r\n\r\n" + "Return Immediately returns from this interaction and immediately runs it again with the created " + "object's ID in parameter 0."))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Runs a named tree in the stack object. The name is sourced from an STR resource (normally 303)."))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "STR Table:", "StringTable", new OpStaticValueBoundsProvider(0, 65535))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "String ID:", "StringID", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Destination:", "Destination", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(222), 0))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Scope:", "StringScope", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(159), 0))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Runs the specified entry point on the Stack Object, like a subroutine. Returns the result of the tree."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Function: ", "Function", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(201), 0))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Change Action Icon", "ChangeIcon"), })); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Specify the parameters passed to the subroutine. -1 passes the corresponding Temp as the parameter."))); var provider = new OpStaticValueBoundsProvider(-32767, 32768); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Argument 1:", "Arg0", provider)); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Argument 2:", "Arg1", provider)); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Argument 3:", "Arg2", provider)); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Argument 4:", "Arg3", provider)); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("If we're running as an interaction's TEST function, " + "adds this interaction with the specified string to the pie menu, with the current Stack Object ID in parameter 0 of the interaction. " + "The first run overwrites - the following runs add additional entries."))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "STR Table:", "StringTable", new OpStaticValueBoundsProvider(0, 65535))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "String ID:", "StringID", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Scope:", "Scope", new OpStaticNamedPropertyProvider(typeof(ScopeSource)))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Runs the specified entry point on the Stack Object, like a subroutine. Returns the result of the tree."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Function: ", "Function", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(201), 0))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Change Action Icon", "ChangeIcon"), })); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Drops an object from the specified slot on the Caller to a destination slot on the Stack Object."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Source Mode: ", "SrcSlotMode", new OpStaticNamedPropertyProvider(new string[] { "Slot[literal]", "Slot[parameter]" }, 0))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Source ID: ", "SrcSlotNum", new OpStaticValueBoundsProvider(0, 65535))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Destination Mode: ", "DestSlotMode", new OpStaticNamedPropertyProvider(new string[] { "Slot[literal]", "Slot[parameter]" }, 0))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Destination ID: ", "DestSlotNum", new OpStaticValueBoundsProvider(0, 65535))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Inventory operations in TSO. Many of these have been added in FreeSO."))); panel.Controls.Add(new OpObjectControl(master, escope, Operand, "Object Type:", "GUID")); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Mode:", "Mode", new OpStaticNamedPropertyProvider(typeof(VMInventoryOpMode)))); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Target Variable", "FSOScope", "FSOData")); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Removes the specified object instance."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Target Object:", "Target", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(156)))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Return Immediately", "ReturnImmediately"), new OpFlag("Cleanup Multitile", "CleanupAll"), })); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("This primitive is not implemented, but its hexadecimal values may be edited directly."))); var provider = new OpStaticValueBoundsProvider(-32768, 32767); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Argument 1:", "Arg0", provider, true)); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Argument 2:", "Arg1", provider, true)); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Argument 3:", "Arg2", provider, true)); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Argument 4:", "Arg3", provider, true)); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Removes the specified object instance."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Target Object:", "Target", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(156)))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Return Immediately", "ReturnImmediately"), new OpFlag("Cleanup Multitile", "CleanupAll"), })); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Sleeps for the ticks specified by the chosen parameter, decrementing it towards zero. " + "Can be interrupted by the user cancelling the interaction, and the Notify Out Of Idle primitive."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Ticks in Parameter:", "StackVarToDec", new OpStaticNamedPropertyProvider(escope.GetVarScopeDataNames(VMVariableScope.Parameters)))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Allow Push", "AllowPush") })); panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Allow Push is not well understood, and currently does nothing."))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Routes the Avatar to the specified Routing Slot, returning True on success and False on failure. Normally upon failure, the Avatar also performs a small explanatory animation, though this can be disabled."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Source: ", "Type", new OpStaticNamedPropertyProvider(new string[] { "Private[parameter]", "Private", "Global" }, 0))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Slot: ", "Data", new OpRoutingSlotNameProvider())); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("No Failure Trees", "NoFailureTrees"), })); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Cycles the object with ID in the Target location to the next object of a specified type. Returns false when none or no more are available."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Search Type: ", "SearchType", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(164), 0))); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Target Scope: ", "TargetOwner", "TargetData")); panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Properties for specific search types:"))); panel.Controls.Add(new OpObjectControl(master, escope, Operand, "Object Type: ", "GUID")); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Local: ", "Local", new OpStaticValueBoundsProvider(-32768, 32767))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Cycles the object with ID in the Target location to the next object of a specified type. Returns false when none or no more are available."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Search Type: ", "SearchType", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(164), 0))); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Target Scope: ", "TargetOwner", "TargetData")); panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Properties for specific search types:"))); panel.Controls.Add(new OpObjectControl(master, escope, Operand, "Object Type: ", "GUID")); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Local: ", "Local", new OpStaticValueBoundsProvider(-32768, 32767))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Invokes a TSO UI 'plugin'. Sends an event in the Event Local to the plugin (eg, -2 = connect), and it will either return true for complete, or false for an event from the server. (with data in temp 0)"))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Avatar Local", "PersonLocal", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Object Local", "ObjectLocal", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Event Local", "EventLocal", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Plugin ID", "PluginID", new OpStaticValueBoundsProvider(int.MinValue, int.MaxValue))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Joinable", "Joinable"), })); }
public OpSoundControl(BHAVEditor master, EditorScope scope, VMPrimitiveOperand operand, string title) { InitializeComponent(); this.Dock = DockStyle.Fill; Master = master; Scope = scope; Operand = (VMPlaySoundOperand)operand; TitleLabel.Text = title; OperandUpdated(); }
public OpAnimControl(BHAVEditor master, EditorScope scope, VMPrimitiveOperand operand, string title) { InitializeComponent(); this.Dock = DockStyle.Fill; Master = master; Scope = scope; Operand = (VMAnimateSimOperand)operand; TitleLabel.Text = title; OperandUpdated(); }
public OpComboControl(BHAVEditor master, EditorScope scope, VMPrimitiveOperand operand, string title, string property, OpNamedPropertyProvider valueProvider) { InitializeComponent(); this.Dock = DockStyle.Fill; Master = master; Scope = scope; Operand = operand; TitleLabel.Text = title; Property = property; ValueProvider = valueProvider; OperandUpdated(); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Routes the Caller avatar to a position relative to the stack object. Returns true on success, false on failure."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Location:", "Location", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(130), -2))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Direction:", "Direction", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(131), -2))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Allow Different Alts", "AllowDiffAlt"), new OpFlag("No Failure Trees", "NoFailureTrees") })); panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Normally on failure routing primitives run a small routine which helps give the player more context on why the route failed. 'No Failure Trees' makes failed routes return false immediately."))); }
public OpObjectControl(BHAVEditor master, EditorScope scope, VMPrimitiveOperand operand, string title, string guidProperty) { InitializeComponent(); this.Dock = DockStyle.Fill; Master = master; Scope = scope; Operand = operand; TitleLabel.Text = title; GUIDProperty = guidProperty; OperandUpdated(); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Animates the caller sim. Returns False when an animation event occurs, and True when the animation is compete."))); panel.Controls.Add(new OpAnimControl(master, escope, Operand, "Animation:")); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Animation Source:", "Source", new OpStaticNamedPropertyProvider( new string[] { "This Tree's Object", "Global", "Person", "Misc" }, 0))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Play Backwards", "PlayBackwards"), new OpFlag("Place Events in Local", "StoreFrameInLocal") })); }
public OpValueControl(BHAVEditor master, EditorScope scope, VMPrimitiveOperand operand, string title, string property, OpValueBoundsProvider bounds) { InitializeComponent(); Master = master; Scope = scope; Operand = operand; TitleLabel.Text = title; Property = property; BoundsProvider = bounds; this.Dock = DockStyle.Fill; OperandUpdated(); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Routes the Caller avatar to a position relative to the stack object. Returns true on success, false on failure."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Location:", "Location", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(130), -2))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Direction:", "Direction", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get <STR>(131), -2))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Allow Different Alts", "AllowDiffAlt"), new OpFlag("No Failure Trees", "NoFailureTrees") })); panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Normally on failure routing primitives run a small routine which helps give the player more context on why the route failed. 'No Failure Trees' makes failed routes return false immediately."))); }
public OpScopeControl(BHAVEditor master, EditorScope scope, VMPrimitiveOperand operand, string title, string sourceProperty, string dataProperty) { InitializeComponent(); this.Dock = DockStyle.Fill; Master = master; Scope = scope; Operand = operand; TitleLabel.Text = title; SourceProperty = sourceProperty; DataProperty = dataProperty; OperandUpdated(); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Finds a location to place the Stack Object, using a variety of modes and options."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Mode:", "Mode", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(239)))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Use Local As Ref", "UseLocalAsRef"), new OpFlag("Allow Intersection", "AllowIntersection"), new OpFlag("User Editable Tiles Only", "UserEditableTilesOnly"), })); panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("If 'Use Local As Ref' is set, the object with ID specified in the local is used as the starting position instead of the caller."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Local:", "Local", new OpStaticNamedPropertyProvider(escope.GetVarScopeDataNames(VMVariableScope.Local)))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Sets a motive to change at a specific delta per hour until it hits the specified value. You can clear all active changes by setting the Clear All flag."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Motive:", "Motive", new OpStaticNamedPropertyProvider(escope.GetVarScopeDataNames(VMVariableScope.MyMotives)))); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Delta:", "DeltaOwner", "DeltaData")); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Max:", "MaxOwner", "MaxData")); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Apply Change Once", "Once"), new OpFlag("Clear All", "ClearAll"), })); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Attempts to play the specified sound event."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Sound: ", "EventID", new OpSoundNameProvider())); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Volume (unused): ", "Volume", new OpStaticValueBoundsProvider(0, 100))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Loop", "Loop"), new OpFlag("No 3D Positioning", "NoPan"), new OpFlag("No Zoom quieting", "NoZoom"), new OpFlag("Use Stack Object as Source", "StackObjAsSource"), })); }
public BHAVEditor OpenEditor(BHAV bhav, GameObject srcobj) { BHAVEditor window; if (Editors.ContainsKey(bhav)) { window = Editors[bhav]; var form = (Form)window; if (form.WindowState == FormWindowState.Minimized) form.WindowState = FormWindowState.Normal; window.Activate(); return window; } window = new BHAVEditor(bhav, new EditorComponent.EditorScope(srcobj, bhav)); window.Show(); window.Activate(); Editors.Add(bhav, window); return window; }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Creates a new instance of the specified object."))); panel.Controls.Add(new OpObjectControl(master, escope, Operand, "Object Type: ", "GUID")); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Position:", "Position", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(167)))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Position Local: ", "LocalToUse", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Interaction Callback: ", "InteractionCallback", new OpStaticValueBoundsProvider(0, 255))); panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Pass Object IDs", "PassObjectIds"), new OpFlag("Pass Temp 0 to Main", "PassTemp0"), })); panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider( "Pass Object IDs provides the option to pass both the Stack Object and the Caller Object to the newly "+ "created object's main routine, as its Stack Object and Temp 0 (ID) respectively."))); }
public BHAVEditor OpenTracer(VM vm, VMEntity entity) { BHAVEditor window; if (Tracers.ContainsKey(entity)) { window = Tracers[entity]; window.UpdateDebugger(); var form = (Form)window; if (form.WindowState == FormWindowState.Minimized) form.WindowState = FormWindowState.Normal; window.Activate(); return window; } window = new BHAVEditor(vm, entity); window.Show(); window.Activate(); Tracers.Add(entity, window); return window; }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Performs the specified expression. Returns the result, which is true only for assignments and true/false for conditionals."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Left Hand Side Scope: ", "LhsOwner", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(132), 0))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Left Hand Side Data: ", "LhsData", new OpStaticValueBoundsProvider(-32768, 32767))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Operator: ", "Operator", new OpStaticNamedPropertyProvider(OperatorStr.Values.ToArray(), 0))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Right Hand Side Scope: ", "RhsOwner", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(132), 0))); panel.Controls.Add(new OpValueControl(master, escope, Operand, "Right Hand Side Data: ", "RhsData", new OpStaticValueBoundsProvider(-32768, 32767))); /*panel.Controls.Add(new OpFlagsControl(master, escope, Operand, "Flags:", new OpFlag[] { new OpFlag("Signed", "IsSigned"), }));*/ }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Places a random number between 0 and the specified range into the specified variable scope."))); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Range:", "RangeScope", "RangeData")); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Destination:", "DestinationScope", "DestinationData")); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Places the Stack Object in the Caller object's 0th slot. " + "Usually used by Avatars. Returns False on failure, True on success."))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Notifies the Stack Object out of both Sleep and Idle for Input primitives. Usually used to notify an object's main thread that an external change has occurred."))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Turns either the Avatar's body or head towards/away from either the Stack Object or the camera."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Mode:", "Mode", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(216)))); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Breakpoints when the specified Variable Scope contains a non-zero value."))); panel.Controls.Add(new OpScopeControl(master, escope, Operand, "Variable:", "Scope", "Data")); }
public virtual void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpUnknownControl()); }
public override void PopulateOperandView(BHAVEditor master, EditorScope escope, TableLayoutPanel panel) { panel.Controls.Add(new OpLabelControl(master, escope, Operand, new OpStaticTextProvider("Finds the 'best' object for a specified entry point, ranked by a combination of distance and the relevant score in its Object Data."))); panel.Controls.Add(new OpComboControl(master, escope, Operand, "Function: ", "Function", new OpStaticNamedPropertyProvider(EditorScope.Behaviour.Get<STR>(201), 0))); }