Re: JSON

Plug-in related stuff can be discussed here.

Moderator: Plugin Moderators

User avatar
Chinasapling
Townsman
Reactions:
Posts: 48
Joined: 11 Nov 2018, 05:33
Plugins: Showcase Store

Platform

Re: JSON

#1

Post by Chinasapling »

:json [
{
"id":"$decarbonatortower00",
"author":"Caliber",
"type":"park",
"width":1,
"height":1,
"influence pollution":-3000,
"influence noise":-3000,
"influence nature":3000,
"influence park":17,
"power": 0,
"water": 0,
"build time":0,
"needs road":true,
"category":"$cat_wastedisposal00",
"title":"Decarbonator Tower",
"text":"It removes too much carbon dioxide (CO2)and it also reduce too much noise in the city.",
"frames":[{"bmp":"Decarbonator Tower.png"}],
"id":"$garbagetrck00",
"type":"car",
"car spawner":[{"cars":["$garbagetrck00"],"count":10,"radius":500}],
"frames":[
{"x":640,"y":668,"w":17,"h":14},
{"x":657,"y":668,"w":18,"h":14},
{"x":675,"y":668,"w":18,"h":14},
{"x":693,"y":668,"w":17,"h":14}
],
"v2":[0,1,0,0],
"speed":0.9,
"flag military":true,
"flag airport":true,
"meta":{"tags":{"garbage":{}}}
}
]
Don't pay attention to copyright first. The question is why there is no building in the game. When I add a car, I can't find it.

User avatar
CommanderABab
AB
Reactions:
Posts: 11086
Joined: 07 Jun 2016, 21:12
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Re: JSON

#2

Post by CommanderABab »

The car spawner line should be in the code section for the building and not the car.

User avatar
CommanderABab
AB
Reactions:
Posts: 11086
Joined: 07 Jun 2016, 21:12
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: JSON

#3

Post by CommanderABab »

Chinasapling wrote:
13 Feb 2019, 09:48
:json [
{
"id":"$decarbonatortower00",
"author":"Caliber",
"type":"park",
"width":1,
"height":1,
"influence pollution":-3000,
"influence noise":-3000,
"influence nature":3000,
"influence park":17,
"power": 0,
"water": 0,
"build time":0,
"needs road":true,
"category":"$cat_wastedisposal00",
"title":"Decarbonator Tower",
"text":"It removes too much carbon dioxide (CO2)and it also reduce too much noise in the city.",
"frames":[{"bmp":"Decarbonator Tower.png"}],
"id":"$garbagetrck00",
"type":"car",
"car spawner":[{"cars":["$garbagetrck00"],"count":10,"radius":500}],
"frames":[
{"x":640,"y":668,"w":17,"h":14},
{"x":657,"y":668,"w":18,"h":14},
{"x":675,"y":668,"w":18,"h":14},
{"x":693,"y":668,"w":17,"h":14}
],
"v2":[0,1,0,0],
"speed":0.9,
"flag military":true,
"flag airport":true,
"meta":{"tags":{"garbage":{}}}
}
]
Don't pay attention to copyright first. The question is why there is no building in the game. When I add a car, I can't find it.

Code: Select all

[
	{
		"id":"$decarbonatortower00",
		"author":"Caliber",
		"type":"park",
		"width":1, 
		"height":1,
		"influence pollution":-3000,
		"influence noise":-3000,
		"influence nature":3000,
		"influence park":17,
		"power": 0,
		"water": 0,
		"build time":0,
		"needs road":true,
		"category":"$cat_wastedisposal00",
		"title":"Decarbonator Tower",
		"text":"It removes too much carbon dioxide (CO2)and it also reduce too much noise in the city.",
		"frames":[{"bmp":"Decarbonator Tower.png"}],
		"car spawner":[{"cars":["$garbagetrck00"],"count":10,"radius":500}]
		},
		{
		 "id":"$garbagetrck00",
    "type":"car",

    "frames":[
      {"x":640,"y":668,"w":17,"h":14},
      {"x":657,"y":668,"w":18,"h":14},
      {"x":675,"y":668,"w":18,"h":14},
      {"x":693,"y":668,"w":17,"h":14}
    ],
     "v2":[0,1,0,0],
    "speed":0.9,
    "flag military":true,
    "flag airport":true,
    "meta":{"tags":{"garbage":{}}}
	}
]
Let me refer you to cars documentation: https://theotown.com/forum/viewtopic.php?p=22167#p22167

User avatar
Chinasapling
Townsman
Reactions:
Posts: 48
Joined: 11 Nov 2018, 05:33
Plugins: Showcase Store

Platform

Re: Re: JSON

#4

Post by Chinasapling »

thank you very much

Post Reply Previous topicNext topic

Return to “Plug-In Discussion”