The International Simutrans Forum

 

Author Topic: New industry placement type: Near City  (Read 15883 times)

0 Members and 1 Guest are viewing this topic.

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
New industry placement type: Near City
« on: July 16, 2012, 09:27:52 PM »
Land property are appropriate for farms, mines and forestry.
City property is appropriate for consumer.
Something between is missing.

I would like to see new property which places industry building some where near the city but not too far neither.
They will be ideal for any kind of factories. Just enough, or designate-able distance so more convenient to move workers in and appears more realistic.

Offline Fabio

  • Devotee
  • Administrator
  • *
  • Posts: 2898
  • The Pak128 Guy
    • Visit me on Facebook
  • Languages: EN, IT, RO, FR
Re: New industry placement type: Near City
« Reply #1 on: July 16, 2012, 09:56:16 PM »
I support the idea that beside natural resources (mines, quarries, forests, oil fields), farms (of any kind, including fishing ponds) and renewable energy power plants all industries should be located near cities instead of scattered in the countryside.
But what would near mean? city industries are already at the city outskirts, as this is the only free location when they are built.
I could think of them as just outside present city limits, but would this differ enough from city placement to justify a new location type?

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #2 on: July 16, 2012, 10:21:24 PM »
city industries are already at the city outskirts, as this is the only free location when they are built.
I'm afraid I was not clear. I mean industry chain factories. Not only it will be easier to build track between city and industry, also reduces the chance of rectangular factories do not appear.

Given now we have factory out put influenced by passenger and mail, it is very tire some to bring passenger to land placement factories. Closer they are to cities, there is more chance for include them in existing network.

Also visually, heavy industries are placed little further away from the city. Such as power station and refineries.

It will also facilitate building large freight station near the industry.
« Last Edit: July 16, 2012, 10:30:16 PM by colonyan »

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #3 on: July 16, 2012, 10:37:41 PM »


Uploaded with ImageShack.us
I hope this will clarify better what I mean.

Offline Fabio

  • Devotee
  • Administrator
  • *
  • Posts: 2898
  • The Pak128 Guy
    • Visit me on Facebook
  • Languages: EN, IT, RO, FR
Re: New industry placement type: Near City
« Reply #4 on: July 16, 2012, 11:32:56 PM »
So, near city industries would be within a reasonable radius from the city. I second that. Radius from city hall might be between city limits radius and its double. It seems very reasonable. It would be nice and better looking if these would be placed preferably near existing roads or waterways.

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #5 on: July 17, 2012, 01:04:59 AM »
It would be nice and better looking if these would be placed preferably near existing roads or waterways.
Ah. That is nice. Did not think of that.
One image tells hundreds of words.

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: New industry placement type: Near City
« Reply #6 on: July 17, 2012, 02:03:42 AM »
maybe an added parameter for industries, like 'minimum distance to city'?

From my observations, it seems that the more pollution the industry gives off, be it air, water or noise, the further away they are from the center of the city.

Offline IgorEliezer br

  • Devotee
  • Administrator
  • *
  • Posts: 4085
  • Cake recipes are cool... REALLY!
    • Igor Eliezer Architect and Urban Planner/Arquiteto e Urbanista
  • Languages: PT, EN, AutoLISP, Python
Re: New industry placement type: Near City
« Reply #7 on: July 17, 2012, 05:12:45 AM »
maybe an added parameter for industries, like 'minimum distance to city'?
I rather support it. I start maps with very small cities, but they become "packed" with end-consumer industries next to the townhalls.

Offline Fabio

  • Devotee
  • Administrator
  • *
  • Posts: 2898
  • The Pak128 Guy
    • Visit me on Facebook
  • Languages: EN, IT, RO, FR
Re: New industry placement type: Near City
« Reply #8 on: July 17, 2012, 06:13:48 AM »
Colonyan's request (and mine as well) would be rather maximum distance from city centre. Actually I rather dislike to see factories scattered all over the countryside.

Offline dom700

  • *
  • Posts: 44
