Jump to content

setClientLevel


Guest misco

Recommended Posts

Im trying to set and get player levels but im still getting error with this function.

Attempt to call global 'setClientLevel'

Sample from wiki seems not work.

setClientLevel ( targetPlayer, 3 ) - warning

setClientLevel ( thePlayer, tonumber( level ) ) - warning too

Link to comment
Did you put it in the "Client" script or server..If it's in "server" it wont work..

<script src="something.lua" type="client"/> 

Is Client.

<script src="something.lua" /> 

Is Server.

Btw that's in meta.xml, good luck :)

I know how to work with meta.xml but in the development wiki is:(http://development.mtasa.com/index.php? ... lientLevel)

setClientLevel Server-only function

That means function must be used in , no ?

Link to comment

This is an outdated function from a level system which was replaced with the current Access Control List system. Like all other deprecated functions, it was removed (hence setClientLevel is nil), just seems it wasn't removed from the documentation, which I will do now.

So, for player levels, you should be looking at ACL functions instead.

Link to comment
This is an outdated function from a level system which was replaced with the current Access Control List system. Like all other deprecated functions, it was removed (hence setClientLevel is nil), just seems it wasn't removed from the documentation, which I will do now.

So, for player levels, you should be looking at ACL functions instead.

Yes i found it but thanks.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...