[posila] [1.1.19] surface.create_entities_from_blueprint_string does not include train fuel

This subforum contains all the issues which we already resolved.
Post Reply
Xorimuth
Fast Inserter
Fast Inserter
Posts: 249
Joined: Sat Mar 02, 2019 9:39 pm
Contact:

[posila] [1.1.19] surface.create_entities_from_blueprint_string does not include train fuel

Post by Xorimuth »

This API is technically internal, but very useful for anyone making modded simulations, eg with https://mods.factorio.com/mod/simhelper. I spent a long time working out why my train wasn't driving, because there aren't any 'missing fuel' alerts in the simulation.

To reproduce, see attached mod (requires simhelper). In particular, "prototypes/simulations.lua".
Attachments
SpidertronEnhancements_1.2.8.zip
(406.77 KiB) Downloaded 8 times

User avatar
Klonan
Factorio Staff
Factorio Staff
Posts: 4841
Joined: Sun Jan 11, 2015 2:09 pm
Contact:

Re: [1.1.19] surface.create_entities_from_blueprint_string does not include train fuel

Post by Klonan »

Posting the code here so its easier to test:

Code: Select all

        local bp="0eNq9mc1u2zAMx99FZ2cwRX3YOe8NdhyKwnW8VJhjB7aTrijy7pPipGlTFiGBdZcWiu2fSVF/kaZe1EO7a7ZD6Ca1fFGh7rtRLX++qDGsu6pNv03P20YtVZiajcpUV23SaKhCqw6ZCt2q+aOWcLjLVNNNYQrN/Pxx8Hzf7TYPzRBveH2y3g37ZrU4AjK17cf4TN+lF0WOztSzWi6giOhVGJp6vuYO2Qei5hEhp5FIIPEVOU6Rtn6cPoEu4AS176GegBouFJCGAgG1POcX5oTUt5GObael7bQE1IuheNvSgg31NJSytBRD4balafExqSVNpUwFkFJLhqlMPdmznvLbEgVkMguaSWkU2HrSQDpPzqiVQj1jRtmKMp6EUrsJsBXlBJZeFNX2db/pp7BviN3kpFETif0QIqSar8YlUfdtP6T7huNwHf9+02Bd4bR31trcAZocUecIOnIejimhSreZssixjDfHf2AcOo25cYVP20tKOmPCjn0bVotfu6ZNS8AfKC/YEj47QmL0RbOJ0i3Gqd8SDLxM73ieCPWj3w11mrovmQ/KWvZeoJFcD5QctJZCGSlLs7OrsSSUkoM2Uqi/vcVoZnZ15qwHCuKkq5GOL1vvmp41Mr6FFMrIypotP4MklIov5lKoZZR5IA0NUqFBvko86TAVGmSmTJzTcM6YQsMkFhRRU0R2tjRAOk4GRawXIINy0UtdDet+8VSt45OfQZBIZaHbx3E/xMvdrm2plxRCW2lTS9E2Y24vHpML7SLXtZHKg9y4jBYF4lj6ySNhUGgrmfKNEdWpwNCIscI6jZGXjFQiJemsZ9U3ujwh3lf5b4ud7804hW4e/b+Kx4jFR6rPMNWnZ/Vdf0FTnzuWLb/T5F5/7FELybLViMCHslMXIh/K1iJaPpRd4KHnQ9niREGgnDArsqBeWP+woIWwaGZBS+HXLgfq+OUfP1COrSjLD5RjK8ryA+Wk2Q3IhO6kLRNOW9PJWpDX7VdDIZ2wrwWMhonzUijjC8JJW5BQMiyVtiCBUTP4XNiB1XDbUg9C6LX7pKVa2H3XjFapR8m5gzYM343o3OEaScncW+ERwbXnmE5fxvqxWe3a0/HLpY+XxlC8uWE+3vnYsnqqwnRf993q+MYZEyHbamjuT2dAscDLzudBU9ikp6ZQ/x6TvvPDXfLts/LwH9DvkpvHY6jlm1OrTO2bYZwntwDjS+11qRHQHQ5/AUT7vSY="
        game.surfaces[1].create_entities_from_blueprint_string{string = bp, position = {0, 0}}


posila
Factorio Staff
Factorio Staff
Posts: 4982
Joined: Thu Jun 11, 2015 1:35 pm
Contact:

Re: [posila] [1.1.19] surface.create_entities_from_blueprint_string does not include train fuel

Post by posila »

Thanks for the report.
Fixed for 1.1.20

Post Reply

Return to “Resolved Problems and Bugs”