Space Trains


Adds futuristic trains designed for Space exploration. These trains are faster and have more capacity, but are more expensive to build

Content
1 year, 1 day ago
1.1
16.6K
Transportation Trains

b [Fixed]head on collision with a manually driven space train causes crash.

1 year, 2 days ago

The mod Space Trains (1.3.4) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event Space_trains::on_tick (ID 0)
Space_trains/control.lua:196: attempt to index field 'train' (a nil value)
stack traceback:
Space_trains/control.lua:196: in function <Space_trains/control.lua:194>

1 year, 2 days ago

Traced it back to a cause. If a locomotive to locomotive collision would cause one of them to be destroyed, then the attempts to reverse the damage won't have any effect and it will still be destroyed, and next tick, there will no longer be a valid entity to connect.

1 year, 2 days ago

I see, I'll look into it, thanks for the report

1 year, 2 days ago

I updated the mod with a fix for the crash

1 year, 1 day ago

The mod Space Trains (1.3.5) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event Space_trains::on_entity_damaged (ID 103)
Space_trains/control.lua:190: attempt to compare number with nil
stack traceback:
Space_trains/control.lua:190: in function <Space_trains/control.lua:182>

Still happened in my testing.

1 year, 1 day ago

I even decided to go for very slow movement, so as to not destroy the locomotive, and it still crashed instantly.

1 year, 1 day ago

Weird, I can’t reproduce the bug, can you send a screenshot/ savefile

1 year, 1 day ago

Sorry to interrupt.

I just found out control.lua might be completely redundant.

I was working on my fork that makes trains smaller and I ran into similar issue as well.
Removing it for some reason removed the crash for some reason?

1 year, 1 day ago

well, because control.lua is used to bypass an engine limitation that has to do with connection distances, and is necessary unless you want to couple every piece of rollingstock manually

1 year, 1 day ago

wenn making the trains smaller, the connection distance no longer exceeds the 4 units that the engine is limited to, making it work without the script

1 year, 1 day ago

The bug I think can happen as a result of not having built anything since updating the mod from an earlier version, and causing two locomotives to collide by any means, since the Valid_build variable is not initialized until at least one entity is built since mod update.

1 year, 1 day ago

I See, I’ll implement a fix once I’m done with school for today, also thanks for the report and cooperation

1 year, 1 day ago

I just uploaded another hotfix, can you check if the problem still occurs?

a year ago

I can confirmed that it is fixed now.

a year ago

okay, once again thanks for the bug report and cooperation, I'll mark this as fixed now

New response