[DMC] Posted October 23, 2010 Posted October 23, 2010 hey, i made 2 edits with name and text colors but how can i make it just HEX and not any text
CowTurbo Posted October 23, 2010 Posted October 23, 2010 what you mean ? maybe setPlayerNametagText .. ? http://mrteamgaming.eu
[DMC] Posted October 23, 2010 Author Posted October 23, 2010 no example , my name is DMC when i type in the edit and i type lolololol it wil make my name lololololdmc but i want just hex and nothing else so i only can type a hex code in there
dzek (varez) Posted October 23, 2010 Posted October 23, 2010 function isColorCode(str) if (string.find(str, "^#[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]$")) return true return false end function isContainingColorCode(str) if (string.find(str, "#[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]")) return true return false end function isBeginningWithColorCode(str) if (string.find(str, "^#[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]")) return true return false end examples: isColorCode("#ff00ff is cool color") -- false isColorCode("#ff0000") -- true isColorCode("i like this color: #00ff00") -- false isContainingColorCode("#ff00ff is cool color") -- true isContainingColorCode("#ff0000") -- true isContainingColorCode("i like this color: #00ff00") -- true isBeginningWithColorCode("#ff00ff is cool color") -- true isBeginningWithColorCode("#ff0000") -- true isBeginningWithColorCode("i like this color: #00ff00") -- false btw: i have written this thing, but not tested it Multi theft auto tools - replace cars and peds, move your map or compile your Lua files online! programista php rzeszów Need free webhosting for your small site? PM me. Need help with portforwarding? PM me. Do not PM me asking for help with scripting. Having problems with port forwarding? Send me pm, I can do whole thing for you using TeamViewer (already helped about 20 people, no worries)!
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