ZH-CN/GetAccountsByIP
Jump to navigation
Jump to search
语法
table getAccountsByIP ( string ip )
OOP 语法 什么是OOP?
- 提示: This function is a static function underneath the Account class.
- 方法: Account.getAllByIP(...)
必填参数
- ip: 要从中获取帐户的IP
返回值
返回 “表”(table),其中包含与指定IP地址关联的帐户。如果指定了无效参数,则返回“false”。
示例
此示例添加命令“getAccounts”,该命令输出玩家在聊天框中拥有的帐户数
addCommandHandler("getAccounts", function (player, cmd) local ip = getPlayerIP(player) local accounts = getAccountsByIP(ip) outputChatBox("你有 " .. #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