Cargo Dependencies

Discuss the new AI features ("NoAI") introduced into OpenTTD 0.7, allowing you to implement custom AIs, and the new Game Scripts available in OpenTTD 1.2 and higher.

Moderator: OpenTTD Developers

Post Reply
User avatar
Zutty
Director
Director
Posts: 565
Joined: 22 Jan 2008 16:33

Cargo Dependencies

Post by Zutty »

Hi all,

I'm been busy for a while but I'm back in business now. PathZilla v6 is underway once more.

I have implemented industry support, but I would like to be able to handle ALL cargos not just raw ones.

Is there a way to find which input cargos are needed for an industry to generate a particular output cargo? i.e. when I provide steel to a factory, goods are produced. I dont need to also provide grain and livestock.

I know its pretty trivial with the default industries, but newindustries seems to be more complex. Unless I'm mistaken, in PBI a steel mill requires iron ore AND coal to produce steel.

Or am I just being stupid? :D

Thanks
PathZilla - A networking AI - Now with tram support.
frosch
OpenTTD Developer
OpenTTD Developer
Posts: 990
Joined: 20 Dec 2006 13:31
Location: Aschaffenburg

Re: Cargo Dependencies

Post by frosch »

Sorry, but the only thing you can do is to deliver the cargo, and observe what comes out the other end.
E.g. the produced cargo can also depend on the amount / ratio the output is transported. PBI's refinery can produce either fuel oil or plastics or both, depending whether one or both are transported.
⢇⡸⢸⠢⡇⡇⢎⡁⢎⡱⢸⡱⢸⣭⠀⢸⢜⢸⢸⣀⢸⣀⢸⣭⢸⡱⠀⢰⠭⡆⣫⠰⣉⢸⢸⠀⢰⠭⡆⡯⡆⢹⠁⠀⢐⠰⡁
User avatar
Zutty
Director
Director
Posts: 565
Joined: 22 Jan 2008 16:33

Re: Cargo Dependencies

Post by Zutty »

Oh OK. Thanks for the reply.

I only just played with ECS vectors for the first time and it scared the pants off me. I had originally planned to model cargo vectors by tracing cargo/industry dependencies, but everything is so highly interconnected that it might be too complex.

I think I'll keep it simple for the time being and stick to primary industries.
PathZilla - A networking AI - Now with tram support.
Post Reply

Return to “OpenTTD AIs and Game Scripts”

Who is online

Users browsing this forum: No registered users and 4 guests