Adventure Creator
1.79.1
An adventure game toolkit for Unity, by Chris Burton, ICEBOX Studios 2013-2022
|
Static Public Member Functions | |||||
static void | SetMixerVolume (AudioMixerGroup audioMixerGroup, string parameter, float volume) | ||||
Sets the volume of an Audio Mixer Group (Unity 5 and onward only). More... | |||||
static void | AssignMixerGroup (AudioSource audioSource, SoundType soundType) | ||||
Sets the 'Output Audio Mixer Group' of an Audio Source, based on its sound type (Unity 5 only). More... | |||||
static int | GetAnimLayerInt (AnimLayer animLayer) | ||||
Returns the integer value of the AnimLayer enum. Necessary because two Neck layers are used, though only one is present in the enum. More... | |||||
static References | GetReferences () | ||||
static RuntimeActionList | RunActionListAsset (ActionListAsset actionListAsset, int parameterID=-1, int parameterValue=0) | ||||
Runs an ActionList asset file. If the ActionList contains an Integer parameter, the parameter's value can be set here. More... | |||||
static RuntimeActionList | RunActionListAsset (ActionListAsset actionListAsset, GameObject parameterValue) | ||||
Runs an ActionList asset file, and sets the value of the first parameter, provided that it is a GameObject. More... | |||||
static RuntimeActionList | RunActionListAsset (ActionListAsset actionListAsset, int i, bool addToSkipQueue) | ||||
Runs an ActionList asset file. More... | |||||
static RuntimeActionList | RunActionListAsset (ActionListAsset actionListAsset, Conversation endConversation) | ||||
Runs an ActionList asset file. More... | |||||
static RuntimeActionList | RunActionListAsset (ActionListAsset actionListAsset, Conversation endConversation, int i, bool doSkip, bool addToSkipQueue) | ||||
Runs or skips an ActionList asset file. More... | |||||
static RuntimeActionList | SkipActionListAsset (ActionListAsset actionListAsset) | ||||
Skips an ActionList asset file. More... | |||||
static RuntimeActionList | SkipActionListAsset (ActionListAsset actionListAsset, int i, Conversation endConversation=null) | ||||
Skips an ActionList asset file. More... | |||||
static double | CalculateFormula (string formula) | ||||
Calculates a formula (Not available for Windows Phone devices). More... | |||||
static string | CombineLanguageString (string string1, string string2, int langugeIndex, bool separateWithSpace=true) | ||||
Combines two on-screen strings into one. More... | |||||
static string | ConvertTokens (string _text) | ||||
Converts a string's tokens into their true values. The '[var:ID]' token will be replaced by the value of global variable 'ID'. The '[localvar:ID]' token will be replaced by the value of local variable 'ID'. More... | |||||
static string | ConvertTokens (string _text, int languageNumber, LocalVariables localVariables=null, List< ActionParameter > parameters=null) | ||||
Converts a string's tokens into their true values. The '[var:ID]' token will be replaced by the value of global variable 'ID'. The '[localvar:ID]' token will be replaced by the value of local variable 'ID'. More... | |||||
static string | GetVariableTokenText (VariableLocation location, int varID, int variablesConstantID=0) | ||||
static string | ConvertLocalVariableTokenToGlobal (string _text, int oldLocalID, int newGlobalID) | ||||
Converts a token that refers to a given local variable, to one that refers to a given global variable More... | |||||
static string | ConvertGlobalVariableTokenToLocal (string _text, int oldGlobalID, int newLocalID) | ||||
Converts a token that refers to a given local variable, to one that refers to a given global variable More... | |||||
static void | DrawCubeCollider (Transform transform, Color color) | ||||
Draws a cube gizmo in the Scene window. More... | |||||
static void | DrawBoxCollider (Transform transform, Color color) | ||||
Draws a box gizmo in the Scene window. More... | |||||
static void | DrawPolygonCollider (Transform transform, PolygonCollider2D poly, Color color) | ||||
Draws an outline of a Polygon Collider 2D in the Scene window. More... | |||||
static void | DrawMeshCollider (Transform transform, Mesh mesh, Color color) | ||||
Draws an outline of a 3D Mesh in the Scene window. More... | |||||
static void | DrawSphereCollider (Transform transform, SphereCollider sphereCollider, Color color) | ||||
Draws a sphere in the Scene window. More... | |||||
static void | DrawCapsule (Transform transform, Vector3 centre, float radius, float height, Color color) | ||||
Draws a capsule in the Scene window. More... | |||||
static void | FindObjectWithConstantID (int _constantID) | ||||
Locates an object with a supplied ConstantID number (Unity Editor only). If the object is not found in the current scene, all scenes in the Build Settings will be searched. Once an object is found, it will be pinged in the Hierarchy window. More... | |||||
static string[] | GetSceneFiles () | ||||
Returns all scene filenames listed in the Build Settings (Unity Editor only). More... | |||||
static int | GlobalVariableGUI (string label, int variableID, string tooltip="") | ||||
Generates a Global Variable selector GUI (Unity Editor only). More... | |||||
static int | GlobalVariableGUI (string label, int variableID, VariableType variableType, string tooltip="") | ||||
Generates a Global Variable selector GUI (Unity Editor only). More... | |||||
static int | GlobalVariableGUI (string label, int variableID, VariableType[] variableTypes, string tooltip="") | ||||
Generates a Global Variable selector GUI (Unity Editor only). More... | |||||
static int | LocalVariableGUI (string label, int variableID, VariableType variableType) | ||||
Generates a Local Variable selector GUI (Unity Editor only). More... | |||||
static int | LocalVariableGUI (string label, int variableID, VariableType[] variableTypes) | ||||
Generates a Local Variable selector GUI (Unity Editor only). More... | |||||
static int | ComponentVariableGUI (string label, int variableID, VariableType variableType, Variables variables) | ||||
Generates a Component Variable selector GUI (Unity Editor only). More... | |||||
static int | ComponentVariableGUI (string label, int variableID, VariableType[] variableTypes, Variables variables) | ||||
Generates a Component Variable selector GUI (Unity Editor only). More... | |||||
static void | DrawNodeCurve (Rect start, Rect end, Color color, int offset, bool onSide, bool isDisplayed) | ||||
Draws a curve between two Actions in the ActionList Editor window (Unity Editor only). More... | |||||
static void | DrawNodeCurve (Rect start, Vector2 end, Color color, int offset, bool fromSide, bool toSide, bool isDisplayed) | ||||
Draws a curve between two Actions in the ActionList Editor window (Unity Editor only). More... | |||||
static LayerMask | LayerMaskField (string label, LayerMask layerMask, string tooltip="") | ||||
static Vector3 | GetScreenDirection (Vector3 originWorldPosition, Vector3 targetWorldPosition) | ||||
Returns the vector between two world-space points when converted to screen-space.</summary?
| |||||
static Vector3 | GetScreenNavMesh (Vector3 targetWorldPosition) | ||||
Returns the percieved point on a NavMesh of a world-space position, when viewed through screen-space. More... | |||||
static Matrix4x4 | SetVanishingPoint (Camera _camera, Vector2 perspectiveOffset, bool accountForFOV=false) | ||||
Sets the vanishing point of a perspective-locked camera. More... | |||||
static string | UniqueName (string name) | ||||
Generates a unique name for a GameObject by adding numbers to the end of it. More... | |||||
static Rect | GUIBox (float centre_x, float centre_y, float size) | ||||
Generates a Rect from a square. More... | |||||
static Rect | GUIBox (Vector2 posVector, float size) | ||||
Generates a Rect from a square. More... | |||||
static Rect | GUIRect (float centre_x, float centre_y, float width, float height) | ||||
Generates a Rect from a rectangle. More... | |||||
static void | PlayAnimClipFrame (Animation _animation, int layer, AnimationClip clip, AnimationBlendMode blendMode, WrapMode wrapMode, float fadeTime, Transform mixingBone, float normalisedFrame) | ||||
Initialises and plays a legacy AnimationClip on an Animation component, starting from a set point. More... | |||||
static void | PlayAnimClip (Animation _animation, int layer, AnimationClip clip, AnimationBlendMode blendMode=AnimationBlendMode.Blend, WrapMode wrapMode=WrapMode.ClampForever, float fadeTime=0f, Transform mixingBone=null, bool reverse=false) | ||||
Initialises and plays a legacy AnimationClip on an Animation component. More... | |||||
static void | CleanUnusedClips (Animation _animation) | ||||
Cleans the supplied Animation component of any clips not being played. More... | |||||
static float | Lerp (float from, float to, float t) | ||||
Lerps from one float to another over time. More... | |||||
static Vector3 | Lerp (Vector3 from, Vector3 to, float t) | ||||
Lerps from one Vector3 to another over time. More... | |||||
static Quaternion | Lerp (Quaternion from, Quaternion to, float t) | ||||
Lerps from one Quaternion to another over time. More... | |||||
static float | Interpolate (float startT, float deltaT, MoveMethod moveMethod, AnimationCurve timeCurve=null) | ||||
Interpolates a float over time, according to various interpolation methods. More... | |||||
static float | Interpolate (float weight, MoveMethod moveMethod, AnimationCurve timeCurve=null) | ||||
static void | DrawTextEffect (Rect rect, string text, GUIStyle style, Color outColor, Color inColor, float size, TextEffects textEffects) | ||||
Draws GUI text with an outline and/or shadow. More... | |||||
static string | PrepareStringForSaving (string _string) | ||||
static string | PrepareStringForLoading (string _string) | ||||
static float | SignedAngle (Vector2 from, Vector2 to) | ||||
Gets the signed angle between two 2D vectors More... | |||||
static Vector3 | GetCharLookVector (CharDirection direction, Char _character=null) | ||||
A class that provides a number of useful functons for both editor and runtime.
|
static |
Sets the 'Output Audio Mixer Group' of an Audio Source, based on its sound type (Unity 5 only).
audioSource | The Audio Source component to affect |
soundType | The sound type that controls the volume |
|
static |
Calculates a formula (Not available for Windows Phone devices).
formula | The formula string to calculate |
|
static |
Cleans the supplied Animation component of any clips not being played.
_animation | The Animation component to clean |
|
static |
Combines two on-screen strings into one.
string1 | The first string |
string1 | The second string |
languageIndex | The index number of the current language. If the language reads right-to-left, then the strings will be combined in reverse |
separateWithSpace | If True, the two strings will be separated by a space |
|
static |
Generates a Component Variable selector GUI (Unity Editor only).
label | The label of the popup GUI |
variableID | The currently-selected local variable's ID number |
variableType | The variable type to restrict choices to |
variables | The Variables component that contains the variable |
|
static |
Generates a Component Variable selector GUI (Unity Editor only).
label | The label of the popup GUI |
variableID | The currently-selected local variable's ID number |
variableTypes | An array variable types to restrict choices to |
variables | The Variables component that contains the variable |
|
static |
Converts a token that refers to a given local variable, to one that refers to a given global variable
_text | The text to convert |
oldGlobalID | The ID number of the old global variable |
newLocalID | The ID number of the new local variable |
|
static |
Converts a token that refers to a given local variable, to one that refers to a given global variable
_text | The text to convert |
oldLocalID | The ID number of the old local variable |
newGlobalID | The ID number of the new global variable |
|
static |
Converts a string's tokens into their true values. The '[var:ID]' token will be replaced by the value of global variable 'ID'. The '[localvar:ID]' token will be replaced by the value of local variable 'ID'.
_text | The original string with tokens |
|
static |
Converts a string's tokens into their true values. The '[var:ID]' token will be replaced by the value of global variable 'ID'. The '[localvar:ID]' token will be replaced by the value of local variable 'ID'.
_text | The original string with tokens |
languageNumber | The index number of the game's current language |
localVariables | The LocalVariables script to read local variables from, if not the scene default |
|
static |
Draws a box gizmo in the Scene window.
transform | The transform of the object to draw around |
color | The colour of the box |
|
static |
Draws a capsule in the Scene window.
transform | The transform of the object to draw around |
centre | The capsule's centre |
radius | The capsule's radius |
height | The capsule's height |
color | The colour to draw with |
|
static |
Draws a cube gizmo in the Scene window.
transform | The transform of the object to draw around |
color | The colour of the cube |
|
static |
Draws an outline of a 3D Mesh in the Scene window.
transform | The transform of the object to draw around |
mesh | The Mesh to draw |
color | The colour of the mesh |
|
static |
Draws a curve between two Actions in the ActionList Editor window (Unity Editor only).
|
static |
Draws a curve between two Actions in the ActionList Editor window (Unity Editor only).
start | The Rect of the Action to draw from |
end | The point to draw to |
color | The colour of the curve |
offset | How far the line should be offset along the rect |
fromSide | True if the curve should begin on the side of the Action |
toSide | True if the curve should end on the side of the Action |
isDisplayed | True if the Action to draw from is expanded |
|
static |
Draws an outline of a Polygon Collider 2D in the Scene window.
transform | The transform of the object to draw around |
poly | The Polygon Collider 2D |
color | The colour of the outline |
|
static |
Draws a sphere in the Scene window.
transform | The transform of the object to draw around |
sphereCollider | The SphereCollider to use as a reference |
color | The colour to draw with |
|
static |
Draws GUI text with an outline and/or shadow.
rect | The Rect of the GUI text |
text | The text itself |
style | The GUIStyle that the GUI text uses |
outColour | The colour of the text's outline/shadow |
inColour | The colour of the text itself |
size | The size of the text |
textEffects | The type of text effect (Outline, Shadow, OutlineAndShadow, None) |
|
static |
Locates an object with a supplied ConstantID number (Unity Editor only). If the object is not found in the current scene, all scenes in the Build Settings will be searched. Once an object is found, it will be pinged in the Hierarchy window.
_constantID | The ConstantID number of the object to find |
|
static |
Returns the integer value of the AnimLayer enum. Necessary because two Neck layers are used, though only one is present in the enum.
animLayer | The AnimLayer enum |
|
static |
Returns the References asset, which should be located in a Resources directory.
|
static |
Returns all scene filenames listed in the Build Settings (Unity Editor only).
|
static |
Returns the percieved point on a NavMesh of a world-space position, when viewed through screen-space.
targetWorldPosition | The position in world-space
|
|
static |
Generates a Global Variable selector GUI (Unity Editor only).
label | The label of the popup GUI |
variableID | The currently-selected global variable's ID number |
|
static |
Generates a Global Variable selector GUI (Unity Editor only).
label | The label of the popup GUI |
variableID | The currently-selected global variable's ID number |
variableType | The variable type to restrict choices to |
|
static |
Generates a Global Variable selector GUI (Unity Editor only).
label | The label of the popup GUI |
variableID | The currently-selected global variable's ID number |
variableTypes | An array variable types to restrict choices to |
|
static |
Generates a Rect from a square.
centre_x | The centre of the square in the x-direction |
centre_y | The centre of the square in the y-direction |
size | The size of the square |
|
static |
Generates a Rect from a square.
posVector | The top-left corner of the square |
size | The size of the square |
|
static |
Generates a Rect from a rectangle.
centre_x | The centre of the rectangle in the x-direction |
centre_y | The centre of the rectangle in the y-direction |
width | The width of the rectangle |
height | The height of the rectangle |
|
static |
Interpolates a float over time, according to various interpolation methods.
startT | The starting time |
deltaT | The time difference |
moveMethod | The method of interpolation (Linear, Smooth, Curved, EaseIn, EaseOut, Curved) |
timeCurve | The AnimationCurve to interpolate against, if the moveMethod = MoveMethod.Curved |
|
static |
Lerps from one float to another over time.
from | The initial value |
to | The final value |
t | The time value. If greater than 1, the result will overshoot the final value. If less than 1, the result will undershoot the initial value |
|
static |
Lerps from one Quaternion to another over time.
from | The initial value |
to | The final value |
t | The time value. If greater than 1, the result will overshoot the final value. If less than 1, the result will undershoot the initial value |
|
static |
Lerps from one Vector3 to another over time.
from | The initial value |
to | The final value |
t | The time value. If greater than 1, the result will overshoot the final value. If less than 1, the result will undershoot the initial value |
|
static |
Generates a Local Variable selector GUI (Unity Editor only).
label | The label of the popup GUI |
variableID | The currently-selected local variable's ID number |
variableType | The variable type to restrict choices to |
|
static |
Generates a Local Variable selector GUI (Unity Editor only).
label | The label of the popup GUI |
variableID | The currently-selected local variable's ID number |
variableTypes | An array variable types to restrict choices to |
|
static |
Initialises and plays a legacy AnimationClip on an Animation component.
_animation | The Animation component |
layer | The layer to play the animation on |
clip | The AnimatonClip to play |
blendMode | The animation's AnimationBlendMode |
wrapMode | The animation's WrapMode |
fadeTime | The transition time to the new animation |
mixingBone | The transform to set as the animation's mixing transform |
reverse | True if the animation should be reversed |
|
static |
Initialises and plays a legacy AnimationClip on an Animation component, starting from a set point.
_animation | The Animation component |
layer | The layer to play the animation on |
clip | The AnimatonClip to play |
blendMode | The animation's AnimationBlendMode |
wrapMode | The animation's WrapMode |
fadeTime | The transition time to the new animation |
mixingBone | The transform to set as the animation's mixing transform |
normalisedFrame | How far along the timeline the animation should start from (0 to 1) |
|
static |
Runs an ActionList asset file.
actionListAsset | The ActionList asset to run |
endConversation | The Conversation to enable when the ActionList is complete |
|
static |
Runs or skips an ActionList asset file.
actionListAsset | The ActionList asset to run |
endConversation | The Conversation to enable when the ActionList is complete |
i | The index of the Action to start from |
doSkip | If True, all Actions within the ActionList will be run and completed instantly. |
addToSkipQueue | True if the ActionList should be added to the skip queue |
|
static |
Runs an ActionList asset file, and sets the value of the first parameter, provided that it is a GameObject.
actionListAsset | The ActionList asset to run |
parameterValue | The value to set the GameObject parameter to |
|
static |
Runs an ActionList asset file.
actionListAsset | The ActionList asset to run |
i | The index of the Action to start from |
addToSkipQueue | True if the ActionList should be added to the skip queue |
|
static |
Runs an ActionList asset file. If the ActionList contains an Integer parameter, the parameter's value can be set here.
actionListAsset | The ActionList asset to run |
parameterID | The ID of the parameter to set |
parameterValue | The value to set the parameter to, provided that IsIntegerBased returns True |
|
static |
Sets the volume of an Audio Mixer Group (Unity 5 and onward only).
audioMixerGroup | The Audio Mixer Group to affect |
parameter | The name of the attenuation parameter |
volume | The new volume (ranges from 0 to 1) |
|
static |
Sets the vanishing point of a perspective-locked camera.
_camera | The Camera to affect |
perspectiveOffset | The offset from the perspective's centre |
accountForFOV | If True, then the Camera's FOV will be accounted for |
|
static |
Gets the signed angle between two 2D vectors
from | The first vector |
to | The second vector |
|
static |
Skips an ActionList asset file.
actionListAsset | The ActionList asset to skip |
|
static |
Skips an ActionList asset file.
actionListAsset | The ActionList asset to skip |
i | The index of the Action to skip from |
endConversation | The Conversation to enable when the ActionList is complete |
|
static |
Generates a unique name for a GameObject by adding numbers to the end of it.
name | The original name of the GameObject |