Account: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
mNo edit summary
No edit summary
(13 intermediate revisions by 13 users not shown)
Line 1: Line 1:
The [[account]] class represents a [[client]]'s server account. You can get the account object associated to any client using [[getClientAccount]].
The [[account]] class represents a [[player]]'s server account. You can get the [[account]] object associated to any client using [[getPlayerAccount]].


Accounts are unique to each client and can be used to store information that is persistent across map changes and user sessions. Clients that join without an account are given a temporary 'guest' account. This can store information like any other account, but isn't saved across sessions.
Accounts are unique to each client and can be used to store information that is persistent across map changes and user sessions. Clients that join without an account are given a temporary 'guest' account. This can store information like any other account, but isn't saved across sessions.


When a user logs in or out, the account object assigned to them will change. As such, you must not assume that the account attached to a client remains constant during their session.
When a user logs in or out, the account object assigned to them will change. As such, you must not assume that the account attached to a client remains constant during their session.
PHP code to check password hashes from the MTA server database is [[Account_PHP|here.]]


==Related scripting functions==
==Related scripting functions==
===Server===
{{Account functions}}
{{Account functions}}
[[Category:Scripting Concepts]]
[[hu:account]]
[[ru:Account]]
[[pl:Account]]
[[it:Account]]
[[de:Account]]

Revision as of 09:49, 14 December 2018

The account class represents a player's server account. You can get the account object associated to any client using getPlayerAccount.

Accounts are unique to each client and can be used to store information that is persistent across map changes and user sessions. Clients that join without an account are given a temporary 'guest' account. This can store information like any other account, but isn't saved across sessions.

When a user logs in or out, the account object assigned to them will change. As such, you must not assume that the account attached to a client remains constant during their session.

PHP code to check password hashes from the MTA server database is here.

Related scripting functions

Server