New Cargo info, and a request!

Discussion of Pop Top's last release of RRT.
milo
Engineer
Posts: 512
Joined: Sat Nov 11, 2006 5:36 pm
Location: End of the line

Unread post

Gwizz wrote:How much room in the game engine do we have for new buildings?
That's a good question. There are a total of 110 effect slots for buildings. RT3 comes with 68 building types and fills another 22 slots with ports and warehouses. The Gwizz Port is in enough scenarios that we should reserve a slot for it, leaving 19 slots free for new buildings. Adding more buildings probably causes warehouse 'Add Building' effects to start vanishing off the list, followed by port 'Add Building' effects. I haven't seen any tests in the code for maximum building counts, but I don't have enough buildings to test if the game works with more than 98 installed.

I'm strongly tempted to swap the positions of the ports and the warehouses in the effect list. Because ports require very precise water/land positions, 'Add Building' usually fails for them and isn't really usable in a scenario unless there's a lot of water. That could potentially give us another 11 building slots.
milo
Engineer
Posts: 512
Joined: Sat Nov 11, 2006 5:36 pm
Location: End of the line

Unread post

Ran into a hitch - turns out that if only a port or warehouse produces a cargo, the cargo isn't considered active. None of the new cargos are showing up because there's no 'real' building producing them. I'll have to research this one more; not sure if it would break existing scenarios to let warehouses enable cargos.

I think I can squeeze enough room out of the translation table for 19 more entries (= 19 objects usable in both English and German scenarios). All of these will be used for cargo names. In addition, there are probably another dozen slots or so holding values that aren't used in the game, such as car names. I'm not sure how we'll handle translating building names yet; this could cause problems when trying to swap scenarios with Molse's crew.

How the devil did Ned Fumpkin build so much so fast? The sophistication of what he constructed for Atlantis is staggering.
User avatar
EPH
Dispatcher
Posts: 451
Joined: Sun Nov 12, 2006 3:23 pm
Location: York PA

Unread post

Milo, I'm not sure what you are referring to here. In British Miracle the only things producing cotton are ports and warehouses. Cotton is enabled as a good in the master list, but there are no cotton plantations in the game. The ports and warehouses produce cotton just fine.
The optimist proclaims we live in the best of all possible worlds; and the pessimist fears this is true." - James Branch Cabell
milo
Engineer
Posts: 512
Joined: Sat Nov 11, 2006 5:36 pm
Location: End of the line

Unread post

You have cotton farms enabled, even if they can't actually be generated by a region; that's why cotton show up as an available cargo. If you disable cotton farms but leave your warehouses enabled, cotton vanishes. I don't have a 'real' building that produces concrete yet, so even if I create a warehouse that supplies concrete, it doesn't show up as an available cargo.
User avatar
EPH
Dispatcher
Posts: 451
Joined: Sun Nov 12, 2006 3:23 pm
Location: York PA

Unread post

OK, I see that now. So the 'enable cargo' list in the editor is generated on the fly from buildings in the database?
The optimist proclaims we live in the best of all possible worlds; and the pessimist fears this is true." - James Branch Cabell
User avatar
bombardiere
Dispatcher
Posts: 425
Joined: Tue Nov 14, 2006 9:07 am
Location: Turku, Finland

Unread post

About the newspapers. While in general, I believe, that these are cargoes, which belongs under what it transported in Mail. However I was leafing trough a book, which contains pictures of British Rails Mk1 coaches. And hey there was a picture of blue Mk1 Full Brake coach, which had a word Newspapers written with large letters on its side. So at least BR did transport newspapers with special cars.

I will try to look into prices too. Hopefully I get my version of the list ready this weekend.

BTW about cargo availability. I fairly certain that I did a scenario, which imported cotton and coffee without the farms being enabled. No actually I am sure! I checked it and I have a working scenario, which doesn’t have these building available, but I can still get cargoes from ports/warehouse.

It could be so that the game needs the building in general. It doesn’t need to be in a scenario, but it must be there in the game’s system.
:?:
User avatar
pure al
Dispatcher
Posts: 306
Joined: Sat Dec 23, 2006 11:38 am
Location: British Rail Class 450

Unread post

Milo if we make the Department store create a few new cargos (or as many as possible really) it could be the building that activates these cargos in our scenarios. You said before that not too many scenarios had used this building, so this shouldn't effect anything. I can't remember exactly how may cargos can be created per building, but it's worth a shot.

bombardiere the newspapers cargo is not going to be a main cargo anyway, so we don't have to worry about it too much. It'll be up to the scenario designer to choose whether he wants to use it or not.

Thanks for helping out with the cargo prices list. Everyone else is also very welcome to say what prices these new cargos should be. (Milo posted a price list of original cargos above)
milo
Engineer
Posts: 512
Joined: Sat Nov 11, 2006 5:36 pm
Location: End of the line