Re: New industry placement type: Near City
« Reply #9 on: July 17, 2012, 08:00:11 AM »
I am wondering what is wrong with the current system. In my games the factories are fairly close to a town, maybe it is because I have set the minimum space between factories to 1.

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #10 on: July 17, 2012, 10:15:01 AM »
If there are fairy many cities against map size, some to many of factories stands close to city. But some will still stand far away in no mans land.  I think it also has to do with from the fact that consumer is usually designated to stand in city too. Factories tries to get near it according to range it is told to be placed. That is my guess.

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: New industry placement type: Near City
« Reply #11 on: July 18, 2012, 07:22:13 AM »
Colonyan's request (and mine as well) would be rather maximum distance from city centre. Actually I rather dislike to see factories scattered all over the countryside.

ah, okay, I see.
Then maybe add a maximum, on top of a minimum, or just have an 'ideal' distance.

I am wondering what is wrong with the current system. In my games the factories are fairly close to a town, maybe it is because I have set the minimum space between factories to 1.
The trouble with the current system is that it can place a farm inside a city or it can place a shop in the middle of nowhere.
The former happens when there are multiple large cities that are in close proximity to each other. I'm not entirely sure how the later happens, but it seems to occur when there is already a shop inside a city. The new shop tries to open up in it, and gets bounced outside to whatever the minimum spacing is set to. That's even if the two shops have no relation to each other.

Offline Roads

  • Devotees (Inactive)
  • *
  • Posts: 645
Re: New industry placement type: Near City
« Reply #12 on: July 19, 2012, 04:09:36 PM »
Here are some of the reasons I never play the standard game.  To me, there is only one way to really fix all this and that is a systematic approach.

This begins with random natural resources placed on the map according to where they would naturally be found.  Then of course cities are added because, just as in real life, people move to areas where there are natural resources or fertile land.  Then the factories...

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5523
  • Languages: EN, NO
Re: New industry placement type: Near City
« Reply #13 on: July 19, 2012, 05:03:24 PM »
Then of course cities are added because, just as in real life, people move to areas where there are natural resources or fertile land.

However the biggest cities seem to be located at strategic locations that aren't particularly rich in natural resources. And I think the "factories" are established at the same time as, if not before, the settlement, though for settlements predating the industrial revolution, the industry started out too small scale for transport simulation.

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: New industry placement type: Near City
« Reply #14 on: July 19, 2012, 08:48:46 PM »
However the biggest cities seem to be located at strategic locations that aren't particularly rich in natural resources. And I think the "factories" are established at the same time as, if not before, the settlement, though for settlements predating the industrial revolution, the industry started out too small scale for transport simulation.

I think there are 3 types of settlements.
1 - City built near large body of water. Placement is due to abundance of food, drinking water and ease of trade via ships. These tend to be the largest cities in the world.
2 - City built along trade route. Obviously, for the safety of travelers on long journeys. May have been a fort in the past.
3 - Town built near resource or construction project. Cheaper to have workers live closer to the place they work. These tend to grow when the industry is booming, but may also die completely when the industry closes down. These, usually, never grow very large.

There might be more types, but that's the best I can think of. Food and water abundance governs maximum city size and commerce level governs how quickly a city can grow.

Offline Fabio

  • Devotee
  • Administrator
  • *
  • Posts: 2898
  • The Pak128 Guy
    • Visit me on Facebook
  • Languages: EN, IT, RO, FR
Re: New industry placement type: Near City
« Reply #15 on: July 19, 2012, 09:32:38 PM »
Awesome explanation. How to translate it in game terms?

1) city builder could detect bodies of water or rivers, as well as farming planes.

2) trickier, but after cities of type 1 and 3 are built, roads might be used to determine placement of these commercial hubs.

3) the trickiest given Simutrans structure. Maybe with per tile climate some areas can be associate with a specific resource and both industries and settlements can use those locations.

This might need more thoughts, but it's the way to have more realistic maps and better player challenge.

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #16 on: July 19, 2012, 09:59:09 PM »
I thought after reply #11 and #12, course of discussion seemed to go to other direction but I see all relate each other.
Also there might be a room to explore to increase believe-ability of cities placement for realism pursuers too.
Lets see now...

ADD: There's also this issue where "ideal" near city factory placement distance may become adapt to actual city size since cities grows in area.

Offline ӔO

  • Devotees (Inactive)
  • *
  • Posts: 2345
  • Hopefully helpful
  • Languages: en, jp
