Group Spawning for Decorations (Suggestion)

Plug-in related stuff can be discussed here.

Moderator: Plugin Moderators

User avatar
KINGTUT10101
1,000,000 inhabitants
Reactions:
Posts: 2220
Joined: 07 Jul 2016, 22:50
Location: 'Merica
Plugins: Showcase Store
Version: Beta
Contact:

Plugin Creator

Platform

Group Spawning for Decorations (Suggestion)

#1

Post by KINGTUT10101 »

I would like to suggest some new things for the decoration spawning feature. The current system works fine, but it could be better. What I am suggesting are more option to define how our decorations spawn, such as the ability to space them out or spawn them in clusters.

Here is some example code:

Code: Select all

[
	{
		"author":"Kingtut101",
		"drawground":true,
		"framealignmentarea":false,
		"frames":[
			{
				"count":4,
				"steal":"$searocks00",
				"w":32
			}
		],
		"height":1,
		"hidden":false,
		"id":"rockbig.kt101",
		"price":100,
		"pricefactor":0,
		"spawn":{
			"density":10,
			"group":[
				"rockbig.kt101",
				"rocksmall.kt101"
			],
			"height":500,
			"p":0.03,
			"radius":1000,
			"size":25,
			"space":50
		},
		"title":"Rocks",
		"type":"decoration",
		"width":1
	},
	{
		"author":"Kingtut101",
		"drawground":true,
		"framealignmentarea":false,
		"frames":[
			{
				"count":4,
				"steal":"$searocks00",
				"w":32
			}
		],
		"height":1,
		"hidden":false,
		"id":"rocksmall.kt101",
		"price":100,
		"pricefactor":0,
		"title":"Rocks",
		"type":"decoration",
		"width":1
	}
]
If these suggestions were added here's what this json would do. It would spawn these two rocks in large, un-dense clusters and these clusters of rocks would be significantly spaced out from one another. Here is what it could look like:
Screenshot_20180714-220537.png
(The pink border is just there to help you visualize the size of the clusters)
In order to have large spread out clusters of rocks where the clusters also spawn far away from one another you would need high numerical values for size, space, and density. For comparison, this is what it would look like if these values were much lower:

Code: Select all

[
	{
		"author":"Kingtut101",
		"drawground":true,
		"framealignmentarea":false,
		"frames":[
			{
				"count":4,
				"steal":"$searocks00",
				"w":32
			}
		],
		"height":1,
		"hidden":false,
		"id":"rockbig.kt101",
		"price":100,
		"pricefactor":0,
		"spawn":{
			"density":2,
			"group":[
				"rockbig.kt101",
				"rocksmall.kt101"
			],
			"height":500,
			"p":0.03,
			"radius":1000,
			"size":5,
			"space":10
		},
		"title":"Rocks",
		"type":"decoration",
		"width":1
	},
	{
		"author":"Kingtut101",
		"drawground":true,
		"framealignmentarea":false,
		"frames":[
			{
				"count":4,
				"steal":"$searocks00",
				"w":32
			}
		],
		"height":1,
		"hidden":false,
		"id":"rocksmall.kt101",
		"price":100,
		"pricefactor":0,
		"title":"Rocks",
		"type":"decoration",
		"width":1
	}
]
Screenshot_20180714-221603.png
As you can see, when these values are lowered they make smaller, denser clusters that spawn much more closely to one another.

User avatar
KINGTUT10101
1,000,000 inhabitants
Reactions:
Posts: 2220
Joined: 07 Jul 2016, 22:50
Location: 'Merica
Plugins: Showcase Store
Version: Beta
Contact:

Plugin Creator

Platform

Re: Group Spawning for Decorations (Suggestion)

#2

Post by KINGTUT10101 »

Here I'll explain what each of these new values would be in greater detail.

SIZE:
This determines the maximum size a cluster can be. Imagine this as that pink border around the clusters in the previous images. The higher the value, the bigger the circle, which means more decorations will be able to spawn.

SPACE:
This will determine the minimum distance in between each cluster. This can be used to spread them out and to keep them from clumping up. The higher the value, the farther away each cluster will be from one another.

DENSITY:
This will determine how densly the decorations inside the cluster will spawn. A higher density means that more decorations will be able to spawn within the cluster. A density of zero will cause the decorations to spawn directly next to one another within their cluster.