Unread post

bombardiere wrote:BTW about cargo availability. I fairly certain that I did a scenario, which imported cotton and coffee without the farms being enabled. No actually I am sure! I checked it and I have a working scenario, which doesn’t have these building available, but I can still get cargoes from ports/warehouse.
Does your scenario work under 1.06? Wonder if adding express cargo to warehouses broke something.
milo
Engineer
Posts: 512
Joined: Sat Nov 11, 2006 5:36 pm
Location: End of the line

Unread post

Found it. The rules for whether a cargo is available are slightly more complicated than I thought. Here's a list, where earlier conditions outweigh later conditions, and all cargos start in a 'limbo' state:
  • Cargos that do not exist yet in the current game year (or do not exist on the start date of a tutorial) are disabled.
  • If the wartime special condition is enabled, then anything that isn't meat, cheese, weapons, ammo, diesel, or clothing is disabled.
  • Passengers and mail are enabled.
  • For each port or warehouse enabled in a region containing at least one building, all cargos it generates are enabled.
  • If Barracks are enabled, then Troops are enabled.
  • If Recycling Plants are enabled, then Waste is enabled.
  • If a building is type-2 (farms + factories), is not a port or warehouse, is not a recycling plant, and is enabled in the Industry page, then all of the cargos it generates are available.
  • All remaining cargos are disabled.
Implications:
  • Custom-placed ports and warehouses do not contribute to cargo availability, but ports and warehouses potentially generated by a region do. I think this explains why Bombardiere and I are seeing different behavior. Thought about just always enabling any cargo specified in a warehouse or port consist, but that breaks several scenarios that have unused recipes. It's also too expensive to scan all placed buildings for cargo generation.
  • Type-4 buildings (stores, windmills, school houses, stadiums, etc) won't contribute to cargo availability, though I believe they can produce cargo.
  • Troops are not a wartime cargo!
  • The express skins (Prisoners, Newspaper, probably Money and Valuables) may cause trouble, as they won't have special cases like the 'Troops' entry above without additional code.
Tested part of this by adding my test warehouse to region 00's distribution - sure enough, the new cargos showed up.

[Edit - discovered more details about the region rule]
Last edited by milo on Sun Apr 29, 2007 1:43 am, edited 3 times in total.
milo
Engineer
Posts: 512
Joined: Sat Nov 11, 2006 5:36 pm
Location: End of the line

Unread post

Cool. Got most of the new cargos working. Looks as if we're still short an Ore icon, though I can probably do some manipulation of the Bauxite icon if necessary. Several of the icons, particularly Rock (Gravel), may need a single-pixel black outline to avoid becoming blobs against the green dialog background. Overall, though, this set looks terrific.

I'm also considering dropping Money to a Mail skin and introducing 'Crystals' as its replacement; while there's not a huge volume in them, they double as a futuristic cargo and as an input to production of Electronics and Valuables.

For some reason RT3 doesn't like the TGAs. Converting them back to .DDS files seemed to satisfy it. Not sure why. Sorry for wasting your time, pure al!

Still don't have skins working. Worst case, I can build an external utility that alters the cargos in a .gmp; that approach has the advantage that we can override anything about the cargo when skinning it, rather than just the name and icon, but makes scenario creation and editing a little more cumbersome.
Gwizz
CEO
Posts: 1100
Joined: Sat Nov 11, 2006 6:45 pm

Unread post

A side note: Could a building from RT2 be used as the starting point to convert it for use in RT3?

To save some time, I was looking at the RT2 retail buildings as a starting point for creating a 3d factory in RT3. As I study the manual, it might be easier to just start from scratch.
milo
Engineer
Posts: 512
Joined: Sat Nov 11, 2006 5:36 pm
Location: End of the line

Unread post

Not sure - I haven't looked at the structures in RT2 much. Would probably recommend against it, because it would then require anyone using the new building to own a copy of RT2 as well as RT3. Admittedly, many of us do, but...
User avatar
bombardiere
Dispatcher
Posts: 425
Joined: Tue Nov 14, 2006 9:07 am
Location: Turku, Finland

Unread post

Gwizz, No. Buildings in RT2 aren’t 3D. Just 2D pictures with several sides. AFAIK that is…
However, if you know for example MSTS model maker´, these models could be converted to RT3. At least in theory, and premission is need of course :)

Otherwise look great Milo. 8) I’ll get my ideas for prices later today.
User avatar
Hawk
The Big Dawg
Posts: 6503
Joined: Fri Nov 10, 2006 10:28 am
Location: North Georgia - USA

Unread post

I'm a model builder for MSTS stuff. I use TSM though.
Be right back. :wink:

