-
-
Notifications
You must be signed in to change notification settings - Fork 0
Module: Character
Аниса edited this page Jun 16, 2022
·
27 revisions
This module provides a custom character management interface to integrate w/ your resources. For servers such as DayZ
, Roleplay
, RPG
, Arenas
where clients can create multiple character under their account, this module comes into the play!
Syntax #2 should only be used in conjunction w/ thread
local bool: state = dbify.character.fetchAll(
table: {
--These are conditional datas that has to be used for the query
{string: columnName, ~: columnValue},
},
function: callback(table: result, table: arguments),
~: ...arguments
)
--Syntax #2:
local table: result, table: arguments = self:await(dbify.character.fetchAll(
thread: self,
table: {
--These are conditional datas that has to be used for the query
{string: columnName, ~: columnValue},
},
~: ...arguments
))
--Syntax #1:
local bool: state = dbify.character.create(
function: callback(int: characterID, table: arguments),
~: ...arguments
)
--Syntax #2:
local int: characterID, table: arguments = self:await(dbify.character.create(
thread: self,
~: ...arguments
))
--Syntax #1:
local bool: state = dbify.character.delete(
int: characterID,
function: callback(bool: result, table: arguments),
~: ...arguments
)
--Syntax #2:
local bool: result, table: arguments = self:await(dbify.character.delete(
thread: self,
int: characterID,
~: ...arguments
))
--Syntax #1:
local bool: state = dbify.character.setData(
int: characterID,
table: {
--These are columns that has to be updated w/ their respective values
{string: columnName, ~: columnValue},
...
},
function: callback(bool: result, table: arguments),
~: ...arguments
)
--Syntax #2:
local bool: result, table: arguments = self:await(dbify.character.setData(
thread: self,
int: characterID,
table: {
--These are columns that has to be updated w/ their respective values
{string: columnName, ~: columnValue},
...
},
~: ...arguments
))
--Syntax #1:
local bool: state = dbify.character.getData(
int: characterID,
table: {
--These are columns whose values are to be retrieved
string: columnName,
...
},
function: callback(table: result, table: arguments),
~: ...arguments
)
--Syntax #2:
local table: result, table: arguments = self:await(dbify.character.getData(
thread: self,
int: characterID,
table: {
--These are columns whose values are to be retrieved
string: columnName,
...
},
~: ...arguments
))