Require

From GiderosMobile
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Available since: Gideros 2011.6
Class: (global)

Description

Loads and runs libraries.

require(packagename)

Roughly, require does the same job as dofile but require searches for the file in a path. Because of that, require is the preferred function in Lua for loading libraries.

Parameters

packagename: (string) library to load

See also

Loading Order of Lua Files