[Resolved] How can cars appear in buildings?
Posted: 13 Jan 2020, 07:20
Can anyone help me?
A feature rich city builder game for Android, iOS and PC
https://www.forum.theotown.com/
Code: Select all
{//optional , this one lights the entire vehicle at night. It is quite small.
"id": "$mycaranim",
"type": "animation",
"light":true,
"light switching":false,
"frames": [{
"bmp": "mycaranim.png",
"w": 13,
"h": 15,
"target w":6,
"target h":6,
"count": 4
}]
},
{
"id": "$mycar",
"type": "car",
"frames": [{//see documentation for vehicle graphics examples
"bmp": "mycar.png",
"w": 13,
"h": 15,
"target w":6,
"target h":6,
"count": 4
}],
"animation": [{ //optional
"id": "$mycaranim",
"pos": [0, 0, 0, 0, 0, 0, 0, 0] //array of xyxyxyxy positions for animation to appear on vehicle
}
],
"v2": [2, 2, 2, 2], //unsure, I think required by an update
"capacity": 11,
"speed": 1,
"flag normal": true, // flags of roads vehicle can use
"flag user2": true,
"meta": { //optional, special services vehicle may provide
"tags": {
"fire brigade": {},
"garbage": {}
}
}
},
Code: Select all
"car spawner": [{
"cars": ["$carid1" //,"$carid2" etc
],
"flags": ["fire brigade"], //if a vehicle has a special use then use this. Otherwise no.
"targets":["buildingid","orbuildingtype"], //array of building ids for vehicle to attempt to visit. (Can cause traffic problems)
"count": 2,
"radius": 4000 //this would go over the whole map. Use 5,10 or 20 to keep them near the building.
}]