Burnys Train Station Blueprint Creator

by Burny

A helper mod to quickly create train station blueprints for different train lengths and individual needs.

Content
4 years ago
0.14 - 0.18
46
Blueprints

b Game Crashes When Using With Cut and Paste Mod

6 years ago
(updated 6 years ago)

When attempting to create a train station blueprint when holding the copy tool from the Cut and paste tools mod, the game crashes. The following error message is displayed on the way out:

Error while running event
BurnysTSBC::on_gui_click (ID 1)
Given item is not a blueprint.
stack traceback:
BurnysTSBC/control.lua:840: in function
'holding_empty_blueprint'
BurnysTSBC/control.lua:929: in function
<BurnysTSBC/control.lua:849>

The copy tool is probably not an actual blueprint which would explain it not working, and its not really designed for using in this manner, but I have been using it as a temporary blueprint. So my curiosity led me to attempting to use it with your mod, which led to the above crash.

PS: The mod does work as expected with a normal blueprint.

6 years ago

Thanks for the notification!
I tried to replicate the "bug", and found the issue, but to be completely honest, I don't know what I should do about it. :D

I changed my mod now so that it should no longer crash but also no longer try to create a blueprint when holding cut/copy tool in the mouse cursor.
Using one-time-use blueprint just for my mod is a good idea, sadly I have no idea how to implement it without adding a new item to the game. For now, people will still have to create a station from the mod, place the blueprint, then delete the blueprint. I can't figure out an easy way to implement a one-time-use blueprint.

The code of the copy-paste mod seems not that easy to understand, otherwise I'd try to implement it.

New response