Re: New industry placement type: Near City
« Reply #17 on: July 19, 2012, 10:07:15 PM »
I thought after reply #11 and #12, course of discussion seemed to go to other direction but I see all relate each other.
Also there might be a room to explore to increase believe-ability of cities placement for realism pursuers too.
Lets see now...

ADD: There's also this issue where "ideal" near city factory placement distance may become adapt to actual city size since cities grows in area.

Perhaps count from the edge of the city border?
a value of zero can mean somewhere inside the city border, while one or higher would be outside of the city.
The only downside I can see is the industry being placed near a corner, which might be desolate compared to a single side.

Awesome explanation. How to translate it in game terms?

1) city builder could detect bodies of water or rivers, as well as farming planes.

2) trickier, but after cities of type 1 and 3 are built, roads might be used to determine placement of these commercial hubs.

3) the trickiest given Simutrans structure. Maybe with per tile climate some areas can be associate with a specific resource and both industries and settlements can use those locations.

This might need more thoughts, but it's the way to have more realistic maps and better player challenge.

Maybe add a value like 'land fertility' depending on climate and proximity to water?
I'm not entirely sure how one can dictate which cities grow faster than others through commerce in game.
« Last Edit: July 19, 2012, 10:14:49 PM by ӔO »

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #18 on: July 19, 2012, 10:21:36 PM »
Until industrial revolution, rise of life expectancy, lowering of infant mortality and invention of cheap chemical fertilizer (such as Haber–Bosch process), fertile land housed larger population. There were not much difference in term of population scattering. People live evenly everywhere. Unless there's good access of water. Ships had far more transportation capacity than land ones until railraoad and trucks become available. Edo in Japan had 1M pop and collecting food by ships around the main island.

As food gets cheaper, medical treatment and mass transportation becomes available, major cities gathered surplus population from country side all around as newly risen industries required many workers.


OK. This is little bit of setting.
So I think other than availability of fertile land and placement of water body or river, cities with large growth potentials should have good reason to attract population to settle.

Reasons could be
1. Where ruler is. Capital. All the fine goods and cultures accumulate and matures through out the time.
2. where regional capitals are. little bit like 1. but in smaller degree.
3. where different rulers made it capital once back in time. They have lost its glory but still has its consistency. those are old capitals.
4.where place is fertile. Traditionally farming village and grown to town.
5. where towns and cities which had there specialties traditionally. alcohol, fine handcrafts, clothings
6. towns in region where additive value farm crops were made traditionally. fruits, tea, spices etc
7. where good amount of water flows constantly. for early industries
8. where important mines are.
9. where religious facility existed since long time and gathered peoples faith over time and become famous.
10. where tourist attraction has become into small town. hot spring, beautiful sights, historical site.
10 is little redundant with 9. 

Thus cities could be attributed with above tags. or if possible combination of two. further detailed with different degree.
As map is generated, all cities will have reason why they are there.

__________
add: Category 1,2,3 could require tag 4 as prerequisite.
__________

Those will give general guidance for where to place chain industries and different attractions, land or in cities.

Additionally, game could present an event where capital change occur during game time line.
Not necessary this will attract most of the growth. example. ottawa, washington, canberra
(was washington always capital? anyways)

Important thing is that growth will be once collected in one THEN distributed depending on how much different cities are more attractive.
« Last Edit: July 19, 2012, 11:21:40 PM by colonyan »

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #19 on: July 19, 2012, 10:52:16 PM »
Quote
AEO:
Perhaps count from the edge of the city border?
a value of zero can mean somewhere inside the city border, while one or higher would be outside of the city.
The only downside I can see is the industry being placed near a corner, which might be desolate compared to a single side.
Nice idea. Even though it might placed in edge, its fine. City road should be near and connection should still be easy.
« Last Edit: July 19, 2012, 11:05:56 PM by colonyan »

Offline Fabio

  • Devotee
  • Administrator
  • *
  • Posts: 2898
  • The Pak128 Guy
    • Visit me on Facebook
  • Languages: EN, IT, RO, FR
Re: New industry placement type: Near City
« Reply #20 on: July 19, 2012, 11:23:20 PM »
Talking of cities, the topic can be split in 2 different issues:

