Page 1 of 2

[OTTD] Subway stations disguised as parks [alpha release]

Posted: 27 May 2010 17:34
by Freak_NL
Status:
Alpha 1, barely usable.
Release: in this post

Updated Sunday May 30th

In the NuTracks thread I've asked about the technical possibilities for replacing the tunnel entrance graphics only for a specific rail type (third rail metro tracks). This is as of yet impossible, but it looks like it may become possible in the nearish future. The reason is a concept I'm working on:

Subway stations cleverly disguised as parks

Presently, if you want to use down-town metro lines without sacrificing too many houses, you might end with something like this:
Present method of building pseudo-subway lines
Present method of building pseudo-subway lines
subs.png (60.75 KiB) Viewed 16434 times
Thanks to the signals in tunnels patch, it is already possible to skip the signals around the platforms, and with the NuTracks and 2CC trainset, a metro line can easily carry respectable amounts of passengers, even with platforms at a length of 2 tiles. So what if we had a NewGRF for subway stations that could make the 4 by 2 tiles needed for such a down-town station look like parks?
Mock-up of park/subway stations
Mock-up of park/subway stations
subs2.png (22.41 KiB) Viewed 16434 times
I've never made a NewGRF before, so I have started experimenting a bit:
A first foray into NewGRF coding
A first foray into NewGRF coding
parktest.png (18.67 KiB) Viewed 16434 times
As you can see, I'm doing something wrong here. The roofs don't obscure the whole train, only a bit of it. Any idea what is going wrong here? This is my pre-NFORenum NFO:

Code: Select all

// Automatically generated by GRFCODEC. Do not modify!
// (Info version 7)
// Format: spritenum pcxfile xpos ypos compression ysize xsize xrel yrel
1 * 10  00 00 00 00
1 * 10  08 07 "FN01" // GRF_ID
        "Subway park stations" 00 // Name
        "Subway stations in the form of parks above ground" 0D // Description
        "by Freak_NL" 00 // Author
1 * 10   01 04 01 04
1 sprites/platforms.pcx   1   7  09 23 42  -9  -3        // ID 42D platform NE
1 sprites/platforms.pcx  113  38 09 39 64 -31  -8        // ID 42E platform + roof SW
1 sprites/platforms.pcx  91   7  09 23 42 -31  -3        // ID 42F platform NW
1 sprites/platforms.pcx  46   38 09 39 64 -31  -8        // ID 430 platform + roof SE
1 * 10  00 04 02 01 01 // Changing 2 properties for 1 station
        08 "PRKP" // Put the station in "Park platforms"
        09 02 // Tile layout, 2 different tiles
        // tiletype   bounding box        sprite id     bounding box        sprite id
        F4 03 00 00   00 00 00 10 05 03   2F 04 00 00   00 00 00 10 10 08   30 04 00 00   80
        F3 03 00 00   00 00 00 05 10 03   2D 04 00 00   00 00 00 10 10 08   2E 04 00 00   80
1 * 10  02 04 00 00 01 00 00
1 * 10  03 04 01 01 00 00 00
1 * 10  04 48 FF 01 01 C5 "Park platform" 00
1 * 10  04 48 FF 01 01 C4 "Subway park platforms" 00
Questions about the NFO:

I've looked at a number of other NewGRFs and the tutorial for inspiration, but some parts I don't quite understand.
  • Action0's tiletype (F4 03 00 00), that seems to work, but what does it refer to?
  • Do I need multiple sprites to make a closed "roof" (park) as outlined above?
NewGRF and graphics attached to the next post.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 27 May 2010 17:36
by Freak_NL
This is the resulting NewGRF and its graphics. Don't mind the colours, this is just a test to see if I could manage writing the NFO file and align the graphics properly.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 27 May 2010 17:50
by dandan
That's a very nice idea.

I see one problem though: How are you going to cover the tunnel entrances?
But even so, if you just ignore that for now, a solution might come along some time in the future (when the new railtypes feature is improved with respect to tunnels).
Freak_NL wrote: As you can see, I'm doing something wrong here. The roofs don't obscure the whole train, only a bit of it. Any idea what is going wrong here?
I guess the problem is with the bounding boxes. You have put the z-size to 3, which is too low.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 27 May 2010 17:55
by Freak_NL
The tunnel problem may solve itself in the future, and in the mean time, at least the station tiles can be made to look like parks.

