GetAccountsBySerial: Difference between revisions
Jump to navigation
Jump to search
Jurandovsky (talk | contribs) No edit summary |
m (Добавление языков) |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 31: | Line 31: | ||
{{Account_functions}} | {{Account_functions}} | ||
[[en:getAccountsBySerial]] | |||
[[ru:getAccountsBySerial]] | |||
[[pl:getAccountsBySerial]] | [[pl:getAccountsBySerial]] | ||
[[zh-cn:getAccountsBySerial]] |
Latest revision as of 13:23, 12 April 2021
This function returns a table containing all accounts that were logged onto from specified serial. If the serial is empty string, it will return all accounts that were never logged onto.
Syntax
table getAccountsBySerial ( string serial )
OOP Syntax Help! I don't understand this!
- Note: This function is a static function underneath the Account class.
- Method: Account.getAllBySerial(...)
Required Arguments
- serial: The serial to get accounts from
Returns
Returns table containing the accounts associated with specified serial. Returns false if invalid arguments were specified.
Example
This example adds command getAccounts that outputs the number of accounts a player has in the chat box.
addCommandHandler("getAccounts", function (player, cmd) local serial = getPlayerSerial(player) local accounts = getAccountsBySerial(serial) outputChatBox("You have " .. #accounts .. " accounts.", player) end)
See Also
- addAccount
- copyAccountData
- getAccount
- getAccountData
- getAccountName
- getAccountPlayer
- getAccountSerial
- getAccounts
- getAccountsBySerial
- getAllAccountData
- getPlayerAccount
- isGuestAccount
- logIn
- logOut
- removeAccount
- setAccountData
- setAccountPassword
- getAccountByID
- getAccountID
- getAccountIP
- getAccountsByData
- getAccountsByIP
- setAccountName