mistakes Posted April 24, 2016 Posted April 24, 2016 Okay.. Here I come with this stupid problem .-. I Don't know how to make this to work with word not with ID .. I Wanna use player Name not player ID ... Please help, i'm new scripter.. local player t = tonumber(t) if not t then player = p else player = getPlayerByID(t) end if not player then return end
mistakes Posted April 24, 2016 Author Posted April 24, 2016 Yes.. I Try but it's doesn't work to change getPlayerByID with getPlayerFromName.. It's from ur lobby system..
Bonsai Posted April 24, 2016 Posted April 24, 2016 First of all "t = tonumber(t)" has to be removed then. Then you need a function to get the player from a part of his nick only, as having to typ the whole nick can be pretty annoying. https://wiki.multitheftauto.com/wiki/Ge ... omNamePart
mistakes Posted April 24, 2016 Author Posted April 24, 2016 Thank you @Bonsai. Now the code is: local player if not t then player = p else player = getPlayerFromPartialName(t) end if not player then return end and it's working fine.. I Added also the code from the link u gave me.. Thanks for you help.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now