diff --git a/Docs/command_ref/gameobject_commands.md b/Docs/command_ref/gameobject_commands.md new file mode 100644 index 00000000..2d6190f0 --- /dev/null +++ b/Docs/command_ref/gameobject_commands.md @@ -0,0 +1,17 @@ +# GameObject commands # {#gameobject_commands} + +[TOC] +# Instantiate # {#Instantiate} +Instantiate a game object + +Defined in Fungus.SpawnObject + +Property | Type | Description + --- | --- | --- +_source Object | Fungus.GameObjectData | Game object to copy when spawning. Can be a scene object or a prefab. +_parent Transform | Fungus.TransformData | Transform to use as parent during instantiate. +_spawn At Self | Fungus.BooleanData | If true, will use the Transfrom of this Flowchart for the position and rotation. +_spawn Position | Fungus.Vector3Data | Local position of newly spawned object. +_spawn Rotation | Fungus.Vector3Data | Local rotation of newly spawned object. +_newly Spawned Object | Fungus.GameObjectData | Optional variable to store the GameObject that was just created. + diff --git a/Docs/command_ref/input_commands.md b/Docs/command_ref/input_commands.md index c226bbc4..e64e3b4f 100644 --- a/Docs/command_ref/input_commands.md +++ b/Docs/command_ref/input_commands.md @@ -1,15 +1,13 @@ -# Input Commands # {#input_commands} - -Commands that interact with UnityEngine.Input +# Input commands # {#input_commands} [TOC] -# Move # {#Move} -Moves a game object to a specified position over time. Can be either to or from a given target. Can be absolute or additive. +# GetAxis # {#GetAxis} +Store Input.GetAxis in a variable -Defined in Fungus.MoveLean +Defined in Fungus.GetAxis Property | Type | Description --- | --- | --- -axisName | Fungus.StringData | Input Axis name, defined in [InputManager](https://docs.unity3d.com/Manual/class-InputManager.html) -axisRaw | System.Boolean | If true, calls GetAxisRaw instead of GetAxis -outValue | Fungus.FloatData | Float to store the value of the GetAxis. \ No newline at end of file +Axis Raw | System.Boolean | If true, calls GetAxisRaw instead of GetAxis +Out Value | Fungus.FloatData | Float to store the value of the GetAxis + diff --git a/Docs/command_ref/leanTween_commands.md b/Docs/command_ref/leanTween_commands.md index 986a7ba5..581cab9c 100644 --- a/Docs/command_ref/leanTween_commands.md +++ b/Docs/command_ref/leanTween_commands.md @@ -1,74 +1,72 @@ -# LeanTween commands # {#leanTween_commands} - -Fungus Commands that apply [LeanTweens](http://dentedpixel.com/LeanTweenDocumentation/classes/LeanTween.html) to a GameObject. +# LeanTween commands # {#leantween_commands} [TOC] # Move # {#Move} -Moves a game object to a specified position over time. Can be either to or from a given target. Can be absolute or additive. +Moves a game object to a specified position over time. The position can be defined by a transform in another object (using To Transform) or by setting an absolute position (using To Position, if To Transform is set to None). Defined in Fungus.MoveLean Property | Type | Description --- | --- | --- -_targetObject | Fungus.GameObjectData | GameObject to tween -_duration | Fungus.FloatData | Time in seconds for the tween to complete -_toFrom | System.Enum | 'To' or 'From'. To means it tweens from its current to the target. From, will jump to the final and tween back towards the current. -_absAdd | System.Enum | 'Absolute' or 'Additive'. Absolute treats the destination as a final. Additive calculates the final as the current plus the value within the destination. -easeType | LeanTweenType | Forumla used to animate from start to end value. E.g. easeInOutQuad -loopType | LeanTweenType | If the tween is to loop (play it's duration more than once) how should it do that, clamp or pingping etc. -repeats | System.Int32 | Number of times to repeat the tween, -1 is infinite. -stopPreviousTweens | System.Boolean | If true stop any previously LeanTweens on this object before adding this one. Warning; expensive. -waitUntilFinished | System.Boolean | If true, this command will halt the block until the tween is finished. -_toTransform | Fungus.TransformData | Target transform that the GameObject will move to. Often easier to configure tweens with the use of a target gameobject than a hard coded world position. (if this is not set then the _toPosition vector3 will be used) -_toPosition | Fungus.Vector3Data | Target world position that the GameObject will move to, if no From Transform is set. This is only used if the _toTransform is null -isLocal | System.Boolean | Whether to animate in world space or relative to the parent. False by default. - +_to Transform | Fungus.TransformData | Target transform that the GameObject will move to +_to Position | Fungus.Vector3Data | Target world position that the GameObject will move to, if no From Transform is set +Is Local | System.Boolean | Whether to animate in world space or relative to the parent. False by default. +_target Object | Fungus.GameObjectData | Target game object to apply the Tween to +_duration | Fungus.FloatData | The time in seconds the animation will take to complete +_to From | Fungus.BaseLeanTweenCommand+ToFrom | Does the tween act from current TO destination or is it reversed and act FROM destination to its current +_abs Add | Fungus.BaseLeanTweenCommand+AbsAdd | Does the tween use the value as a target or as a delta to be added to current. +Ease Type | LeanTweenType | The shape of the easing curve applied to the animation +Loop Type | LeanTweenType | The type of loop to apply once the animation has completed +Repeats | System.Int32 | Number of times to repeat the tween, -1 is infinite. +Stop Previous Tweens | System.Boolean | Stop any previously LeanTweens on this object before adding this one. Warning; expensive. +Wait Until Finished | System.Boolean | Wait until the tween has finished before executing the next command -# Scale # {#Scale} -Scales a game object to a specified scale over time. Can be either to or from a given target. Can be absolute or additive. +# Rotate # {#Rotate} +Rotates a game object to the specified angles over time. -Defined in Fungus.ScaleLean +Defined in Fungus.RotateLean Property | Type | Description --- | --- | --- -_targetObject | Fungus.GameObjectData | GameObject to tween -_duration | Fungus.FloatData | Time in seconds for the tween to complete -_toFrom | System.Enum | 'To' or 'From'. To means it tweens from its current to the target. From, will jump to the final and tween back towards the current. -_absAdd | System.Enum | 'Absolute' or 'Additive'. Absolute treats the destination as a final. Additive calculates the final as the current plus the value within the destination. -easeType | LeanTweenType | Forumla used to animate from start to end value. E.g. easeInOutQuad -loopType | LeanTweenType | If the tween is to loop (play it's duration more than once) how should it do that, clamp or pingping etc. -repeats | System.Int32 | Number of times to repeat the tween, -1 is infinite. -stopPreviousTweens | System.Boolean | If true stop any previously LeanTweens on this object before adding this one. Warning; expensive. -waitUntilFinished | System.Boolean | If true, this command will halt the block until the tween is finished. -_toTransform | Fungus.TransformData | Target scale for the tween to use. If null then the _toScale vector3 is used instead. -_toScale | Fungus.Vector3Data | Target scale that the GameObject will scale to. Only used if _toTransform is null. Default is 1,1,1 +_to Transform | Fungus.TransformData | Target transform that the GameObject will rotate to +_to Rotation | Fungus.Vector3Data | Target rotation that the GameObject will rotate to, if no To Transform is set +Is Local | System.Boolean | Whether to animate in world space or relative to the parent. False by default. +Rotate Mode | Fungus.RotateLean+RotateMode | Whether to use the provided Transform or Vector as a target to look at rather than a euler to match. +_target Object | Fungus.GameObjectData | Target game object to apply the Tween to +_duration | Fungus.FloatData | The time in seconds the animation will take to complete +_to From | Fungus.BaseLeanTweenCommand+ToFrom | Does the tween act from current TO destination or is it reversed and act FROM destination to its current +_abs Add | Fungus.BaseLeanTweenCommand+AbsAdd | Does the tween use the value as a target or as a delta to be added to current. +Ease Type | LeanTweenType | The shape of the easing curve applied to the animation +Loop Type | LeanTweenType | The type of loop to apply once the animation has completed +Repeats | System.Int32 | Number of times to repeat the tween, -1 is infinite. +Stop Previous Tweens | System.Boolean | Stop any previously LeanTweens on this object before adding this one. Warning; expensive. +Wait Until Finished | System.Boolean | Wait until the tween has finished before executing the next command -# Rotate # {#Rotate} -Rotate a game object to a specified rotation (matching another transform or eulerAngle) over time. Can be either to or from a given target. Can be absolute or additive. +# Scale # {#Scale} +Changes a game object's scale to a specified value over time. -Defined in Fungus.RotateLean +Defined in Fungus.ScaleLean Property | Type | Description --- | --- | --- -_targetObject | Fungus.GameObjectData | GameObject to tween -_duration | Fungus.FloatData | Time in seconds for the tween to complete -_toFrom | System.Enum | 'To' or 'From'. To means it tweens from its current to the target. From, will jump to the final and tween back towards the current. -_absAdd | System.Enum | 'Absolute' or 'Additive'. Absolute treats the destination as a final. Additive calculates the final as the current plus the value within the destination. -easeType | LeanTweenType | Forumla used to animate from start to end value. E.g. easeInOutQuad -loopType | LeanTweenType | If the tween is to loop (play it's duration more than once) how should it do that, clamp or pingping etc. -repeats | System.Int32 | Number of times to repeat the tween, -1 is infinite. -stopPreviousTweens | System.Boolean | If true stop any previously LeanTweens on this object before adding this one. Warning; expensive. -waitUntilFinished | System.Boolean | If true, this command will halt the block until the tween is finished. -_toTransform | Fungus.TransformData | Rotation for the tween to match. If not set _toRotation will be used. -_ToRotation | Fungus.FloatData | Target rotation that the GameObject will rotate to, if no To Transform is set -isLocal | System.Boolean | Whether to animate in world space or relative to the parent. False by default. -rotateMode | System.Enum | 'PureRotate', 'LookAt2D' or 'LookAt3D'. Determines how to use the supplied rotation information. PureRotate is a simply euler/quaternion match. LookAt2D matches the euler z only. LookAt3D rotations the objects forward to point at the given direction/target. +_to Transform | Fungus.TransformData | Target transform that the GameObject will scale to +_to Scale | Fungus.Vector3Data | Target scale that the GameObject will scale to, if no To Transform is set +_target Object | Fungus.GameObjectData | Target game object to apply the Tween to +_duration | Fungus.FloatData | The time in seconds the animation will take to complete +_to From | Fungus.BaseLeanTweenCommand+ToFrom | Does the tween act from current TO destination or is it reversed and act FROM destination to its current +_abs Add | Fungus.BaseLeanTweenCommand+AbsAdd | Does the tween use the value as a target or as a delta to be added to current. +Ease Type | LeanTweenType | The shape of the easing curve applied to the animation +Loop Type | LeanTweenType | The type of loop to apply once the animation has completed +Repeats | System.Int32 | Number of times to repeat the tween, -1 is infinite. +Stop Previous Tweens | System.Boolean | Stop any previously LeanTweens on this object before adding this one. Warning; expensive. +Wait Until Finished | System.Boolean | Wait until the tween has finished before executing the next command -# Stop Tweens # {#StopTweens} -Stops the all active LeanTweens, made by fungus or otherwise, on the target GameObject +# StopTweens # {#StopTweens} +Stops the LeanTweens on a target GameObject Defined in Fungus.StopTweensLean Property | Type | Description --- | --- | --- _target Object | Fungus.GameObjectData | Target game object stop LeanTweens on + diff --git a/Docs/command_ref/math_commands.md b/Docs/command_ref/math_commands.md index 163c5004..626a59ed 100644 --- a/Docs/command_ref/math_commands.md +++ b/Docs/command_ref/math_commands.md @@ -1,201 +1,161 @@ # Math commands # {#math_commands} -Provides a way for Fungus.FloatData to be used in conjunction with most of [Mathf](https://docs.unity3d.com/ScriptReference/Mathf.html) and more. - [TOC] # Abs # {#Abs} -Sets the outValue to the be Absolute value of the inValue. +Command to execute and store the result of a Abs Defined in Fungus.Abs Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # Clamp # {#Clamp} -Sets the outValue to the result of a clamp of value, between lower and upper. +Command to contain a value between a lower and upper bound, with optional wrapping modes Defined in Fungus.Clamp Property | Type | Description --- | --- | --- -mode | System.Enum | Clamp or Repeat or Pingpong. See [Repeat and Pingpong](https://docs.unity3d.com/ScriptReference/Mathf.html) for more details. -lower | Fungus.FloatData | The lower bound of the clamp -upper | Fungus.FloatData | The upper bound of the clamp -value | Fungus.FloatData | The value to be clamped -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). +Out Value | Fungus.FloatData | Result put here, if using pingpong don't use the same var for value as outValue. # Curve # {#Curve} -Sets the outValue to the evaluation at inValue of the supplied animation curve. Useful for non linearly remapping values. +Pass a value through an AnimationCurve Defined in Fungus.Curve Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. -curve | Unity.AnimationCurve | See [AnimationCurve](https://docs.unity3d.com/ScriptReference/AnimationCurve.html) for more info. Defaults to a Linear 0,0, to 1,1 AnimationCurve. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # Exp # {#Exp} -Sets the outValue to the be Exp (e^) value of the inValue. +Command to execute and store the result of a Exp Defined in Fungus.Exp Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. -# Inv # {#Inv} -Sets the outValue to the be mutliplicative inverse of the inValue, 1 / inValue. +# Inverse # {#Inverse} +Multiplicative Inverse of a float (1/f) Defined in Fungus.Inv Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # InvLerp # {#InvLerp} -Sets the outValue to the Calculates the inverse lerp, the percentage a value is between two others. +Calculates the inverse lerp, the percentage a value is between two others. Defined in Fungus.InvLerp Property | Type | Description --- | --- | --- -clampResult | System.Boolean | Clamp percentage to 0-1? -a | Fungus.FloatData | Min of the range -b | Fungus.FloatData | Max of the range -value | Fungus.FloatData | Value to determine precentage between a and b. -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). +Clamp Result | System.Boolean | Clamp percentage to 0-1? # Lerp # {#Lerp} -Sets the outValue to the linear interpolation of a percentage between two other values. +Linearly Interpolate from A to B Defined in Fungus.Lerp - -Property | Type | Description - --- | --- | --- -mode | System.Enum | Lerp or LerpUnclamped or LerpAngle. See [Lerp functions in Mathf](https://docs.unity3d.com/ScriptReference/Mathf.html) for more details. -a | Fungus.FloatData | Min of the range, default 0. -b | Fungus.FloatData | Max of the range, default 1. -percentage | Fungus.FloatData | percentage between a and b. -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). - # Log # {#Log} -Sets the outValue to the be Log or Ln of the inValue. +Command to execute and store the result of a Log Defined in Fungus.Log Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. -mode | System.Enum | Base10 or Natural. Base10 is the standard Log, Natural log is often seen as Ln. +Mode | Fungus.Log+Mode | Which log to use, natural or base 10 +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # Map # {#Map} -Sets the outValue mapping of a value that currently exists between a set of numbers to another set of numbers. -E.g. a value of 5 between 0 and 10, mapped to 0-20 would result in 10. - -Does not clamp between ranges, use a Fungus.Clamp before or after this command for that if is desired. +Map a value that exists in 1 range of numbers to another. Defined in Fungus.Map - -Property | Type | Description - --- | --- | --- -initialRangeLower | Fungus.FloatData | Min of the initial range, default 0. -initialRangeupper | Fungus.FloatData | Max of the initial range, default 1. -value | Fungus.FloatData | Value to be mapped from initial to new range. -newRangeLower | Fungus.FloatData | Min of the new target range, default 0. -newRangeUpper | Fungus.FloatData | Max of the new target range, default 1. -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). - # MinMax # {#MinMax} -Sets the outValue to minimum or the maximum of 2 given values. +Command to store the min or max of 2 values Defined in Fungus.MinMax Property | Type | Description --- | --- | --- -function | System.Enum | Min or Max. -inLHSValue | Fungus.FloatData | lhs given to min or max function. -inRHSValue | Fungus.FloatData | rhs given to min or max function. -outValue | Fungus.FloatData | Value the result of the function min or max. +Function | Fungus.MinMax+Function | Min Or Max -# Neg # {#Neg} -Sets the outValue to the be addative inverse of the inValue, becomes -inValue. +# Negate # {#Negate} +Negate a float Defined in Fungus.Neg Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # Pow # {#Pow} -Sets the outValue to result of a base value rasied to an exponent. -E.g. 2^5 -2 is the base -5 is the exponent. +Raise a value to the power of another. Defined in Fungus.Pow Property | Type | Description --- | --- | --- -baseValue | Fungus.FloatData | Base value. -exponentValue | Fungus.FloatData | Exponent value -outValue | Fungus.FloatData | Value the result of the pow function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # Round # {#Round} -Sets the outValue to the Rounded result of inValue. +Command to execute and store the result of a Round Defined in Fungus.Round Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. -mode | System.Enum | Round or Floor or Ceil. Round is closest whole number, Floor is the smaller whole number, Ceil is the larger whole number. +Function | Fungus.Round+Mode | Mode; Round (closest), floor(smaller) or ceil(bigger). +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # Sign # {#Sign} -Sets the outValue to the be mutliplicative sign of the inValue. -1 for negative number otherwise it is 1. +Command to execute and store the result of a Sign Defined in Fungus.Sign Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # Sqrt # {#Sqrt} -Sets the outValue to the be square root of the inValue. +Command to execute and store the result of a Sqrt Defined in Fungus.Sqrt Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.FloatData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. # ToInt # {#ToInt} -Sets the outValue to the Rounded to Int result of inValue. +Command to execute and store the result of a float to int conversion Defined in Fungus.ToInt Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.IntData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. -mode | System.Enum | RoundToInt or FloorToInt or CeilToInt. Round is closest integer, Floor is the smaller integer, Ceil is the larger integer. +Function | Fungus.ToInt+Mode | To integer mode; round, floor or ceil. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.IntegerData | Where the result of the function is stored. # Trig # {#Trig} -Sets the outValue to the of a trigonmetric function performed on inValue. +Command to execute and store the result of basic trigonometry Defined in Fungus.Trig Property | Type | Description --- | --- | --- -inValue | Fungus.FloatData | Value passed into the function (the right hand side). -outValue | Fungus.IntData | Value the result of the function is saved to (the left hand side). This can be the same Fungus.FloatData as the inValue. -function | System.Enum | Rad2Deg, Deg2Rad, ACos, ASin, ATan, Cos, Sin, Tan. Default is Sin. \ No newline at end of file +Function | Fungus.Trig+Function | Trigonometric function to run. +In Value | Fungus.FloatData | Value to be passed in to the function. +Out Value | Fungus.FloatData | Where the result of the function is stored. + diff --git a/Docs/command_ref/narrative_commands.md b/Docs/command_ref/narrative_commands.md index 878f3215..3ef6338d 100644 --- a/Docs/command_ref/narrative_commands.md +++ b/Docs/command_ref/narrative_commands.md @@ -41,7 +41,7 @@ Target Block | Fungus.Block | Block to execute when this option is selected Hide If Visited | System.Boolean | Hide this option if the target block has been executed previously Interactable | Fungus.BooleanData | If false, the menu option will be displayed but will not be selectable Set Menu Dialog | Fungus.MenuDialog | A custom Menu Dialog to use to display this menu. All subsequent Menu commands will use this dialog. -hideThisOption | Fungus.BooleanData | If true, this option will be passed to the Menu Dialogue but marked as hidden, this can be used to hide options while maintaining a Menu Shuffle. +Hide This Option | Fungus.BooleanData | If true, this option will be passed to the Menu Dialogue but marked as hidden, this can be used to hide options while maintaining a Menu Shuffle. # Menu Shuffle # {#MenuShuffle} Shuffle the order of the items in a Fungus Menu @@ -50,8 +50,7 @@ Defined in Fungus.MenuShuffle Property | Type | Description --- | --- | --- -shuffleMode | System.Enum | Determines if the order is shuffled everytime this command is it (Every) or if it is consistent when returned to but random (Once) - +Shuffle Mode | Fungus.MenuShuffle+Mode | Determines if the order is shuffled everytime this command is it (Every) or if it is consistent when returned to but random (Once) # Menu Timer # {#MenuTimer} Displays a timer bar and executes a target block if the player fails to select a menu option in time. @@ -104,8 +103,8 @@ Extend Previous | System.Boolean | Type this text in the previous dialog box. Fade When Done | System.Boolean | Fade out the dialog box when writing has finished and not waiting for input. Wait For Click | System.Boolean | Wait for player to click before continuing. Stop Voiceover | System.Boolean | Stop playing voiceover when text finishes writing. +Wait For V O | System.Boolean | Wait for the Voice Over to complete before continuing Set Say Dialog | Fungus.SayDialog | Sets the active Say dialog with a reference to a Say Dialog object in the scene. All story text will now display using this Say Dialog. -Wait for VO | System.Boolean | Wait for the VO line to complete before continuing. # Set Language # {#SetLanguage} Set the active language for the scene. A Localization object with a localization file must be present in the scene. diff --git a/Docs/command_ref/rigidbody2d_commands.md b/Docs/command_ref/rigidbody2d_commands.md index a4bfc8d9..9cf6fbc0 100644 --- a/Docs/command_ref/rigidbody2d_commands.md +++ b/Docs/command_ref/rigidbody2d_commands.md @@ -1,39 +1,27 @@ -# Rigidbody2D Commands # {#rigidbody2d_commands} - -Commands that interact with [UnityEngine.Rigidbody2D](https://docs.unity3d.com/ScriptReference/Rigidbody2D.html) & Fungus.Rigidbody2DVariable +# Rigidbody2D commands # {#rigidbody2d_commands} [TOC] -# AddTorque2D # {#AddTorque2D} -Add Torque to a Rigidbody2D. +# AddForce2D # {#AddForce2D} +Add force to a Rigidbody2D -Defined in Fungus.AddTorque2D +Defined in Fungus.AddForce2D Property | Type | Description --- | --- | --- -rb | Fungus.Rigidbody2DData | Targeted rigidbody2d -forceMode | Unity.ForceMode2D | Parameter given to AddTorque -force | Fungus.FloatData | Amount of torque to be added +Force | Fungus.Vector2Data | Vector of force to be added +Force Scale Factor | Fungus.FloatData | Scale factor to be applied to force as it is used. +At Position | Fungus.Vector2Data | World position the force is being applied from. Used only in AddForceAtPosition -# AddForce2D # {#AddForce2D} -Add Force to a Rigidbody2D. +# AddTorque2D # {#AddTorque2D} +Add Torque to a Rigidbody2D -Defined in Fungus.AddForce2D +Defined in Fungus.AddTorque2D Property | Type | Description --- | --- | --- -rb | Fungus.Rigidbody2DData | Targeted rigidbody2d -forceMode | Unity.ForceMode2D | Parameter given to AddForce -forceFunction | System.Enum | Which variant of AddForce to use (AddForce,AddForceAtPosition,AddRelativeForce) -force | Fungus.Vector2DData | Amount of torque to be added -forceScaleFactor | Fungus.FloatData | Scale factor to be applied to force as it is used. Default 1. -atPosition | Fungus.Vector2DData | World position the force is being applied from. Used only in AddForceAtPosition +Force | Fungus.FloatData | Amount of torque to be added # StopMotion2D # {#StopMotion2D} -Stop motion or angularmotion or both of a rigidbody2d. +Stop velocity and angular velocity on a Rigidbody2D -Defined in Fungus.StopMotion2D - -Property | Type | Description - --- | --- | --- -rb | Fungus.Rigidbody2DData | Targeted rigidbody2d -motionToStop | System.Enum | Which motion to stop (Velocity,AngularVelocity,AngularAndLinearVelocity) \ No newline at end of file +Defined in Fungus.StopMotionRigidBody2D diff --git a/Docs/command_ref/scene_commands.md b/Docs/command_ref/scene_commands.md index 2de4d37e..ede34b5c 100644 --- a/Docs/command_ref/scene_commands.md +++ b/Docs/command_ref/scene_commands.md @@ -1,6 +1,4 @@ -# Scene Commands # {#scene_commands} - -Commands that interact with scenes and Unity SceneManagement. +# Scene commands # {#scene_commands} [TOC] # Reload # {#Reload} @@ -10,4 +8,5 @@ Defined in Fungus.ReloadScene Property | Type | Description --- | --- | --- -Loading Image | UnityEngine.Texture2D | Image to display while loading the scene \ No newline at end of file +Loading Image | UnityEngine.Texture2D | Image to display while loading the scene + diff --git a/Docs/command_ref/scripting_commands.md b/Docs/command_ref/scripting_commands.md index 84375ea1..9769f235 100644 --- a/Docs/command_ref/scripting_commands.md +++ b/Docs/command_ref/scripting_commands.md @@ -40,7 +40,7 @@ Defined in Fungus.Destroy Property | Type | Description --- | --- | --- _target Game Object | Fungus.GameObjectData | Reference to game object to destroy -destroyInXSeconds | Fungus.FloatData | Optional delay given to the destroy +Destroy In X Seconds | Fungus.FloatData | Optional delay given to destroy # Execute Lua # {#ExecuteLua} Executes a Lua code chunk using a Lua Environment. @@ -117,15 +117,15 @@ _target Game Object | Fungus.GameObjectData | Reference to game object to enable Active State | Fungus.BooleanData | Set to true to enable the game object # Spawn Object # {#SpawnObject} -Spawns a new object based on a reference to a scene or prefab game object. Can use the Instantiate parent if desired and can be set to spawn at the same location as the flowchart. +Spawns a new object based on a reference to a scene or prefab game object. Defined in Fungus.SpawnObject Property | Type | Description --- | --- | --- _source Object | Fungus.GameObjectData | Game object to copy when spawning. Can be a scene object or a prefab. -_parent Transform | Fungus.TransformData | Optional, Transform to use as parent of newly spawned object. -_sapwn At Self | Fungus.BooleanData | If true, will use the Transfrom of this Flowchart for the position and rotation. +_parent Transform | Fungus.TransformData | Transform to use as parent during instantiate. +_spawn At Self | Fungus.BooleanData | If true, will use the Transfrom of this Flowchart for the position and rotation. _spawn Position | Fungus.Vector3Data | Local position of newly spawned object. _spawn Rotation | Fungus.Vector3Data | Local rotation of newly spawned object. _newly Spawned Object | Fungus.GameObjectData | Optional variable to store the GameObject that was just created. diff --git a/Docs/command_ref/transform_commands.md b/Docs/command_ref/transform_commands.md index 01167ef8..2ec3f49b 100644 --- a/Docs/command_ref/transform_commands.md +++ b/Docs/command_ref/transform_commands.md @@ -1,16 +1,7 @@ # Transform commands # {#transform_commands} -Commands that interact with and impact the UnityEngine.Transform - [TOC] # Property # {#Property} -Fades a sprite to a target color over a period of time. +Get or Set a property of a transform component Defined in Fungus.TransformProperty - -Property | Type | Description - --- | --- | --- -getOrSet | System.Enum | Get or set the property from the transform -property | System.Enum | Which property are you targeting (ChildCount,EulerAngles,Forward,HasChanged,HierarchyCapacity,HierarchyCount,LocalEulerAngles,LocalPosition,LocalScale,LossyScale,Parent,Position,Right,Root,Up) -transformData | Fungus.TransformData | Target transform. -inOutVar | Fungus.Variable | Variable that is being used to pull data from or push the data to. Can be a bool, int, float or Transform. See (Unity Transform Docs for detials)[https://docs.unity3d.com/ScriptReference/Transform.html] diff --git a/Docs/command_ref/ui_commands.md b/Docs/command_ref/ui_commands.md index 65f06cc2..f360afb3 100644 --- a/Docs/command_ref/ui_commands.md +++ b/Docs/command_ref/ui_commands.md @@ -34,7 +34,7 @@ Toggle | UnityEngine.UI.Toggle | Target toggle object to get the value from Toggle State | Fungus.BooleanVariable | Boolean variable to store the state of the toggle value in. # Set Interactable # {#SetInteractable} -Set the interactable sate of selectable objects. +Set the interactable state of selectable objects. Defined in Fungus.SetInteractable diff --git a/Docs/command_ref/vector3_commands.md b/Docs/command_ref/vector3_commands.md index 9678509f..25462197 100644 --- a/Docs/command_ref/vector3_commands.md +++ b/Docs/command_ref/vector3_commands.md @@ -1,49 +1,19 @@ -# Vector3 Commands # {#vector3_commands} - -Commands that interact with and manipulate Fungus.Vector3Variable +# Vector3 commands # {#vector3_commands} [TOC] # Arithmetic # {#Arithmetic} Vector3 add, sub, mul, div arithmetic Defined in Fungus.Vector3Arithmetic - -Property | Type | Description - --- | --- | --- -lhs | Fungus.Vector3Data | Left hand side of the operation -rhs | Fungus.Vector3Data | Right hand side of the operation -output | Fungus.Vector3Data | Push result of operation into this variable -operation | System.Enum | Operation to perform (Add,Sub,Mul,Div) - # Fields # {#Fields} Get or Set the x,y,z fields of a vector3 via floatvars Defined in Fungus.Vector3Fields - -Property | Type | Description - --- | --- | --- -getOrSet | System.Enum | Get or Set the fields of the Vector3. -vec3 | Fungus.Vector3Data | Target Vector3. -x | Fungus.FloatData | x field. -y | Fungus.FloatData | y field. -z | Fungus.FloatData | z field. - # Normalise # {#Normalise} -Normalise a vector3, output can be the same as the input. +Normalise a Vector3 Defined in Fungus.Vector3Normalise - -Property | Type | Description - --- | --- | --- -vec3In | Fungus.Vector3Data | Vector3 data to be normalised. -vec3Out | Fungus.Vector3Data | Vector3 to store result of normalisation. - # ToVector2 # {#ToVector2} -Convert Fungus Vector3 to Fungus Vector2. +Convert Fungus Vector3 to Fungus Vector2 Defined in Fungus.Vector3ToVector2 - -Property | Type | Description - --- | --- | --- -vec3 | Fungus.Vector3Data | Vector3 data to be normalised. -vec2 | Fungus.Vector3Data | Vector2 to store result of normalisation. \ No newline at end of file