LuaLibraryAnimate: StoppedGear and other funcs
authorWuzzy
Thu, 03 May 2018 00:18:54 +0100
changeset 1382 8d6310a05033
parent 1381 6695b6e1d39a
child 1383 75735c1890c7
LuaLibraryAnimate: StoppedGear and other funcs
LuaLibraryAnimate.wiki
--- a/LuaLibraryAnimate.wiki	Thu May 03 00:08:47 2018 +0100
+++ b/LuaLibraryAnimate.wiki	Thu May 03 00:18:54 2018 +0100
@@ -25,6 +25,9 @@
 === `ShowAnimation()` ===
 Performs the current action in the cinematic and returns `true` if finished, otherwise `false`. It needs to be used in `onGameTick`. Cut-scenes need to be added with `AddAnim(steps)`.
 
+=== `Animate()` ===
+*UNDOCUMENTED!*
+
 === `AddAnim(steps)` ===
 Adds `steps` to the array of animations, where `steps` is a table with numbers as keys and elements of the following form. Each step is a table having the following keys: `func`, `args`, `swh`.
 
@@ -90,6 +93,12 @@
 === `AnimSwitchHog(gear)` ===
 Switches to `gear` and follows it.
 
+=== `AnimGiveState(gear, state)` ===
+Adds the [GearStates gear state] `state` to `gear`.
+
+=== `AnimRemoveState(gear, state)` ===
+Removes the [GearStates gear state] `state` from `gear`.
+
 === `AnimWait(gear, time)` ===
 Increases the wait time by `time`. `gear` is just for compatibility with `ShowAnimation`.
 
@@ -213,3 +222,8 @@
 Internally, the input mask you provide is simply AND-ed with the input mask used by the Animate library. Otherwise, this function works lik `SetInputMask`.
 
 If you call `SetInputMask` directly, note that it might get quickly overwritten by the Animatel library!
+
+== Misc. ==
+
+=== `StoppedGear(gear)` ===
+Returns `true` if the gear is considered to be resting (not moving). (dX and dY are very small) or if the gear does not exist.