[.15.10] on_train_changed_state not fire when train changes

Bugs that are actually features.
Nexela
Smart Inserter
Smart Inserter
Posts: 1828
Joined: Wed May 25, 2016 11:09 am
Contact:

[.15.10] on_train_changed_state not fire when train changes

Post by Nexela »

/c script.on_event(defines.events.on_train_changed_state, function (event) game.print("changed") end)

Find a train in automatic mode. add a wagon to it. train switches to manual mod but event isn't triggered
Rseding91
Factorio Staff
Factorio Staff
Posts: 16421
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [.15.10] on_train_changed_state not fire when train changes

Post by Rseding91 »

That's not the train changing state. That's the train being destroyed and a new one created.

You want to also listen to the train created event.
If you want to get ahold of me I'm almost always on Discord.
Post Reply

Return to “Not a bug”