Tweak code style

This commit is contained in:
lopezloo 2023-02-09 06:22:27 +01:00
parent 6b91137253
commit 56a6dddd70

6
ui.js
View File

@ -1,14 +1,16 @@
showInterface = true; showInterface = true;
autoRotateCamera = false; autoRotateCamera = false;
function hex2rgb(hex) { function
hex2rgb(hex) {
let r = parseInt(hex.slice(1, 3), 16); let r = parseInt(hex.slice(1, 3), 16);
let g = parseInt(hex.slice(3, 5), 16); let g = parseInt(hex.slice(3, 5), 16);
let b = parseInt(hex.slice(5, 7), 16); let b = parseInt(hex.slice(5, 7), 16);
return [r, g, b]; return [r, g, b];
} }
function updateVehicleCustomColors() { function
updateVehicleCustomColors() {
let colors = []; let colors = [];
for(let i = 0; i < 4; i++) { for(let i = 0; i < 4; i++) {
let cStr = document.getElementById("custom-color" + i).value; let cStr = document.getElementById("custom-color" + i).value;