1) City location: where to place most of settlements on the map; and

2) City growth: which city should grow more/faster.

Keep in mind that all (realistic) paksets have a playability starting at the earliest with the industrial revolution (late XVIII - early XIX century). Pre-industrial age has however a legacy effect since cities are started much earlier and then grown till they reach the chosen start year. The earlier a city is built, the bigger it grows. When the game is running, city growth is given by pax transport.

1) city location is the most interesting area to develop. Cities could be divided into
- rural
- commercial
- natural resources
- industrial
These types could be coded into the townhall dat.

Rural cities are built in plains, maybe restricted to temperate, Mediterranean and tropical climates. All farms and agricultural industries are built around rural cities.

Commercial cities are built near the shore, rivers or near existing river crossings and crossroads.

Natural resources cities are hard to place on the map. But playing with townhall climates and industry climates we could get interesting results. Natural resources industries will be built near these cities.

Industrial cities: they can also merge with commercial cities. All non-resources and non-agricultural factories are places near or within an industrial city.

Consumers are instead spread in any kind of city.

2) city growth.
Cities should be built at first where a river meets the sea, or where two larger rivers meet. These will grow the most. 1/3 of cities should be built this way and will be the regional Capitols. Possibly, these should be spread on the map as far from one another as it is possible.

Then cities must be built in other locations, maybe "spreading" from the first cities at reasonable distance.

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #21 on: July 19, 2012, 11:52:00 PM »
I like commercial cities placed near exiting road intersection and navigate able water path.
I assume they will have larger percentage of commercial city building.
___

In attempt to summarize.
1. Alternating growth rule depending of the attributed nature of the city. Currently, 3 size of the city only changes the growth rule. Larger they are faster they grow.
2. Cities could be attributed with different natures depending on its geographic location and arbitrary assignation.
3. Fixed natural resource deposit locations. Mainly mines.
In order to
A. prevent land placement type industries to be present on unnatural looking locations.
B. to give more alternating playing experience.
C. to more systematically relate, structure and place map items (cities, industries and attractions).
___

From point1.
Continue using currently used city categorization based on population, village, town, city. There are 3 types of growth level for each category. Thus it is possible to expect 9 types of possibilities.

Few extreme examples.
1) village class growing with city class growth rule (very fast growth, explosion)C3
2) city class growing with village class growth rule (stagnation)A1
___

village:C 
town:B
city:A

almost stagnation growth rule:0 (to have stagnating villages and towns)
village growth rule:1
town growth rule:2
city growth rule:3

C0    C1   C2   C3
B0    B1   B2    B3
A0    A1   A2    A3

C1, B2 and A3 will be the currently applied rules.
More sophisticated ones maybe of course possible. Such as making it more linear scaling.
« Last Edit: July 20, 2012, 12:13:23 AM by colonyan »

Offline Roads

  • Devotees (Inactive)
  • *
  • Posts: 645
Re: New industry placement type: Near City
« Reply #22 on: July 20, 2012, 03:39:34 AM »
Very thoughtful stuff here and I hope at least some of it will be implemented.  One thing I want to add.  Currently the version of pak128 I'm playing, I think it is from November of last year, is disappointing when it comes to city growth.  The best I can determine city growth has absolutely nothing to do with anything realistic but seems rather based on some algorithm which makes transport of passengers and mail the most difficult it can possibly be.

For example, the first city I built which is pretty close to the center of the map and requires almost all traffic east and west to travel through it is one of the smallest cities on the map.  This is directly contrary to what happens in real life.  As has already been pointed out, some of the largest cities in the world grew because of no other reason than it was an ideal stop on a trade or travel route - Singapore for example.

It seems simple enough to have, as one parameter,  the game grow a city based on the number of passengers, mail and cargo that passes through it.  Heck, I would be thrilled if it only considered passengers...

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #23 on: July 20, 2012, 04:14:35 AM »
Very thoughtful stuff here and I hope at least some of it will be implemented.  One thing I want to add.  Currently the version of pak128 I'm playing, I think it is from November of last year, is disappointing when it comes to city growth.  The best I can determine city growth has absolutely nothing to do with anything realistic but seems rather based on some algorithm which makes transport of passengers and mail the most difficult it can possibly be.

