JeViCo Posted February 9, 2018 Posted February 9, 2018 (edited) Hello everyone! How can i compare 2 different rgb car colors? I can't compare just doing (r,g,b) ~= (r2,g2,b2) Edited February 9, 2018 by Juuve
Moderators IIYAMA Posted February 9, 2018 Moderators Posted February 9, 2018 if r ~= r2 or g ~= g2 or b ~= b2 then -- not the same color end 1 Do you want to improve your Lua programming skills and make less mistakes? Start with Lua Language Server! Useful functions 3x Spoiler checkPassiveTimer getScreenStartPositionFromBox getPedGender Tutorials 4x Spoiler Scaling DX Events Attach an addEventHandler on a group of elements Debugging
Tekken Posted February 10, 2018 Posted February 10, 2018 You can only check for red cause if one of the 3 is different the color will be different. if r ~= r2 then --not the same collor end No need to check all 3 of 'em. Resources I made: attachToBones - A newer bone_attach. Simple Level system - Just a simple level system. Do not PM me for help with leaked scripts! I WILL NOT HELP YOU!
Moderators IIYAMA Posted February 10, 2018 Moderators Posted February 10, 2018 (edited) You can only check for red cause if one of the 3 is different the color will be different. No need to check all 3 of 'em. I do not agree with that. Colour 1: 255, 100, 50 Colour 2: 255, 70, 50 <- Edited February 10, 2018 by IIYAMA Do you want to improve your Lua programming skills and make less mistakes? Start with Lua Language Server! Useful functions 3x Spoiler checkPassiveTimer getScreenStartPositionFromBox getPedGender Tutorials 4x Spoiler Scaling DX Events Attach an addEventHandler on a group of elements Debugging
Tekken Posted February 11, 2018 Posted February 11, 2018 Oh yes I didn't thought of that. >_< 1 Resources I made: attachToBones - A newer bone_attach. Simple Level system - Just a simple level system. Do not PM me for help with leaked scripts! I WILL NOT HELP YOU!
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