Building on water?

Plug-in related stuff can be discussed here.

Moderator: Plugin Moderators

User avatar
mdk_813
Inhabitant of a Country
Reactions:
Posts: 857
Joined: 16 Dec 2016, 02:38
Location: Germany
Plugins: Showcase Store

Platform

Building on water?

#1

Post by mdk_813 »

Hi guys,
I would like to do some buildings, that can be placed on water, in a similar way to the small red buoys already in the game.
Is there a way to do that and what setting would I have to put into the json to make that work?

Thanks.

User avatar
Brody Craft
Inhabitant of a Infinity
Reactions:
Posts: 8034
Joined: 24 Jan 2017, 11:15
Location: SE Asia
Plugins: Showcase Store
Version: Beta

Platform

Re: Building on water?

#2

Post by Brody Craft »

Code: Select all

"needs water":"true",

User avatar
mdk_813
Inhabitant of a Country
Reactions:
Posts: 857
Joined: 16 Dec 2016, 02:38
Location: Germany
Plugins: Showcase Store

Platform

Re: Building on water?

#3

Post by mdk_813 »

Brody Craft wrote:
09 Jul 2017, 13:26

Code: Select all

"needs water":"true",
Yes, I made a small 1x1 test-bouy and it didn't seem to work. In building mode it did not turn green and was not placable.
However, I wrote it like that:

Code: Select all

"needs water":true,
May the missing " " be the problem?

User avatar
mdk_813
Inhabitant of a Country
Reactions:
Posts: 857
Joined: 16 Dec 2016, 02:38
Location: Germany
Plugins: Showcase Store

Platform

Re: Building on water?

#4

Post by mdk_813 »

former member wrote:
09 Jul 2017, 13:36
True and false are boolean, they don't need ".
Try

Code: Select all

"needs water":true,
"needs ground":false
I made a floating park before.
Ah ok, thanks, I didn't use "needs ground":false, in there. Maybe that was the problem?
I will try it out.

User avatar
mdk_813
Inhabitant of a Country
Reactions:
Posts: 857
Joined: 16 Dec 2016, 02:38
Location: Germany
Plugins: Showcase Store

Platform

Re: Building on water?

#5

Post by mdk_813 »

Hm, I can't get it to work.

I thought the transparency could be a problem, so I removed "draw ground" and put the original water texture from Lobby into the png. Didn't work either.
Currently, it looks like this:

Code: Select all

[
   {
      "id":"Testboje.mdk_813",
	  "type":"park",
	  "author":"mdk_813",
      "width":1,
	  "height":1,
	  "frames":[{"bmp":"Testboje_1x1.png"}],
	  "price":1,
	  "monthly price":1,
	  "water":"0",
	  "power":"0",
      "build time":0,
	  "needs road":false,
	  "needs water":true,
	  "needs ground":false,
	  "title":"Testboje",
	  "text":"Will it float?"
   }
]
Any ideas?
Attachments
Testboje_1x1.png
Testboje_1x1.png (3.23 KiB) Viewed 4512 times

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

Plugin Creator

Platform

Re: Building on water?

#6

Post by CommanderABab »

mdk_813 wrote:
09 Jul 2017, 15:40
Hm, I can't get it to work.

I thought the transparency could be a problem, so I removed "draw ground" and put the original water texture from Lobby into the png. Didn't work either.
Currently, it looks like this:

Code: Select all

[
   {
      "id":"Testboje.mdk_813",
	  "type":"park",
	  "author":"mdk_813",
      "width":1,
	  "height":1,
	  "frames":[{"bmp":"Testboje_1x1.png"}],
	  "price":1,
	  "monthly price":1,
	  "water":"0",
	  "power":"0",
      "build time":0,
	  "needs road":false,
	  "needs water":true,
	  "needs land":false,
	  "title":"Testboje",
	  "text":"Will it float?"
   }
]
Any ideas?
Try the one from the quote box.

User avatar
mdk_813
Inhabitant of a Country
Reactions:
Posts: 857
Joined: 16 Dec 2016, 02:38
Location: Germany
Plugins: Showcase Store

Platform

Re: Building on water?

#7

Post by mdk_813 »

Cool, thanks, now it builds on water, but the ground texture causes another problem: The game now builds these brownish foundations.
So, I guess I need to get rid of the ground texture in the png and put something like "draw ground" (or "draw water"?) into the json.

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

Plugin Creator

Platform

Re: Building on water?

#8

Post by CommanderABab »

CommanderABab wrote:
09 Jul 2017, 15:44
mdk_813 wrote:
09 Jul 2017, 15:40
Hm, I can't get it to work.

I thought the transparency could be a problem, so I removed "draw ground" and put the original water texture from Lobby into the png. Didn't work either.
Currently, it looks like this:

Code: Select all

[
   {
      "id":"Testboje.mdk_813",
	  "type":"park",
	  "author":"mdk_813",
      "width":1,
	  "height":1,
	  "frames":[
	   {
	    "bmp":"Testboje_1x1.png",
	    "handle y":4
	   }
	  ],
	  "price":1,
	  "monthly price":1,
	  "water":"0",
	  "power":"0",
      "build time":0,
	  "needs road":false,
	  "needs water":true,
	  "needs land":false,
	  "title":"Testboje",
	  "text":"Will it float?"
   }
]
Any ideas?
Try the one from the quote box.
Add your image's pixel height plus 4. (result = pixel height + 4). Replace the 4 after handle with the result.

User avatar
mdk_813
Inhabitant of a Country
Reactions:
Posts: 857
Joined: 16 Dec 2016, 02:38
Location: Germany
Plugins: Showcase Store

Platform

Re: Building on water?

#9

Post by mdk_813 »

Nice!
"needs land":false, and "draw ground":true, did the trick!

Thank you guys!
Attachments
Testboje_examples.png
Testboje_examples.png (248.73 KiB) Viewed 4502 times

User avatar
wcs
Small-town resident
Reactions:
Posts: 38
Joined: 16 Jun 2019, 08:21
Plugins: Showcase Store
Contact:

Re: Building on water?

#10

Post by wcs »

I am having the same problem. Is it possible to create a zone plugin that could be built in water?

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

Plugin Creator

Platform

Re: Building on water?

#11

Post by CommanderABab »


User avatar
yusuf8a684
Reactions:

Re: Building on water?

#12

Post by yusuf8a684 »

wcs wrote:
18 Jun 2019, 10:38
I am having the same problem. Is it possible to create a zone plugin that could be built in water?
I don't think sir

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

Plugin Creator

Platform

Re: Building on water?

#13

Post by CommanderABab »

https://theotown.com/forum/viewtopic.php?p=84430#p84430

Yes, it is possible to build such a building. Will it build by itself? No.

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

Plugin Creator

Platform

Re: Building on water?

#14

Post by CommanderABab »

No, you can't place just a zone itself on water.

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

Plugin Creator

Platform

Re: Building on water?

#15

Post by CommanderABab »

You can see from the video that I was once able to zone small sections of water, but it depended on a bug which was removed.

User avatar
wcs
Small-town resident
Reactions:
Posts: 38
Joined: 16 Jun 2019, 08:21
Plugins: Showcase Store
Contact:

Re: Building on water?

#16

Post by wcs »

I see, I was planning on adding floating slums in my plugin. I guess I would just have to add a water decal beneath it and just build land on water.

Post Reply Previous topicNext topic

Return to “Plug-In Discussion”