New map features
Moderator: OpenTTD Developers
Re: New map features
As much as it'd be better to solely use newgrf properties, as this feature would only exist in non-trunk versions, it seems unrealistic to expect any significant subset of past or future newgrf authors to choose to implement it. Having some sort of fallback such as allowing bridges over roofless stations is probably necessary for the feature to be of practical use with newgrf stations.
Ex TTDPatch Coder
Patch Pack, Github
Patch Pack, Github
Re: New map features
i think adding this property should have been done years ago, so NewGRF authors could have had time to prepare. it's not like the discussion is new or anything...
also, there isn't really something in the way of adding this to trunk, as the NewGRF thing is the only real issue holding it back.
also, there isn't really something in the way of adding this to trunk, as the NewGRF thing is the only real issue holding it back.
Re: New map features
cirdan wrote:Alternatively, we can also tell users not to use a tall rail station tile under a bridge? It is not as if the particular station tile choice has any impact on gameplay, right? Is there any NewGRF out there that only offers roofed tiles?
Eddi wrote:I would really like this to be done properly with a NewGRF property similar to bridge height for objects.
this means, any existing NewGRF stations would be excluded from having bridges over them. relying on the fallback graphics type is not reliable, and any hacks involving sprite height or stuff are nonsense.
JGR wrote: As much as it'd be better to solely use newgrf properties, as this feature would only exist in non-trunk versions, it seems unrealistic to expect any significant subset of past or future newgrf authors to choose to implement it. Having some sort of fallback such as allowing bridges over roofless stations is probably necessary for the feature to be of practical use with newgrf stations.
Eddi wrote:i think adding this property should have been done years ago, so NewGRF authors could have had time to prepare. it's not like the discussion is new or anything...
also, there isn't really something in the way of adding this to trunk, as the NewGRF thing is the only real issue holding it back.
Considering the above suggestions as well as HackaLittleBit's, kamnet's, Quast65's and Streckenläufer's thoughts and questions, how about the following? ...wallyweb wrote:Caveat Emptor - Buyer beware:
Allow bridge building at any level.
For evaluation purposes, code a NMF diff/patch that allows any level bridge over road, rail and sea stations, waypoints, buoys and depots with a warning in the diff/patch release post that the feature is for player evaluation and is not saved game safe pending the development of a proper NewGRF Specification.
This will give everybody a chance to see and comment upon what works and what does not work from a graphical point of view and give Cirdan an opportunity to resolve any coding bugs.
Once a NewGRF Specification has been done and tested, it can be included in the default station hard code. Authors of existing GRFs can then decide whether to update their code with this property. Authors of future GRFs will have access to this property right out of the box.
At the risk of being cast into an eternal flame, may I suggest inluding bridges over bridges as well? I am having some interesting thoughts of the possibilities.
wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
- planetmaker
- OpenTTD Developer
- Posts: 9432
- Joined: 07 Nov 2007 22:44
- Location: Sol d
Re: New map features
Implementing an additional propertyA which defines the height of the building and whether bridges are allowed over it in new NewGRFs is not a big deal. So if the specs should be created in a reasonable manner, I would expect it to stick and be picked up. Starting with "evaluation hacks" on the other hand is a sure way to bad results and will make sure people rather not spend time on implementing it.JGR wrote:As much as it'd be better to solely use newgrf properties, as this feature would only exist in non-trunk versions, it seems unrealistic to expect any significant subset of past or future newgrf authors to choose to implement it. Having some sort of fallback such as allowing bridges over roofless stations is probably necessary for the feature to be of practical use with newgrf stations.
OpenTTD: manual | online content | translations | Wanted contributions and patches
#openttdcoop: blog | wiki | public server | DevZone | NewGRF web translator
DevZone - home of the free NewGRFs: OpenSFX | OpenMSX | OpenGFX | Swedish Rails | OpenGFX+ Trains|RV|Industries|Airports|Landscape | NML
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: New map features
Just a pic to illustrate all the problems.
1 Pillars through ceiling.
2 Bridges with and without pillars.
3 Distance between pillars.
4 Roof height of building.
5 Tiles with and without roof.
Did I forget something?
- Attachments
-
- s3.png (86.68 KiB) Viewed 956 times
Re: New map features
I too think that this is the way forward, at least for now.JGR wrote:As much as it'd be better to solely use newgrf properties, as this feature would only exist in non-trunk versions, it seems unrealistic to expect any significant subset of past or future newgrf authors to choose to implement it. Having some sort of fallback such as allowing bridges over roofless stations is probably necessary for the feature to be of practical use with newgrf stations.
See below. Note that savegame compatibility is not a problem, as the format is not changed. If you build a bridge that we later disallow, you will be stuck with a bridge that may look ugly and cannot be rebuilt, but that is all.wallyweb wrote:Considering the above suggestions as well as HackaLittleBit's, kamnet's, Quast65's and Streckenläufer's thoughts and questions, how about the following? ...
For evaluation purposes, code a NMF diff/patch that allows any level bridge over road, rail and sea stations, waypoints, buoys and depots with a warning in the diff/patch release post that the feature is for player evaluation and is not saved game safe pending the development of a proper NewGRF Specification.
This will give everybody a chance to see and comment upon what works and what does not work from a graphical point of view and give Cirdan an opportunity to resolve any coding bugs.
When I designed my new map array, I deliberately reserved 4 bits in each bridgeable tile so that we could have overcrossing bridges with signals. Then again, having room for them in the map array is only the beginning.wallyweb wrote:At the risk of being cast into an eternal flame, may I suggest inluding bridges over bridges as well? I am having some interesting thoughts of the possibilities.
Here is a new version of the patch. It allows bridges over buoys (an oversight in my first patch) and over rail stations and waypoints:
- For standard rail station tiles, the bridge deck must be 4 levels higher than the station for roofed tiles, 2 levels higher for the station building tile and at any height above for standard non-roofed tiles.
- For standard waypoints, the bridge deck must be 3 levels higher than the waypoint.
- For custom rail station and waypoint tiles, you can build a bridge at any height, for testing purposes.
- Attachments
-
- station-bridge.diff
- Patch; apply with -p1
- (21.27 KiB) Downloaded 82 times
Re: New map features
cirdan wrote:Here is a new version of the patch. It allows bridges over buoys (an oversight in my first patch) and over rail stations and waypoints:Please test and report what you find. The values for standard tiles are the minimum required to avoid glitches, but that is all the testing that I have done. Please test your favourite NewGRFs, so that we can reach a consensus on what to do with them and whether to extend the spec for this.
- For standard rail station tiles, the bridge deck must be 4 levels higher than the station for roofed tiles, 2 levels higher for the station building tile and at any height above for standard non-roofed tiles.
- For standard waypoints, the bridge deck must be 3 levels higher than the waypoint.
- For custom rail station and waypoint tiles, you can build a bridge at any height, for testing purposes.
Here is the unguaranteed Win32 binary 2nd Edition pathched to the current NMF push:
Happy Testing.
wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
Re: New map features
would be very very very very nice to have the Houseplacing in the map editor !!!!
This would be more than awesome for most map-creating people !!!!
This would be more than awesome for most map-creating people !!!!
Re: New map features
Thank you, as always.wallyweb wrote:Here is the unguaranteed Win32 binary 2nd Edition patched to the current NMF push:
Err, have you actually tried? It should already be there.Timeflyer wrote:would be very very very very nice to have the Houseplacing in the map editor !!!!
This would be more than awesome for most map-creating people !!!!
Re: New map features
would be nice to have this ONE in a STABLE VERSION !!!! That's waht i meanErr, have you actually tried? It should already be there.
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: New map features
Why do CAPITAL LETTERS so annoy us?Timeflyer wrote:would be nice to have this ONE in a STABLE VERSION !!!! That's waht i mean
It would be more helpful if you would point out what is not stable in Cirdan's branche!
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: New map features
Just some testing.
check_bridge is always 1 with newgrf correct?
Att. Ore unloader station 0.1 has moving crane.
Awesome graphics by the way.
Code: Select all
uint gfx = layout[platform * plat_len + offset];
uint check_bridge = (statspec != NULL) ? 1 : (gfx < 2 ? 1 : gfx < 4 ? 2 : 4);
Att. Ore unloader station 0.1 has moving crane.
Awesome graphics by the way.
- Attachments
-
- st3.png
- (653.87 KiB) Not downloaded yet
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: New map features
just a preliminary proposal.planetmaker wrote: Implementing an additional propertyA which defines the height of the building and whether bridges are allowed over it in new NewGRFs is not a big deal. So if the specs should be created in a reasonable manner, I would expect it to stick and be picked up. Starting with "evaluation hacks" on the other hand is a sure way to bad results and will make sure people rather not spend time on implementing it.
Some things may be missing.
But it is food for thought.
I hope it makes sense.
Note, I do not know newgrf's inner workings.
Byte for buildings
Code: Select all
7 6 5 4 3 2 1 0
0 : Bridge construction allowed. (no yes)
1 : Bridge pillars on north side allowed. (no yes)
2 : Bridge pillars on south side allowed. (no yes)
If both north and south are zero, no pillars allowed.
If both north and south are one, tile handles pillars unconditional.
345: Amount of extra z-levels to add, before bridge construction is allowed. (7 levels)
Or height in z-levels of structure.
67 : Reserved.
Code: Select all
7 6 5 4 3 2 1 0
0 : Bridge can be build over buildings. (no yes)
1 : Has pillars. (no yes)
234: Max length of middle section bridge = 7 tiles or more.
56 : Min length of middle section + 1 = 1 .. 4 tiles
Zero means bridge has no middle sections.
7 : Minimum z-level nescessary of bridge deck to clear roof top's. (zero or one)
Re: New map features
The image below demonstrates that the player does have default bridge options where the pillars do not penetrate the roof of the hall.
Bridge pillars vary greatly in quantity, shape and positioning. It would be a nightmare to work up code to control them from another GRF such as stations.
If anything, to provide the player with more choice, the number of defined bridges (13) should be increased or multiple bridge sets should be allowed.
I no longer think that "allow bridge" and "bridge height" should be added to station properties. The images and saved game demonstrate that the player has a wealth of choices to explore. Until quantum computing comes to TTDX/OTTD, only the stupid AI needs guidance. As much as politicians and the Illuminati wish we were, humans are not AI ... (yet ).
Loading the TBRS GRF seen below shows the player has even more options to pick from.
The attached save game shows almost all the default bridges.
Now load TBRS into that game and see what happens.Bridge pillars vary greatly in quantity, shape and positioning. It would be a nightmare to work up code to control them from another GRF such as stations.
If anything, to provide the player with more choice, the number of defined bridges (13) should be increased or multiple bridge sets should be allowed.
I no longer think that "allow bridge" and "bridge height" should be added to station properties. The images and saved game demonstrate that the player has a wealth of choices to explore. Until quantum computing comes to TTDX/OTTD, only the stupid AI needs guidance. As much as politicians and the Illuminati wish we were, humans are not AI ... (yet ).
wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: New map features
Another solution could be giving a preview of bridge to be build + button to actually construct.
Player selects site to construct bridge and then selects a bridge in option box.
The bridge is shown as preview on the selected site.
Only when player clicks 'build' button, the action is completed.
Player selects site to construct bridge and then selects a bridge in option box.
The bridge is shown as preview on the selected site.
Only when player clicks 'build' button, the action is completed.
- Attachments
-
- build.PNG (67.53 KiB) Viewed 3365 times
Re: New map features
I don't really follow this bit, the bridge tile layout and length restrictions are already defined in the GRF spec.HackaLittleBit wrote:Byte for bridges
Code: Select all
7 6 5 4 3 2 1 0 234: Max length of middle section bridge = 7 tiles or more. 56 : Min length of middle section + 1 = 1 .. 4 tiles Zero means bridge has no middle sections.
There's no need to specify them again by a separate mechanism unless you're implying adjusting the bridge tile layout to match the restrictions of tiles underneath?
Also more generally, memory isn't *that* scarce and I don't think it's necessary to be that tight-fisted with bit allocations within the GRF interface. Some level of future-proofing is generally prudent to avoid creating future maintenance work for yourself.
Ex TTDPatch Coder
Patch Pack, Github
Patch Pack, Github
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: New map features
Sort of.JGR wrote: unless you're implying adjusting the bridge tile layout to match the restrictions of tiles underneath?
If you look at the pic you can see that bridge 3 and 4 only differ at the middle section.
If you would know before building the bridge, the size of that middle section or available middle sections you would be able to say if bridge would put pillars or not on station.
Bridge 1 has a middle section of 2 or 3.
The idea was to give info to the routine of available length of middle sections, to give as little interference as possible to the underlying structures.(houses stations etc.)
I don't know if this is possible.
Correct me if I am wrong, but for example bridge 4 with a middle span of 5 or 7 tiles would be awesome.
Just brain storming.
- Attachments
-
- br.png (113.58 KiB) Viewed 3337 times
Re: New map features
I like this.HackaLittleBit wrote:Another solution could be giving a preview of bridge to be build + button to actually construct.
The possibilities are here.HackaLittleBit wrote:I don't know if this is possible.
Correct me if I am wrong, but for example bridge 4 with a middle span of 5 or 7 tiles would be awesome.
Just brain storming.
wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: New map features
Thanks.wallyweb wrote:The possibilities are here.
- Attachments
-
- br.png (144.07 KiB) Viewed 3302 times
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: New map features
And other solution.
Substituting sections of bridge with BRIDGE_PIECE_MIDDLE_EVEN.
Substituting sections of bridge with BRIDGE_PIECE_MIDDLE_EVEN.
- Attachments
-
- long1.png (169.77 KiB) Viewed 956 times
Who is online
Users browsing this forum: No registered users and 43 guests