Lua:SaveGlobalData

From Fortress Forever Wiki
Revision as of 07:34, 24 June 2013 by Ddm999 (talk | contribs) (Created page with "{{Infobox manual/Header}} ==SaveGlobalData== Saves a Lua object as a serialized file allowing data to be transferred between map changes (the data can also be opened by any ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search


SaveGlobalData

Saves a Lua object as a serialized file allowing data to be transferred between map changes (the data can also be opened by any map).

Usage 1

SaveGlobalData( luaobject )

Input

  • luaobject(object) The table, string, boolean or number to be saved.

Output

Returns: nothing

Example

local datatable = { 1, 2, 3 }
SaveGlobalData( datatable )

Usage 2

SaveGlobalData( luaobject, suffix )

Input

  • luaobject(object) The table, string, boolean or number to be saved.
  • suffix(string) A suffix to add to distinguish different files.

Output

Returns: nothing

Example

local datatable = { 1, 2, 3 }
SaveGlobalData( datatable, "table" )