DiskApi

Allows you to persistently store and retrieve data for players or general use

Overview:

Functions:

API Reference

loadFile()

Loads a file into memory.

DiskApi.loadFile("data.json", true, false)

Parameters:

  • fileName (String)

  • async (Boolean)

  • global (Boolean)


saveFile()

Writes the current file data to disk.

Parameters: Same as loadFile.


getVar()

Retrieves a stored value.

Parameters:

  • fileName (String)

  • key (String)

  • fallback (Any)

  • global (Boolean)

Returns:

  • value (Any)


setVar()

Stores a value.

Parameters:

  • fileName (String)

  • key (String)

  • value (Any)

  • global (Boolean)


Example:

circle-check

Tips

Last updated

Was this helpful?