Edit 1: See this post.
Hawk
User avatar
pure al
Dispatcher
Posts: 306
Joined: Sat Dec 23, 2006 11:38 am
Location: British Rail Class 450

Unread post

Excellent work Milo!
Several of the icons, particularly Rock (Gravel), may need a single-pixel black outline to avoid becoming blobs against the green dialog background
Give me a list and I'll get it done in a few minutes for you (edit: by black you mean transparent, not hitting the edges?) :D
I'm also considering dropping Money to a Mail skin...
Do it, I really don't mind. Did you like the deuterium icon?
For some reason RT3 doesn't like the TGAs
Hmm, try removing the capitols? Otherwise did the icons loose much quality when you converted them to dds?

I should still have a number of new building files. I haven't re-textured them, but I think giving a 3D building model a new texture will make it look very different. Plus you can remove certain parts of the buildings (chimneys/sheds etc) by not giving them a texture, thereby giving certain buildings a completely new appearance. I haven't tried it yet, and I probably forgot everything bombardiere taught me, but in theory that should work.
milo
Engineer
Posts: 512
Joined: Sat Nov 11, 2006 5:36 pm
Location: End of the line

Unread post

pure al wrote:Give me a list and I'll get it done in a few minutes for you (edit: by black you mean transparent, not hitting the edges?) :D
Black, actually. Just a pixel or so, antialiased if you're fancy. Take a look at several of the existing icons: they almost always have a faint outline that improves their contrast. Ours look a little fuzzier in comparison. Issue applies to pretty much the whole set, but Rock and Electronics are the ones I notice it most on. Thanks!
Did you like the deuterium icon?
:) Quite. Very quantum!
pure al wrote:
milo wrote:For some reason RT3 doesn't like the TGAs
Hmm, try removing the capitols? Otherwise did the icons loose much quality when you converted them to dds?
I got something like "PIPMipMapError: No valid DDS/TGA/JPG file can be found" when I tried to use them. The contents looked fine under a hex editor, so I'm not sure what was going on there. Converting them to DDS with the same capitalization worked fine, though I probably lost detail from your originals.
I should still have a number of new building files. I haven't re-textured them, but I think giving a 3D building model a new texture will make it look very different. Plus you can remove certain parts of the buildings (chimneys/sheds etc) by not giving them a texture, thereby giving certain buildings a completely new appearance. I haven't tried it yet, and I probably forgot everything bombardiere taught me, but in theory that should work.
!! Hadn't thought anyone would be constructing these so soon! Um... yikes, if you're pursuing this already, then I have more work to do on the translation code.
User avatar
pure al
Dispatcher
Posts: 306
Joined: Sat Dec 23, 2006 11:38 am
Location: British Rail Class 450

Unread post

Don't rush anything Milo, I had around 4-5 buildings constructed a few months ago for the scenario I was working on. But they were using the original 3D Model/textures so not really 'new'. Gwizz, Hawk, Bomber, anyone, I'm not taking over, I'd really like to see some of you involved in creating new buildings :D

p.s Gwizz can you remind me how to make a building appear in it's upgraded form like you did for your port? I can't find it :oops:
Gwizz
CEO
Posts: 1100
Joined: Sat Nov 11, 2006 6:45 pm

Unread post

I don't remember but I have it written down. I'll look for it.
The Gwizz Port was made for me.

A small station and a port were combined.
User avatar
bombardiere
Dispatcher
Posts: 425
Joined: Tue Nov 14, 2006 9:07 am
Location: Turku, Finland

Unread post

Don't rush anything Milo, I had around 4-5 buildings constructed a few months ago for the scenario I was working on. But they were using the original 3D Model/textures so not really 'new'. Gwizz, Hawk, Bomber, anyone, I'm not taking over, I'd really like to see some of you involved in creating new buildings
I am interested in making a pottery, as it was my idea. Slowly… Time is limited as usual… and what time I have for Tycoon, I use it for couple British Rail projects. And learning Blender…

p.s Gwizz can you remind me how to make a building appear in it's upgraded form like you did for your port? I can't find it
Building upgrade is in the code. I don’t know it works fully. But for the skins, it recycles existing skins. And there is upgrade 3dp files. “Upgrade1” additions for every 3D file.
User avatar
pure al
Dispatcher
Posts: 306
Joined: Sat Dec 23, 2006 11:38 am
Location: British Rail Class 450

Unread post

Cool. Gwizz I still can't find the code, if you could point me in the right direction that would be great. Unless Bombar you're saying Gwizz port skips the un-upgraded 3dp and uses two upgraded 3d models, that must be it! Thanks.

Otherwise guys here's the Ore Mine with a Coal Mine behind it:
Image

Here's the Ore Icon:
Image

Any comments?
Post Reply