IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Got an idea for OpenTTD? Post it here!

Moderator: OpenTTD Developers

Post Reply
TopTechDreamer
Engineer
Engineer
Posts: 48
Joined: 22 Feb 2012 12:21
Location: Ukraine
Contact:

IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TopTechDreamer » 24 Aug 2019 23:58

( TopTechDreams patchpack (for Win32 (XP SP3 and later) (and Win64) and for Android). This is PROTOTYPE. ) To use this .exe file, copy (unzip) it to the same folder as the "openttd.exe" of stable version 1.9.1 and run it.
[ Edited 20190904 20:38 : Android build of this patchpack of version 1.9.2.83 by pelya (thanks a lot). ]
[ :!: Edited 20190830 20:50 : With my apologies: attachment with source-code (folder "scr") renewed, because subfolder "scr\script" was missed earlier and now it is here: with +1 modified file "script_order.cpp" inside. Please, re-download this full source-code, who has interest for it. Excuse me, please. ] (source files only which have changes)

... :!: IMPLEMENTED suggestions:

:arrow: 1. Water Tunnels (viewtopic.php?f=32&t=46596)
== Boat tunnels. You should be able to dig tunnels for boats. (viewtopic.php?f=32&t=84354).

How to use? - Try to build railway tunnel near water (between 2 water areas). Ships will be able to use it already!..
But You can convert it to water-tunnel (ship-tunnel) graphics - try to build canal (1 tile) or ship depot (2 tiles) just on entrance of this railway tunnel.
(You can convert 1-tile-entrance water tunnel to 2-tiles-entrance via the same operation.)
Water-(ship-)tunnel with 1-tile-entrance works with visual defects (non-continuous disappearing and appearing of ships), but 2-tiles-entrance works quite realistic (continuous).

:!: IMPORTANT: Existing pathfinder algorithms are not optimized for tunnels (or bridges) with 2-tiles-long entrances. So ships can not find a way through such tunnels often. Use buoyes to fix this: place buoy after exit of the second (other) side of such tunnel - this will help to the pathfinder algorithm to find a way through this tunnel.

Changes in source code to implement this feature are marked with label (comment) :

Code: Select all

//  for Allow Ships to use Tunnels (Water-Tunnels or Rail-Tunnels for Ships)

---

:arrow: 2. Now You can have more objects under bridges! - This program allow
2.1. stations under bridges (over 1 level of height = of z-coordinate) // This allow, for example, to build bridge over railway station or to build ship doc (or bus station) under the bridge... But... You better don't build bridges over Heliports or over Airport's runways... please. :)
2.2. houses under bridges (over 2 levels of height) // This may look not very good with tall buildings.
2.3. trees under bridges (over 3 levels of height) // This is what I was dreaming about: this looks great and allow to save forests and rainforests. But bridge have to be of enough height.
2.4. industries under bridges (over 4 levels of height) // This looks normal with small industries: Water Tower, Water Supply etc.. I didn't try to build bridges over big industries (as Oil Refinery).

Many of such combinations look really nice.

Changes in source code to implement this feature are marked with label (comment) :

Code: Select all

//  for Allow stations under bridges
//  for Allow houses under bridges
//  for Allow trees under bridges
//  for Allow industries under bridges
---

:!: :arrow: 3. 3D-Revolution of (railway-) stations (these are most powerful new possibilities) :

:!: :arrow: 3.1. (Railway-) tunnel-stations and bridge-stations - as shown and described in the topic Existing objects bridges and tunnels as stations (viewtopic.php?f=32&t=85229). But!.. Now player can control tunnel-stations and bridge-stations via existing User Interface (UI) :
(Note: Player can convert different 2 ends of 1 tunnel or bridge to (platform-) tiles of different stations. In such case both of that stations will share this platform between each other, i.e. will have platform with length of the whole tunnel or bridge, but will be unable to use it at the same time - only consequentially, in sequence, by queue - like timeshare. But train will be able to stop there only in 1 of 2 directions - heading outside.)

:!: IMPORTANT: Existing pathfinder algorithms are not adjusted to work with tunnel-platforms or bridge-platforms (or stations). So trains can not find a way to such platforms as usual (if there are no usual directly adjacent platform-tiles). Use Waypoints to fix this: place waypoint before a point of entrance to such station so, that trains don't have a possibility to avoid this station. Then trains will try to go via one of that tunnels of bridges, that are its platforms. When some train will achieve some entrance tile of such tunnel(-platform) or bridge(-platform), this train will start to interact with that platform and station.