For example, the first city I built which is pretty close to the center of the map and requires almost all traffic east and west to travel through it is one of the smallest cities on the map.  This is directly contrary to what happens in real life.  As has already been pointed out, some of the largest cities in the world grew because of no other reason than it was an ideal stop on a trade or travel route - Singapore for example.

It seems simple enough to have, as one parameter,  the game grow a city based on the number of passengers, mail and cargo that passes through it.  Heck, I would be thrilled if it only considered passengers...
I see your point. From the fact that a location has good access to many already existing key locations should become a point of interest. I can think of some kind of logistic center or residential development if it has good access to many different industry and business employers. Can not think right now how to do this in game.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5523
  • Languages: EN, NO
Re: New industry placement type: Near City
« Reply #24 on: July 20, 2012, 05:04:07 AM »
Another aspect that I don't see mentioned is a distinction between two types of "factories": Those that spawn settlements, and those that are spawned by settlements. Settlement spawning factories within the playable timeline of Simutrans are primarily mines and oil fields. These should appear anywhere, but if they are far enough away, they will also spawn a new town.

The settlement spawned factories can further be divided into two: small ones that appear within the city, and large ones that appear on the edge of cities. The former would almost exclusively be the end of a chain, while the latter can be both ends of chains (supermarkets and wholesales) or intermediate factories. Intermediate industries can appear either near it's raw materials, near where there is demand for it's products, or at strategically placed settlements.

Farms are somewhat special. They used to spawn settlements, but that was before the playable timeline. In theory, they could be anywhere in a suitable climate, perhaps with a greater concentration near what Fabio calls rural settlements, but virtually never in a city. The latter will require support in Simutrans for industries that close down.

And while on the topic of industries: When a growing city engulfs a factory, that factory should affect what kind of city buildings appear arround it, it it doesn't already. Perhaps the type of city building nearby would affect placement of factories on the edge of cities also.
 
So many ideas...

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: New industry placement type: Near City
« Reply #25 on: July 20, 2012, 08:09:30 AM »
For industries affecting buildings nearby in cities I suggest a pollution parameter - low values favour commercial, high, industrial.


For city and industry placement, how complicated should you go (there have been discussions in the past on this). Water, fertile land and natural resources placement must also be considered:

Water availability is down to climate and geology. You can be next to the sea or on a island with little access to fresh water, and climate and geology can cause rivers to evapourate before they reach the sea. Springs may be available nearby if the ground water level is high enough - this in turn can depend on the rainfall not only nearby but in other tiles which feed the same aquifer. Geology will be discussed below, climate depends on latitude, nearby large bodies of water and prevailing winds.

Fertile land is determined by soil type, climate and rainfall. Soil type is also affected by climate, and also by geology of the underlying rocks, as well as recent (last 20 thousand years) past climate -glacial activity in the past may result in thinner less fertile soils now.

Natural resource are determined mostly by geology. Oil and gas are often found in basins (which may be flooded). Distribution of coal and rock is dependent on past (up to 1000 million years) climate. Previously a desert will mean sandstone, previously underwater will mean chalk, limestone or mudstone (also possibility of oil). Swamps give rise to coal. Geological activity in the intervening period will bury (or erode) these rocks - if we are near a tectonic plate collision then rocks are likely to be folded, resulting in linear patterns parallel to the collision. If we are at the collision point there will be mountains (but these may have since been eroded).



Why do I detail the above - simply because if you do not consider these then distribution of water (including rivers), fertile land and natural resources (and also the heightmap) will be random. If you do you are proposing map generation to include a simulation of the area from the formation of the earth to present. If they are random then they will not affect city distribution in a realistic way. If they don't affect city distribution in a realistic way why bother to include them at all?

Simulation games focus on one aspect (in simutrans case, transport). Imagination is required when playing them to fill in areas which are outside the scope of the simulation. Exactly what is outside the scope of the simulation is a matter of performance and programmer time!

Offline Roads

  • Devotees (Inactive)
  • *
  • Posts: 645
Re: New industry placement type: Near City
« Reply #26 on: July 20, 2012, 10:12:50 AM »
@kierongreen

