If you want your cars front and back light is always ON, like in vanilla models. You can use light animation code like this. its obtained from Theotown assets.
Code:
Select all Reset
"animation" : [
{
"id": "carlight_red",
"pos": [0, 0, 1, 10, 11, 11, 0, 0],
"frames": [1,2]
},
{
"id": "carlight_red",
"pos": [0, 0, 4, 11, 14, 10, 0, 0],
"frames": [1,2]
},
{
"id": "carlight_yellow",
"pos": [12, 11, 0, 0, 0, 0, 0, 8],
"frames": [0,3]
},
{
"id": "carlight_yellow",
"pos": [15, 10, 0, 0, 0, 0, 2, 9],
"frames": [0,3]
}]
And if you confused what pos mean, its for locating red & yellow light position precisely. Red light is for back of the cars, Yellow light is for front of the cars. I will add simple explanation like this :
The value from the "pos" is like coordinates and its depend on the car size and shape, so it will require many trial and error for finding right placement.
Hope it will help you someday.