How to use? - Try to build railway platform tile directly on entrance of (railway-) tunnel or bridge to convert it to a tunnel-platform or bridge-platform (as one of platforms joined with an existing station or as new station - using [Ctrl] button to choose station as it is for usual platform tiles). Try to do the same, but with active {remove] button (in railway UI), to remove station from the given entrance of tunnel or bridge (just similar to the usual platform tiles) - this will convert tunnel or bridge from station to the simple (ordinary, usual) tunnel or bridge. Try to click on the entrance-tile of tunnel-station or bridge-station to open window of that station (similar to the usual platform-tiles). Even "Land area information" works right with tunnel-platforms and bridge-platforms now!

Changes in source code to implement this feature are marked with label (comment) :
Without changes of UI functions:

Code: Select all

//  for Existing objects tunnels and bridges as stations
// Begin for Existing objects tunnels and bridges as stations
With changes of UI functions:

Code: Select all

//  for Existing objects tunnels and bridges as stations // 20190724: // 2nd stage: Allow users to convert objects via UI.
// Begin for Existing objects tunnels and bridges as stations // 20190724: // 2nd stage: Allow users to convert objects via UI.
:!: :arrow: 3.2. (Railway-) tunnels and bridges, even if they are not stations, can be parts of (railway-) platforms to increase "platform length" parameter of that platforms (to avoid "platform length penalty" to unloading and loading speed (and time), if platform is shorter than train). This looks like bridges and tunnels continue that platforms - as shown and described in the topic Allow existing tunnels and bridges to increase "platform length" parameter for directly adjacent station tiles (viewtopic.php?f=32&t=85330).
(Note: directly adjacent platform tiles of different stations do the same: they continue each other. And (directly adjacent to platform tiles) even non-platform railroad tiles do the same, but only if they are under any bridge.)
(Note: Player can build platform tiles of different stations near different 2 ends of 1 tunnel or bridge. In such case both of that stations will share this platform between each other, i.e. will have longer platform, but will be unable to use it at the same time - only consequentially, in sequence, by queue - like timeshare.)

How to use? - Simply build bridge or tunnel directly adjacent to some platform tile (as continue of some platform). As shown in corresponding topic (link in p.3.2 above).

Changes in source code to implement this feature are marked with label (comment) :

Code: Select all

/* BEGIN of Allow existing tunnelbridge to increase "platform length" parameter for directly adjacent station tiles */
---

Glory to Ukraine. :)
Last edited by TopTechDreamer on 04 Sep 2019 20:39, edited 9 times in total.

User avatar
kamnet
Moderator
Moderator
Posts: 6778
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: IMPLEMENTED some suggestions (DOWNLOAD .EXE file) - Independence day of Ukraine 20190824 release

Post by kamnet » 25 Aug 2019 00:18

This would be extremely helpful if you set up a github repository, connected to the OpenTTd master branch, and then submitted each patch individually against it. This would get the attention of the devs and allow them to inspect it, provide better feedback on how to improve it, and perhaps even move forward with implementing it.

User avatar
jfs
Director
Director
Posts: 565
Joined: 08 Jan 2003 23:09
Location: Denmark

Re: IMPLEMENTED some suggestions (DOWNLOAD .EXE file) - Independence day of Ukraine 20190824 release

Post by jfs » 25 Aug 2019 09:47

I initially dismissed this topic as political spam due to the subject line. Agree with kamnet that you should keep the source code in a public repository as it would make it much easier to review and track changes for others.

TopTechDreamer
Engineer
Engineer
Posts: 48
Joined: 22 Feb 2012 12:21
Location: Ukraine
Contact:

Re: IMPLEMENTED some suggestions (DOWNLOAD .EXE file) - Independence day of Ukraine 20190824 release

Post by TopTechDreamer » 25 Aug 2019 14:11

With respect.

I think, this is not spam. This is working prototype with possibility (if one wishes it) to download it freely... And with some name of release (version identifier).