As logical as your argument is, I will argue it is better to light one candle than curse the darkness.  The effect of rainfall and why resources formed where they are is not as necessary for the game to be believable as not having a coal power plant next to city hall or a cotton farm next to a sky scraper.  These things are challenging for the most adept RP'er.

At any rate, why not begin a list of things that are within the realm of possibility?

Offline VS

  • Senior Plumber (Devotee)
  • Devotee
  • *
  • Posts: 4855
  • Vladimír Slávik
    • VS's Simutrans site
  • Languages: CS,EN
Re: New industry placement type: Near City
« Reply #27 on: July 20, 2012, 10:40:12 AM »
Perhaps grouping industries spatially could give some good results. Simply make coal mines look for other coal mines when spawning, with 60% weight etc. This could result in believable areas with similar resources, although still somewhat random. Or not. A full-fledged simulation of geological processes is out of question, IMHO :D

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: New industry placement type: Near City
« Reply #28 on: July 20, 2012, 11:03:33 AM »
If you are just going to randomly distribute rainfall, rivers and resources then to base a whole load of coplex distribution on them is not going to improve matters from what we have at the moment. At present you can just imagine coalfields under coal mines, cities being surrounded by fertile land and so on. Calculating and storing values for these adds nothing except for possibly a few pretty map overlays to display. However I admit that for maps based on real life they would allow for a realistic semi random placement of industries and settlements. Actually in the past heavy industry and power plants were located in built up areas.

Offline colonyan

  • Devotee
  • *
  • Posts: 526
  • Full and Warm
Re: New industry placement type: Near City
« Reply #29 on: July 20, 2012, 11:19:55 AM »
Perhaps grouping industries spatially could give some good results. Simply make coal mines look for other coal mines when spawning, with 60% weight etc. This could result in believable areas with similar resources, although still somewhat random. Or not. ...
Ah this sounds simple enough.


ah, okay, I see.
Then maybe add a maximum, on top of a minimum, or just have an 'ideal' distance.
The trouble with the current system is that it can place a farm inside a city or it can place a shop in the middle of nowhere.
The former happens when there are multiple large cities that are in close proximity to each other. I'm not entirely sure how the later happens, but it seems to occur when there is already a shop inside a city. The new shop tries to open up in it, and gets bounced outside to whatever the minimum spacing is set to. That's even if the two shops have no relation to each other.
How about if end consumers are exlcuded from minimum distance? At some point, I want to make so some end consumer stand very close to each other to create a busy truck road traffic.
The problem will be how to taking care which depot cover which consumer due to short distance between them.
« Last Edit: July 20, 2012, 11:33:15 AM by colonyan »

Offline Fabio

  • Devotee
  • Administrator
  • *
  • Posts: 2898
  • The Pak128 Guy
    • Visit me on Facebook
  • Languages: EN, IT, RO, FR
Re: New industry placement type: Near City
« Reply #30 on: July 20, 2012, 01:53:41 PM »
Map creation is the single game task for which performance is not crucial, as you do it only once in a while.
Usually you create more than one map at once if you don't like the result of the first attempt, so a better map albeit slower would be an improvement.

IMHO city placement would be the most needed improvement, as there are maps with large plains with no settlements and most settlements on the roughest areas.
A map with cities located according to the landscape features would be a welcome improvement.

Offline dom700

  • *
  • Posts: 44
Re: New industry placement type: Near City
« Reply #31 on: July 20, 2012, 02:01:33 PM »
I agree that it should be worked on, and I think that both Industry placement and city placement belong together in this discussion. I think it would be a good idea to base the growth of a city on the number of people and goods, which pass through station bearing the name of the city. Shortly after the introduction of the railway, many formerly small villages expanded, either because they suddenly became a major hub, or just because there was demand for workers.
I also think that Sim-Ex is running some advanced city placement code, which not only places cities and surrounding villages, but also tries to place the biggest cities next to rivers.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9513
  • Languages: De,EN,JP
Re: New industry placement type: Near City
« Reply #32 on: July 20, 2012, 06:29:01 PM »
Industry placement is very crucial performancewise, as during the growth of a new industry on a large map the game may get unresponsive for 30s or more.

