Difference between revisions of "Category:Conditions"

From the Fallout3 GECK Wiki
Jump to navigation Jump to search
imported>Hugepinball
(Added to "AND/OR Precedence" section)
imported>Tunaisafish
m (→‎AND/OR Precedence: typo, well spotted RandomNoob)
 
Line 46: Line 46:
The OR checkbox is used to determine how a Condition Item is evaluated with the ones that follow it. Consecutive ORs are treated like a single block when evaluating and have order precedence over AND. For example, the Condition Items (A AND B OR C AND D) are evaluated as (A AND (B OR C) AND D) and not ((A AND B) OR (C AND D)).
The OR checkbox is used to determine how a Condition Item is evaluated with the ones that follow it. Consecutive ORs are treated like a single block when evaluating and have order precedence over AND. For example, the Condition Items (A AND B OR C AND D) are evaluated as (A AND (B OR C) AND D) and not ((A AND B) OR (C AND D)).


By applying the [http://en.wikipedia.org/wiki/Logical_disjunction#Properties distributive and other properties] complex expressions can be converted into a list of Condition Items that will evaluate as intended.  For example, the expression ((A AND B) OR (C AND D)) can be represented as the list of Condition Items (A OR B AND B OR C AND A OR D AND B OR D).  As described above, this evaluates as ((A OR B) AND (B OR C) AND (A OR D) AND (B OR D)) which is equivalent to the initial expression.
By applying the [http://en.wikipedia.org/wiki/Logical_disjunction#Properties distributive and other properties] complex expressions can be converted into a list of Condition Items that will evaluate as intended.  For example, the expression ((A AND B) OR (C AND D)) can be represented as the list of Condition Items (A OR C AND B OR C AND A OR D AND B OR D).  As described above, this evaluates as ((A OR C) AND (B OR C) AND (A OR D) AND (B OR D)) which is equivalent to the initial expression.




[[Category:Quests]]
[[Category:Quests]]
[[Category:Scripting]]
[[Category:Scripting]]

Latest revision as of 15:26, 29 March 2012

Overview[edit | edit source]

Conditions are used in a number of places in the editor to tell the game when certain things should happen. Conditions are simply a list of one or more script functions that specify the circumstances under which a given editor item is valid. Conditions are used in the following editor sections:

The Condition List[edit | edit source]

The condition list displays all of the individual Condition Items for this set of Conditions. Right-clicking in the list displays a popup menu which you can use to create New condition items, Duplicate or Delete existing condition items, Copy one or All items in the list, or Paste in items copied from elsewhere.


The << and >> buttons are used to move Condition Items up or down in the list, respectively, and the New button can be used to create a new item.


To edit a Condition Item, select it in the list and all of the data for that item will displayed in the controls beneath the list where the data can be altered.


The Condition Function dropdown list is the function to run. See Condition Functions for the complete list of script functions that can be used as conditions.

Run On[edit | edit source]

The Run on field is used to indicate that the function should be run on the indicated actor.

  • Subject: The actor owning the object. In the case of dialogue, it's whoever is saying it. In the case of quest targets, it's the player.
  • Target: For dialogue, this is the actor being spoken to. For Packages, it's the actor/object specified as the target.
  • Reference: A specific reference in the world. Use the Select button to find the reference.
  • Combat Reference: If the owning actor is in combat, it is his current combat target.
  • Linked Reference: If the reference is linked to another reference, it will used the linked object.

Function Parameters[edit | edit source]

The Function Parameters button opens up another dialog box in which parameters for the currently selected function can be set. This is where the Reference for a GetDistance function or the Faction for a GetFactionRank function is set.

Comparison[edit | edit source]

The Comparison dropdown list determines how the return value for the function is compared with the Comparison Value to determine if the condition item is true.


The Comparison Value is normally a text field where a value is entered by hand. However, if the Use Global checkbox is checked, the Value is instead a dropdown list in which a global variable can be selected to use as the Comparison Value instead.

AND/OR Precedence[edit | edit source]

The OR checkbox is used to determine how a Condition Item is evaluated with the ones that follow it. Consecutive ORs are treated like a single block when evaluating and have order precedence over AND. For example, the Condition Items (A AND B OR C AND D) are evaluated as (A AND (B OR C) AND D) and not ((A AND B) OR (C AND D)).

By applying the distributive and other properties complex expressions can be converted into a list of Condition Items that will evaluate as intended. For example, the expression ((A AND B) OR (C AND D)) can be represented as the list of Condition Items (A OR C AND B OR C AND A OR D AND B OR D). As described above, this evaluates as ((A OR C) AND (B OR C) AND (A OR D) AND (B OR D)) which is equivalent to the initial expression.

Subcategories

This category has the following 2 subcategories, out of 2 total.

D

P

Pages in category "Conditions"

The following 4 pages are in this category, out of 4 total.