GitHub and its standards are not easy for me: I have almost 0 experience, no account there and... am not ready to spend time to learn GitHub now. Yes, that knowledge would be useful, but.. I am not ready now.
On the other hand, the text search of some string (label) inside 10 source code files (with changes only) - this is simple and easy even for me (with little experience). Visual Studio IDE does such search very well via Ctrl+F (in Windows).

User avatar
kamnet
Moderator
Moderator
Posts: 6778
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: IMPLEMENTED some suggestions (DOWNLOAD .EXE file) - Independence day of Ukraine 20190824 release

Post by kamnet » 25 Aug 2019 16:10

TopTechDreamer wrote:
25 Aug 2019 14:11
With respect. I think, this is not spam.
It's because you included "Independence day of Ukraine 20190824" and "DOWNLOAD .EXE FILE" in the title that it appeared to be political spam. I had to read it a few times myself to understand what you were trying to communicate.

I realize that setting up a github repository might not be easy or convenient for you, but if you have any aspirations of having this patch become part of the source code (and I think it can be argued that it should), then this is going to be a necessary step. It is unlikely that a core developer is going to come here, try to dissect your patches, and pick something that they want to work on developing themselves. By submitting it through github, you're going to be able to tap into the developers feedback quickly and easily. If you leave it here, then there's a strong likelihood that it will linger in obscurity.

TopTechDreamer
Engineer
Engineer
Posts: 48
Joined: 22 Feb 2012 12:21
Location: Ukraine
Contact:

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TopTechDreamer » 25 Aug 2019 17:54

Oh, please!
"Independence day of Ukraine" (or even 1 word "Ukraine") someone may consider as "political spam" (I have different opinion),
but there is no politics in the words "(DOWNLOAD .EXE file)" - this is definitely. But these 3 words in the title of this topic show (reflecting the fact), that here - inside this topic - everyone can exactly DOWNLOAD .EXE file. This is very important, because some people will not enter inside this topic at all, will not open it, if they don't see these words in its title. Maybe, this could be considered as some kind of spam to promote this patch-release of OpenTTD... But this is the forum to discuss about OpenTTD, about wanted changes to it, and people WISH to have such working implementations, like this one - with .EXE files.

That's why I ask You for permission: please, allow me to turn back the insertion "(DOWNLOAD .EXE file)" inside the title of this topic. Maybe, in some modified form - for example: "(here You can DOWNLOAD .EXE file)".

Please please...

User avatar
jfs
Director
Director
Posts: 565
Joined: 08 Jan 2003 23:09
Location: Denmark

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by jfs » 25 Aug 2019 18:38

I never said this topic is spam, I said the subject line is stylistically similar to what is typically used in spam.

The current subject tells me nothing about this being a patchpack, or older patches updated to a more recent version. It just tells me you did something. My suggestion for a subject that would actually give me positive associations would be something like: "Improved tunnels and bridges patch pack (1.9.1 base) - updated 2019-08-24"
Most people have very little attachment to national celebration days of other countries, so the fact the release day coincides with one does not seem relevant at all to me. You may as well have written "Windows 95 anniversary edition", or "Pluto remembrace day release".

User avatar
kamnet
Moderator
Moderator
Posts: 6778
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by kamnet » 25 Aug 2019 18:59

Also, the reason I edited the title "DOWNLOAD EXE. NOW" is because we deal with actual spammers trying to peddle infected exe. files. It's a confusing message at best, and at worst it does appear to be a spammer trying to get people to download infected file.

I agree with jfs, a better title clearly stating what you did would be better. I also think this would get more attention if it was in the OpenTTD Development section, which attracts people who are looking to play with experimental builds and patches, and who are also likely to provide feedback that you will need to improve it.

User avatar
Gwyd
Chief Executive
Chief Executive
Posts: 697
Joined: 17 Apr 2017 16:52
Location: Western Ile-de-France Region

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by Gwyd » 27 Aug 2019 08:41

Yeah this name confused me at first too. Actually reading about the pack was very interesting but something like "stations and boat tunnels patch release" would have made me more likely to come in.

Regardless of that this pack does seem very interesting and I might try it if I get the time.

Edit: should this not be in OpenTTD development rather than suggestions

User avatar
Expresso
Tycoon
Tycoon
Posts: 1736
Joined: 09 Aug 2004 00:14
Location: Gouda, the Netherlands

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by Expresso » 27 Aug 2019 19:18