Offline greenling

  • Lounger
  • *
  • Posts: 1728
  • Simutransarchology it my hobby!
  • Languages: DE,EN
Re: New industry placement type: Near City
« Reply #33 on: July 20, 2012, 06:48:50 PM »
Prissi the blocking from pm it a pamness.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5523
  • Languages: EN, NO
Re: New industry placement type: Near City
« Reply #34 on: July 20, 2012, 07:16:05 PM »
What does it spend time on? If the number of possible locations become restricted, wouldn't it be able to quickly reject most of the map?

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9513
  • Languages: De,EN,JP
Re: New industry placement type: Near City
« Reply #35 on: July 20, 2012, 07:20:04 PM »
Indeed, clustering the industries may help. Because the search for a suitable climate on 16 millions tiles with 10ms per tile will take 160s on a 4000x4000 map ... not to mention that many factories have further restrictions. If this is always restricted to (lets say) a 256x256 area around other factories of the same type, then it could be speeded up. However, then it would only give one cluster per type. Hence further refinedment if this is still needed.

Offline dom700

  • *
  • Posts: 44
Re: New industry placement type: Near City
« Reply #36 on: July 20, 2012, 07:54:54 PM »
Hmmm, the placement time for industries is already quite bad. I had a pak128 game place a new supermarket industry chain on a 3000x3000 map, and the 50 new industries took quite a bit. Therefore this doesn't really sound like an issue to me.
Why does it necessarily have to check all tiles on the map?

As an example here is, how I imagine a new supermarket (only breweries) chain would be made with the new system: (Note: Pak128 chain)

1. It would place the supermarket, most likely in the city which is expanding (no big deal)
2. It would place the breweries, probably also in the same city, or also checking cities in a given distance, which is expanding if no suitable city is found
3. It would place the grain farms, first checking the immediate vicinity of the breweries for suitable (fertile climate) tiles, and then expanding (probably checking 100x100 tiles at the very most for a "normal" map)
4. It would place the coal and glass mines, checking for suitable mining locations, afterwards placing the glass factory somewhere in the center of the mining area). To check for these mining locations, I would probably roughly check a larger area than the grain farms, but with a lower resolutions, like every 5th tile in a 250x250 area or so.

Personally I do not like the cluster idea at all. I do not want to have a 3000x3000 map, which has all coal mines in one corner of that map. That would make playing sickening.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5523
  • Languages: EN, NO
Re: New industry placement type: Near City
« Reply #37 on: July 20, 2012, 10:05:17 PM »
Does it really take 10ms per tile just to check the climate? I would have expected that 10ms would include checking if all tiles are free and can be leveled.

And on a 3000x3000 map, there should, in my opinion, be several coal mine hot spots scattered across the map, but probably no more than 10.

Offline wlindley us

  • Devotee
  • *
  • Posts: 970
    • Hacking for fun and profit since 1977
  • Languages: EN, DE
Re: New industry placement type: Near City
« Reply #38 on: July 21, 2012, 02:02:51 PM »
Perhaps a factory's .dat file could support the type= parameter.  Factories (e.g., newspaper stands) with type=res would only be built in proximity to a sufficient number of residential tiles, for example; a factory with type=ind (e.g., textile mill) would be built only near industrial buildings, and so on.  A factory would then attract nearby construction of buildings of that type.

Perhaps this could even support a factory with type=tow (town hall), which would restrict its construction to being near a city center, or type=harbour to have it built only near a waterfront station?

Offline isidoro

  • Devotee
  • *
  • Posts: 1129
Re: New industry placement type: Near City
« Reply #39 on: July 21, 2012, 09:57:12 PM »
Nice idea!  I like it!

Offline IgorEliezer br

  • Devotee
  • Administrator
  • *
  • Posts: 4085
  • Cake recipes are cool... REALLY!
    • Igor Eliezer Architect and Urban Planner/Arquiteto e Urbanista
  • Languages: PT, EN, AutoLISP, Python
Re: New industry placement type: Near City
« Reply #40 on: September 01, 2012, 06:51:50 PM »
Since the topic *had* derailed a bit (not derailed, but the subject expanded a bit), I thought I should have split it. Doing it now.

Topic split: A new geography for Simutrans: terrain, climate, towns, factories and stuff