Is it possible to visually make it look like the "roof" is level with the surrounding streets (one level higher) like in the mock-up? I think I've got them at 8 and the rear platforms at 3.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 27 May 2010 17:59
by dandan
Freak_NL wrote:Is it possible to visually make it look like the "roof" is level with the surrounding streets (one level higher) like in the mock-up? I think I've got them at 8 and the rear platforms at 3.
Yes, that should be possible if you draw it correctly. Take a look at the "Gare centrale" in the Canadian Stations set.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 27 May 2010 18:12
by Doorslammer
dandan wrote:I see one problem though: How are you going to cover the tunnel entrances?
I assume a possible solution has already presented itself in the modular depot thread.

Great ideas here, "cut and cover" construction of underground lines is definitely something to pursue as a temporary solution to true underground construction.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 27 May 2010 19:52
by DJ Nekkid
what about other buildings as well, for example all TTRS buildings and such? And yes, i've had the idea once, but never got around it.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 27 May 2010 21:40
by Freak_NL
dandan wrote:Yes, that should be possible if you draw it correctly. Take a look at the "Gare centrale" in the Canadian Stations set.
I see that Gare Centrale does what I want, but the Canadian Stations NewGRF is huge! There are way too many entries in that NFO to see how they approached that Action0/09 bit.. :(

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 27 May 2010 22:16
by Freak_NL
Got it. The yrel is now set to -1 and the boundingbox zofs is set to 07. Now trains appear to pass under the roof tile.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 28 May 2010 17:22
by DJ Nekkid
Here is what i've been fiddeling with the last couple of hours :) And that isnt stations :)

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 28 May 2010 17:26
by supermop
Is this a caternary type? could be very attractive if set to use sprites randomly from a set!

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 28 May 2010 17:35
by DJ Nekkid
bingo. That is the plan :)

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 28 May 2010 17:35
by Badger
That would be very clever.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 28 May 2010 17:45
by DJ Nekkid
That is unfortuneatly all i have for today, got a gig at midnight, and got a party with some other DJs i need to attend, but i have quite some ideas in my head, and i think it might turn out quite good :)

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 28 May 2010 18:45
by Eddi
theoretically, you can have pseudo-random bits on rail tiles [in openttd], but i'm not sure if you can use that for catenary.

other than that, catenary consists of two sprites, plus patchwork near corners or tunnels

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 29 May 2010 02:03
by DJ Nekkid
eddi:

i know ... i've done some semi-extensive testing on most of the needed sprites, and i got a fairly good idea for what is needed, and my plan were to do more tomorrow and see how it turns out.
And as there are 3 different streight forward (/ and \) sprites (mainly 2 tho), and with 4 or 8 different sets on thoose two, it should be QUITE random :) My only concern is the crossings,but lets see how it turn out.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 29 May 2010 17:25
by Freak_NL
Looks promising Nekkid!

Thanks to the train shed ideas of supermop I too have some progress:
subs3.png
subs3.png (82.39 KiB) Viewed 15970 times
Apparantly you can cover the tunnel entrances with station graphics if the station tiles are adjacent to them. This works without glitches (as far as I can see) at least for the NW and NE station ends. The SW and SE ends are next on the agenda.

Tile 5 is drawn with a small brick wall that camouflages the small edge you see on the NE side of that road because it is built on a slope. The brick wall uses the same colours, so it looks natural. :)

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 29 May 2010 17:41
by Kogut
What about special station tile for placing on A, B covering A, B, C, D? In the same way as modular train sheds.

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 29 May 2010 17:49
by Freak_NL
My thoughts exactly. If covering them from tile 5 and 6 won't work, then using those tiles is probably the best option. It would make a subway station for a medium sized city 2×5 tiles (tunnel, platform, platform, tunnel, tunnel-cover). Basically, platform length plus 3 as long as you use a patch or patchpack with the signals in tunnels functionality so you don't need to end your platforms with signals.
Przechwytywanie.PNG
What's a przechwytywanie? :?

Edit
Yeah, that didn't work, as expected. I'm going with your suggestion Kogut. :)

Re: [OTTD] Subway stations disguised as parks [concept]

Posted: 29 May 2010 17:57
by Kogut
Default name for screenshot produced from default screenshot tool for windows 7.
Can be translated (from Polish) as capturing.