Why does this trigger virustotal?
Attachments
virustotal.png
(62.11 KiB) Not downloaded yet
virustotal sandbox.png
(59.35 KiB) Not downloaded yet

TopTechDreamer
Engineer
Engineer
Posts: 48
Joined: 22 Feb 2012 12:21
Location: Ukraine
Contact:

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TopTechDreamer » 27 Aug 2019 22:43

I know nothing about this and about "virustotal" at all. After Your question about this I know this name now. :)
My (old) antivirus program says, that no viruses found on this computer. Given executable file was compiled in MS Visual Studio 2019 Community Edition 2019-08-24 18:40 UTC+3 = 15:40 UTC and after was packed in .zip archive and published here 2019-08-24 23:58 UTC. I hope, that this file (and my system) are clean. But...
In 2nd attachment are all modified source-code files - 18 files with 18 copies (each file in 2 copies). Who can compile source-code of OpenTTD to executable file, can do this and use own resulting executable file.

I think it's obviously, that I have no reason to create any danger for anyone. I like OpenTTD, use these forums and want to continue these possibilities. I just can't wait until someone else would implement such wonderful and beautiful possibilities, as I and other people asked earlier and I have implemented them now, and published them here - to share my gladness :D with other people, who like (and love) OpenTTD too. ... And... for glory. :D :)

TopTechDreamer
Engineer
Engineer
Posts: 48
Joined: 22 Feb 2012 12:21
Location: Ukraine
Contact:

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TopTechDreamer » 30 Aug 2019 21:23

With my apologies: attachment #2 (openttd 1.9.1 + Independence day of Ukraine 20190824 release - save, src.zip) with modified source-code files (folder "scr") is renewed 20190830 20:50, because subfolder "scr\script" was missed earlier and now it is here: with +1 modified file "script_order.cpp" inside. Please, re-download this full source-code set (from the heading post of this topic - viewtopic.php?f=32&t=85845), who has interest for it. Excuse me, please. Thank You.

User avatar
acs121
Tycoon
Tycoon
Posts: 1949
Joined: 03 Nov 2017 18:57
Location: Courbevoie, near Paris, France

Re: IMPLEMENTED some suggestions (DOWNLOAD .EXE file) - Independence day of Ukraine 20190824 release

Post by acs121 » 31 Aug 2019 02:16

jfs wrote:
25 Aug 2019 09:47
I initially dismissed this topic as political spam due to the subject line. Agree with kamnet that you should keep the source code in a public repository as it would make it much easier to review and track changes for others.
Same thing. If your patch pack's name is "Independence Day of Ukraine" then just change the topic name as "Independence Day of Ukraine Patchpack" or something like that.

pelya
Transport Coordinator
Transport Coordinator
Posts: 268
Joined: 18 Nov 2010 19:48
Contact:

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by pelya » 31 Aug 2019 20:53

Android build of this patchpack: https://sourceforge.net/projects/libsdl ... 9.2.82.apk
Sources: https://sourceforge.net/projects/libsdl ... src.tar.xz + the patch attached

Update: fixed a bug in dropdown menus, new Android build: https://sourceforge.net/projects/libsdl ... k/download
This time with proper source archive: https://sourceforge.net/projects/libsdl ... z/download
Attachments
openttd-1.9.1-TopTechDreamer.patch
(114.74 KiB) Downloaded 12 times

TrueSatan
Transport Coordinator
Transport Coordinator
Posts: 287
Joined: 16 Jul 2003 18:33

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TrueSatan » 09 Sep 2019 18:08

Interesting patch, building works, but both tunnel and bridge are not removeable anymore after removing the station.
Hope you work more on this patch, could be a nice addition to jgr patch pack.
And I wonder what happens if you have a tunnel with 100 tiles or a bridge over the sea and you build a station
there. Then the whole tunnel or station will be a station right?
Well it needs a lot of checks where to build and where not.
And some setting for station length in tunnel or at the bridge.
Looks promising, keep up the good work.

TopTechDreamer
Engineer
Engineer
Posts: 48
Joined: 22 Feb 2012 12:21
Location: Ukraine
Contact:

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TopTechDreamer » 09 Sep 2019 21:32

I scare because of Your Username. :shock:

I can delete (demolish) bridge or tunnel before, while and after it will be, it is or it was a station. I can delete (demolish via "dynamite" tool) it anytime. ("Remove" button is not allowed for tunnels or bridges in OpenTTD.) Exception may be, if a train is inside, - in that case the game don't allow to delete this tunnel (or bridge) (but also it shows the red message - exclamation - about this situation).
Release from this topic works correctly.

The game controls limitations for parameter "Maximum station spread" ( Advanced Settings --> Limitations ) regarding to tunnel-stations and bridge-stations similar to the same with usual platform tiles. So, if tunnel will be 100 tiles long and "Maximum station spread" = 20 tiles, then the game will disable to convert both end of this tunnel to 1 station, but player will be able to convert 2 ends to 2 different stations - they will share this tunnel in time (like timeshare - look at the descriptions in head of this topic).
This parameter "Maximum station spread" is the only limitation to convert an existing (railroad-) tunnel or bridge to a tunnel-platform or a bridge-platform. This means: if player can build a tunnel, then player can convert it further to tunnel-platform (and the same with bridges).

No, 0 or 1, or 2 ends of tunnel or bridge can be "station tiles" - internal part of tunnel or bridge is not a "station" (it can not interact with trains or with any other objects in the game (houses, industries, ...)) - for more details look at descriptions and picture in the topic Existing objects bridges and tunnels as stations (viewtopic.php?f=32&t=85229).

Tunnels for ships are implemented somehow raw (not optimized and with not fully correct style of source code... but this is just working prototype). But (railroad-) tunnel-stations and bridge-stations work very well with full control via UI. So, I have no plans to make something more for tunnel-platforms and bridge-platforms. Yea, it would be better to make some special graphics for them, but graphics is not my task.

odisseus
Engineer
Engineer
Posts: 38
Joined: 01 Nov 2017 21:19

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by odisseus » 10 Sep 2019 02:00

You really should set up a public repository and distribute your work as code rather than compiled binaries. I would like to try out your patches, but I have no capability to run EXE files (and even if I had, I wouldn't launch random EXEs from the Internet).

TrueSatan
Transport Coordinator
Transport Coordinator
Posts: 287
Joined: 16 Jul 2003 18:33

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TrueSatan » 10 Sep 2019 06:01

Just a nickname I use. That's something to be unique hehe
Nothing to be scared off.

Well if its the station spread then its to long for a single station in imho.
There should be really some extra setting for it :)

Well I started a new game with vanilla settings. Now I can revert the bridge
station and I can remove the bridge/tunnel again. Looks like newgrf are not working
for this patch then. Some new tunnel entrance and some new bridges and it fails to remove
the tunnel or bridge. It only removes the station then.

Another problem. If you remove a tunnel from the opposite side then the station remains as
a ghost station.
Funny thing if you remove the station from a bridge and the tunnel ghost station is still there
the tunnel one will be deleted (turns grey) as well. So you missed a check for the tunnel station one
to invalid it. Should be easy to fix :)

Next thing I found, If you use the delete station tile on the tunnel, it takes your money
but the station itself is still there. Guess its the same problem with missing the check
to invalidate the station.
On bridges it works on the side you build the station but not on the other side, it only takes
your money then but the station will remain. On the side with the station tile it removes and invalidates
the station correctly. but you can still spam the remove station tile and it takes you money
on any bridge part (only did a 3 tile bridge). My guess you missed to check in tunnels and bridges if there is anything
like a station. If the station is finally gone, its only on bridge heads that you can spam the remove station tile.
Well you should look at your code for bridge and tunnel heads i guess :) If you fix that part
for newgrf and remove the station then I think it will be sooner or l8er a nice addition to some patch packs.
No clue how hackish the patch is currently.

And yes some repo would be good. we are at 1.9.2 now and 1.9.3 testing for openttd. And still you need
the 1.9.1 original package because you don't provide a complete package (with all languages and so on).
So it would be very nice if you could update your patch to at least 1.9.2 and provide a full playable package.

Thanks and keep up the good work.
Cheers

TopTechDreamer
Engineer
Engineer
Posts: 48
Joined: 22 Feb 2012 12:21
Location: Ukraine
Contact:

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TopTechDreamer » 10 Sep 2019 22:12