GROUP:
This will be used to list the IDs of the other plug-ins that will spawn in the cluster. This can be used to allow more than one decoration to spawn within the same cluster. If this part is not provided in the code, then it will only spawn the building that the code is part of. For example, if the group code wasn't added to any of the example code above this plug-in would only spawn rockbig.kt101.

One last thing I'd like to suggest is the value "everywhere": true. When this is true, the decoration will be able to spawn anywhere on the map, disregarding the radius or height. Using this could allow a decoration to more thoroughly cover large maps, for example.
Last edited by KINGTUT10101 on 15 Jul 2018, 16:37, edited 3 times in total.

User avatar
KINGTUT10101
1,000,000 inhabitants
Reactions:
Posts: 2220
Joined: 07 Jul 2016, 22:50
Location: 'Merica
Plugins: Showcase Store
Version: Beta
Contact:

Plugin Creator

Platform

Re: Group Spawning for Decorations (Suggestion)

#3

Post by KINGTUT10101 »

In conclusion, I hope that these will be added because I believe the functionality that they provide is something that is desperately needed for the current spawning system. Adding these new values would allow plug-in creators to be more specific with how their decorations spawn and allow them to create things like small, naturally spawning villages to map generation without them looking cluttered or having them spawn too spread out. However, that's just one way this could be used and I'm sure that the plug-in creators of this community could come up with many more great ideas.

User avatar
JustAnyone
Developer
Reactions:
Posts: 3474
Joined: 23 Jul 2017, 12:45
Location: Easter Island
Plugins: Showcase Store

Platform

Re: Group Spawning for Decorations (Suggestion)

#4

Post by JustAnyone »

It is possible with fun and new rnd action, but I like this.

User avatar
KINGTUT10101
1,000,000 inhabitants
Reactions:
Posts: 2220
Joined: 07 Jul 2016, 22:50
Location: 'Merica
Plugins: Showcase Store
Version: Beta
Contact:

Plugin Creator

Platform

Re: Group Spawning for Decorations (Suggestion)

#5

Post by KINGTUT10101 »

JustAnyone wrote:
15 Jul 2018, 15:51
It is possible with fun and new rnd action, but I like this.
That may be true, but this would be easier and more convenient.

User avatar
KINGTUT10101
1,000,000 inhabitants
Reactions:
Posts: 2220
Joined: 07 Jul 2016, 22:50
Location: 'Merica
Plugins: Showcase Store
Version: Beta
Contact:

Plugin Creator

Platform

Re: Group Spawning for Decorations (Suggestion)

#6

Post by KINGTUT10101 »

former member wrote:
15 Jul 2018, 09:58
Yes! We need this!!!
I wanted to make a plugin with villages that generate randomly on the map, I tried to make it with fun but didn't work that great. What you suggested would be perfect! I really hope this becomes a thing.
Lol I was actually going to make a village plug-in as well if this were added.

User avatar
JustAnyone
Developer
Reactions:
Posts: 3474
Joined: 23 Jul 2017, 12:45
Location: Easter Island
Plugins: Showcase Store

Platform

Re: Group Spawning for Decorations (Suggestion)

#7

Post by JustAnyone »

I was already working on city builder AI

User avatar
yusuf8a684
Reactions:

Re: Group Spawning for Decorations (Suggestion)

#8

Post by yusuf8a684 »

Yeah, villages can be cool ;)

User avatar
KINGTUT10101
1,000,000 inhabitants
Reactions:
Posts: 2220
Joined: 07 Jul 2016, 22:50
Location: 'Merica
Plugins: Showcase Store
Version: Beta
Contact:

Plugin Creator

Platform

Re: Group Spawning for Decorations (Suggestion)

#9

Post by KINGTUT10101 »

JustAnyone wrote:
15 Jul 2018, 17:46
I was already working on city builder AI
This would be completely different. This would just be a small decorative village.

User avatar
JustAnyone
Developer
Reactions:
Posts: 3474
Joined: 23 Jul 2017, 12:45
Location: Easter Island
Plugins: Showcase Store

Platform

Re: Group Spawning for Decorations (Suggestion)

#10

Post by JustAnyone »

I am doing that also.

Post Reply Previous topicNext topic

Return to “Plug-In Discussion”