LuaLibraryUtils.wiki
author Wuzzy
Wed, 02 May 2018 22:50:47 +0100
changeset 1336 41f5299584ed
parent 1331 fef74f26cab9
child 1345 673321313201
permissions -rw-r--r--
LuaLibraryUtils: remove label
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1329
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
     1
#summary Lua library documentation: Utils
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
     2
1331
fef74f26cab9 LuaLibraryUtils: headings
Wuzzy
parents: 1329
diff changeset
     3
= Lua library: `Utils` =
1329
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
     4
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
     5
**NOTE: Documentation of this library is incomplete, some functions are still undocumented.**
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
     6
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
     7
This library includes miscellaneous functions to use, they are all independent of each other and can be used everywhere.
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
     8
1331
fef74f26cab9 LuaLibraryUtils: headings
Wuzzy
parents: 1329
diff changeset
     9
== `gearIsInBox(gear, x, y, w, h)` ==
1329
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
    10
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
    11
Returns whether the gear is inside (centre point of the gear) a box with x and y as the top left corner and having the width and height of w and h respectively.
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
    12
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
    13
1331
fef74f26cab9 LuaLibraryUtils: headings
Wuzzy
parents: 1329
diff changeset
    14
== `gearIsInCircle(gear, x, y, r, useRadius)` ==
1329
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
    15
bd781e19a52d Split Lua libraries into several sub-pages
Wuzzy <almikes@aol.com>
parents:
diff changeset
    16
Returns whether the gear is inside a circle with x and y being the centre point and r being the radius of the circle. The boolean useRadius determine whether only the centre point of the gear will be used or the radius of the gear will be checked too.