odisseus wrote:
10 Sep 2019 02:00
You really should set up a public repository and distribute your work as code rather than compiled binaries. ...
You could download the full set of modified source code files from the head post of this topic - there is the attachment openttd 1.9.1 + Independence day of Ukraine 20190824 release - save, src.zip (download/file.php?id=208814). Other files are not modified (these are source code files from OpenTTD 1.9.1 stable).
+ pelya (thanks) published some openttd-1.9.1-TopTechDreamer.patch file (download/file.php?id=208822) (but sorry, I don't know, how to create or how to use such files automatically).

TopTechDreamer
Engineer
Engineer
Posts: 48
Joined: 22 Feb 2012 12:21
Location: Ukraine
Contact:

Re: IMPLEMENTED some suggestions - Independence day of Ukraine 20190824 release

Post by TopTechDreamer » 11 Sep 2019 00:38

Well I started a new game with vanilla settings. Now I can revert the bridge
station and I can remove the bridge/tunnel again. Looks like newgrf are not working
for this patch then. Some new tunnel entrance and some new bridges and it fails to remove
the tunnel or bridge. It only removes the station then.

I have tested this release (20190824) with NewGRF-s:

1. "Vacuum Tube Train (Vactrain) Set"
Filename: vacuum_tube_train-0.22\vactrain.grf
GRF ID: 444A5901

2. "Vacuum Vehicule Wagon"
Filename: vacuum_vehicle_wagon_and_train-0.22\vactrain.grf
GRF ID: 444A5902

3. "Brianum: speed limit for bridges"
Filename: brianum_speed_limit_for_bridges-1.0\brianum_bridges.grf
GRF ID: 42533031

And several other NewGRF-s, which didn't take a part in that tests.

And I see no problem: with vacuum tube tunnels and bridges UI works correctly. I can not reproduce such problem.
I didn't any tests with NewGRF-s, that change somehow entrances of tunnels or bridges (if exist such NewGRF?).
Another problem. If you remove a tunnel from the opposite side then the station remains as
a ghost station.
Funny thing if you remove the station from a bridge and the tunnel ghost station is still there
the tunnel one will be deleted (turns grey) as well. So you missed a check for the tunnel station one
to invalid it. Should be easy to fix :)

I don't understand this description. What means "remove" ("Remove" tool or "Demolish" (dynamite) tool from UI... or something else)? What means "a ghost station" (an active station with label of Company's color, but without any tiles on the map, or a deleted station with grey label)? I can not reproduce the described situation (don't understand it). Maybe, some save-s or some screenshots could help to explain this situation. (Maybe, previous too.)
Next thing I found, If you use the delete station tile on the tunnel, it takes your money
but the station itself is still there. Guess its the same problem with missing the check
to invalidate the station.
On bridges it works on the side you build the station but not on the other side, it only takes
your money then but the station will remain. On the side with the station tile it removes and invalidates
the station correctly. but you can still spam the remove station tile and it takes you money
on any bridge part (only did a 3 tile bridge). My guess you missed to check in tunnels and bridges if there is anything
like a station. If the station is finally gone, its only on bridge heads that you can spam the remove station tile.

Yea, there is something like this. The game doesn't prevent to remove (to apply the "Remove" tool to) the station at the end of tunnel or bridge, which have no station (but in the code it means not StationID == INVALID_STATION, but StationID == 0). I agree, it would be more handy to prevent this action.
It looks like I forgot to insert this check to prevent this money drain.
But, at least, this is not critical error - player can just don't use "Remove" operation there, where no need is for it.

The problem is, I tried to use StationID = INVALID_STATION to mark (tunnel/bridge entrances), where "no station" is... (In such case there is full reason to allow players to "Remove" 0-stations, i.e. with StationID == 0.) But result is negative: such tries lead to the abnormal program termination (at least, I have this result). Then I leave StationID == 0 as "no station"-marker. But StationID == 0 is not error - the very first station (in the game or for each company) have ID == 0. This means, that in current release player can not "Remove" the very first station from any tunnel or bridge, because "no station" for tunnels and bridges is equal to 0-station, i.e. "no station" == the very first station (for tunnels and bridges). But if player use not "go to <station>" orders but "go non-stop to <station>" orders, then trains will not stop in every tunnel or bridge on their way, but will go to the ordered station.

Post Reply

Return to “OpenTTD Suggestions”

Who is online

Users browsing this forum: No registered users and 2 guests