[MOD 0.15] SmartTrains 2.0.5

Topics and discussion about specific mods
Choumiko
Smart Inserter
Smart Inserter
Posts: 1352
Joined: Fri Mar 21, 2014 10:51 pm
Contact:

Re: [MOD 0.13|0.14] SmartTrains 1.1.2|1.0.3

Post by Choumiko »

Updated to SmartTrains 1.1.3
  • fixed error when entering a train in sandbox/without a character
  • fixed updating error
  • added remote interface for Foreman
  • discontinued updates for the 0.13 version
HiddenWolf wrote:I just updated my game from .14.2 to .14-latest, updated all my mods and ran into this:
Error while running the on_configuration_changed: __SmartTrains__/control.lua:715: bad argument #1 to 'pairs' (table expected, got nil)
According to the line you had a SmartTrains version <= 0.3.82 ? It shouldn't error again with this version, if it still does i'd appreciate the save from before updating (if still available)

Speadge
Fast Inserter
Fast Inserter
Posts: 130
Joined: Tue Mar 29, 2016 10:01 am
Contact:

Re: [MOD 0.13|0.14] SmartTrains 1.1.2|1.0.3

Post by Speadge »

Choumiko wrote:Updated to SmartTrains 1.1.3
  • fixed error when entering a train in sandbox/without a character
  • fixed updating error
  • added remote interface for Foreman
  • discontinued updates for the 0.13 version
HiddenWolf wrote:I just updated my game from .14.2 to .14-latest, updated all my mods and ran into this:
Error while running the on_configuration_changed: __SmartTrains__/control.lua:715: bad argument #1 to 'pairs' (table expected, got nil)
According to the line you had a SmartTrains version <= 0.3.82 ? It shouldn't error again with this version, if it still does i'd appreciate the save from before updating (if still available)
just updated to 1.1.3 from 1.1.2

Code: Select all

Error while running the
on_configuration_changed:
__SmartTrains__/control.lua:753: attempt to
index field 'waiting' (a boolean value)
on a MASSIVE train map (200+ stations)
http://imgur.com/a/CjniI

Choumiko
Smart Inserter
Smart Inserter
Posts: 1352
Joined: Fri Mar 21, 2014 10:51 pm
Contact:

Re: [MOD 0.13|0.14] SmartTrains 1.1.2|1.0.3

Post by Choumiko »

Updated to SmartTrains 1.1.4
  • fixed error when updating
Totally forgot how SmartTrains wants to be updated :roll: should all be fine now

Speadge
Fast Inserter
Fast Inserter
Posts: 130
Joined: Tue Mar 29, 2016 10:01 am
Contact:

Re: [MOD 0.13|0.14] SmartTrains 1.1.2|1.0.3

Post by Speadge »

Choumiko wrote:Updated to SmartTrains 1.1.4
  • fixed error when updating
Totally forgot how SmartTrains wants to be updated :roll: should all be fine now
working :)

anyhow - cant get the "go to signal #" working anymore.
the "go to station #" works.

Choumiko
Smart Inserter
Smart Inserter
Posts: 1352
Joined: Fri Mar 21, 2014 10:51 pm
Contact:

Re: [MOD 0.13|0.14] SmartTrains 1.1.2|1.0.3

Post by Choumiko »

Speadge wrote:anyhow - cant get the "go to signal #" working anymore.
the "go to station #" works.
Did it work before the failed update or are you just getting started with goto signal # ? The train has to leave the station before the scheduled waiting time is over and the signal that carries the station # has to be set in the lamp of the smart train stop.

It works for me, i hope it's not because of the failed update. You could try removing a train from the line, setting it to manual mode, reassign it to the line and set it back to auto. If it still doesn't work i'd probably need the save (PM the link if you don't want it public) or at least a screenshot of a station, the schedule and the rules.

Speadge
Fast Inserter
Fast Inserter
Posts: 130
Joined: Tue Mar 29, 2016 10:01 am
Contact:

Re: [MOD 0.13|0.14] SmartTrains 1.1.2|1.0.3

Post by Speadge »

Choumiko wrote:
Speadge wrote:anyhow - cant get the "go to signal #" working anymore.
the "go to station #" works.
Did it work before the failed update or are you just getting started with goto signal # ? The train has to leave the station before the scheduled waiting time is over and the signal that carries the station # has to be set in the lamp of the smart train stop.

It works for me, i hope it's not because of the failed update. You could try removing a train from the line, setting it to manual mode, reassign it to the line and set it back to auto. If it still doesn't work i'd probably need the save (PM the link if you don't want it public) or at least a screenshot of a station, the schedule and the rules.
thanks for reply: i tried the 1.1.2 again and ran into the same problem.
I used it back in 0.** and tried it now again - needed some time to get back into it but finally remembered. And i got the "go to station #" working - it just seems to ignore the signal.
And in ST menu it says "go to signal # or station #2"

my setup:
connect a constant-comb. with signal green=4 to the lamp (i tried every connection) and set the lamp to green > 0 (know that it doesnt have 2 be true).
the train has either no waiting condition, inactivity or circuit signal (tried all, avoided wait time).
so whatever i do it alwys leaves to the next station, but not to station #4 which would be 2 stations ahead.

When i add the "4" in the "go to station#" column, it works fine. Which is why i think the station-setup is ok.
But just with an activated "go to signal #" column and a given signal, it seems not to work at all.

sorry for messing things up, but thats what i remember how it worked back then and i didnt get any update from dthe description. :(

thanks for help

Choumiko
Smart Inserter
Smart Inserter
Posts: 1352
Joined: Fri Mar 21, 2014 10:51 pm
Contact:

Re: [MOD 0.13|0.14] SmartTrains 1.1.2|1.0.3

Post by Choumiko »

Speadge wrote:thanks for reply: i tried the 1.1.2 again and ran into the same problem.
I used it back in 0.** and tried it now again - needed some time to get back into it but finally remembered. And i got the "go to station #" working - it just seems to ignore the signal.
And in ST menu it says "go to signal # or station #2"
That's ok, it just means that it will go to the signal # OR to #2 if the signal # is not a valid schedule index.
Speadge wrote: my setup:
connect a constant-comb. with signal green=4 to the lamp (i tried every connection) and set the lamp to green > 0 (know that it doesnt have 2 be true).
the train has either no waiting condition, inactivity or circuit signal (tried all, avoided wait time).
so whatever i do it alwys leaves to the next station, but not to station #4 which would be 2 stations ahead.
This also sounds ok to me. Make sure you actually connect the wire to the lamp, i find it easy to accidentaly click on the combinator or stop.
One thing you can try once you're sure everything is wired correctly is using the console command (after backing up the save):

Code: Select all

/c remote.call("st", "findStations")
Your game will freeze shortly while it scans the whole map for trainstops and reconnects the lamps/combinators to them

I've attached a small save with a working train line just as a simple example.
Attachments
testSignalNumber.zip
(2.35 MiB) Downloaded 116 times

Speadge
Fast Inserter
Fast Inserter
Posts: 130
Joined: Tue Mar 29, 2016 10:01 am
Contact:

Re: [MOD 0.14] SmartTrains 1.1.4

Post by Speadge »

Thanks for ur time.

I already connected all 3 entities to the signal for making sure its connected - still nothing.
I wont be home within the next 7h but i will give u some feedback on how ur save worked for me.

Just an idea: as i said i have a massive base... and game does barely make the 40ups/60fps. (4.0ghz xeon)

Could this be causing timing problems?

EDIT: ok, just tried it: console command doesnt help, working signals in your save - so i need to figure out what is different in my save

So i stripped my game down and tried it with ST only, no luck.
http://home.speadge.de/storage/games/Fa ... t_test.zip
Could u take a minute to check it, please?


thanky you!

Speadge
Fast Inserter
Fast Inserter
Posts: 130
Joined: Tue Mar 29, 2016 10:01 am
Contact:

Re: [MOD 0.14] SmartTrains 1.1.4

Post by Speadge »

ok, found the issue. It seems there are SERIOUS Issues when ur station(name) is not starting with a letter.

s1 works
11 totally confuses the train. not just ignoring "goto" - its totally confusing the train even when its moving

Choumiko
Smart Inserter
Smart Inserter
Posts: 1352
Joined: Fri Mar 21, 2014 10:51 pm
Contact:

Re: [MOD 0.14] SmartTrains 1.1.4

Post by Choumiko »

Speadge wrote:ok, found the issue. It seems there are SERIOUS Issues when ur station(name) is not starting with a letter.

s1 works
11 totally confuses the train. not just ignoring "goto" - its totally confusing the train even when its moving
That is interesting :D I'll take a look if this is a SmartTrains issue or vanilla.

Speadge
Fast Inserter
Fast Inserter
Posts: 130
Joined: Tue Mar 29, 2016 10:01 am
Contact:

Re: [MOD 0.14] SmartTrains 1.1.4

Post by Speadge »

Choumiko wrote:
Speadge wrote:ok, found the issue. It seems there are SERIOUS Issues when ur station(name) is not starting with a letter.

s1 works
11 totally confuses the train. not just ignoring "goto" - its totally confusing the train even when its moving
That is interesting :D I'll take a look if this is a SmartTrains issue or vanilla.
as i said: just try my save.
as soon as u rename the stations with a letter on 1st position, everything is fine

HiddenWolf
Inserter
Inserter
Posts: 48
Joined: Thu Sep 24, 2015 1:37 pm

Re: [MOD 0.13|0.14] SmartTrains 1.1.2|1.0.3

Post by HiddenWolf »

Choumiko wrote:Updated to SmartTrains 1.1.3
  • fixed error when entering a train in sandbox/without a character
  • fixed updating error
  • added remote interface for Foreman
  • discontinued updates for the 0.13 version
HiddenWolf wrote:I just updated my game from .14.2 to .14-latest, updated all my mods and ran into this:
Error while running the on_configuration_changed: __SmartTrains__/control.lua:715: bad argument #1 to 'pairs' (table expected, got nil)
According to the line you had a SmartTrains version <= 0.3.82 ? It shouldn't error again with this version, if it still does i'd appreciate the save from before updating (if still available)
Thank you. Updating to 1.1.4 (from the mod portal) fixed this error.
I got another one though:

Code: Select all

Error while running the on_configuration_changed: __SmartTrains__/control.lua:753: attempt to index field 'waiting' (a boolean value)

Choumiko
Smart Inserter
Smart Inserter
Posts: 1352
Joined: Fri Mar 21, 2014 10:51 pm
Contact:

Re: [MOD 0.14] SmartTrains 1.1.5

Post by Choumiko »

Updated to SmartTrains 1.1.5
  • fixed problems with numerical station names
  • and yet another updating error
Speadge wrote:as i said: just try my save.
Must have missed the link/edit.
HiddenWolf wrote:

Code: Select all

Error while running the on_configuration_changed: __SmartTrains__/control.lua:753: attempt to index field 'waiting' (a boolean value)
If you get any more errors when updating please attach/upload the save somewhere, that way i can fix all/most errors in one go :D

Speadge
Fast Inserter
Fast Inserter
Posts: 130
Joined: Tue Mar 29, 2016 10:01 am
Contact:

Re: [MOD 0.14] SmartTrains 1.1.5

Post by Speadge »

Great. Thanks. Tried 2 contact u on steam to have a chat in german, but anyhow- will try out later.

Just nice u found the issue after all.

HiddenWolf
Inserter
Inserter
Posts: 48
Joined: Thu Sep 24, 2015 1:37 pm

Re: [MOD 0.14] SmartTrains 1.1.5

Post by HiddenWolf »

HiddenWolf wrote:

Code: Select all

Error while running the on_configuration_changed: __SmartTrains__/control.lua:753: attempt to index field 'waiting' (a boolean value)
If you get any more errors when updating please attach/upload the save somewhere, that way i can fix all/most errors in one go :D[/quote]

Latest update fixed it.

doktorstick
Fast Inserter
Fast Inserter
Posts: 152
Joined: Fri Aug 12, 2016 10:22 pm
Contact:

Re: [MOD 0.14] SmartTrains 1.1.5

Post by doktorstick »

Would you mind disabling these two messages? They fill the console:

Code: Select all

1120.443 Script control.lua:1244: Checking line, needs update: false
1120.445 Script control.lua:1315:
1130.297 Script control.lua:1244: Checking line, needs update: false
1130.297 Script control.lua:1315:

Choumiko
Smart Inserter
Smart Inserter
Posts: 1352
Joined: Fri Mar 21, 2014 10:51 pm
Contact:

Re: [MOD 0.14] SmartTrains 1.1.5

Post by Choumiko »

Updated to SmartTrains 1.1.6
  • removed some debug logging

Chel
Burner Inserter
Burner Inserter
Posts: 7
Joined: Mon Mar 21, 2016 8:15 pm
Contact:

Re: [MOD 0.14] SmartTrains 1.1.6

Post by Chel »

Hi, I have an issue with this mod, as it seems that it adds the refuel station to the schedule as one would expect, but it does not remove it. A little googling shows that I am not the first to encounter this:

Code: Select all

https://www.reddit.com/r/factorio/comments/4pnim2/a_problem_with_smart_trains_mod/
I have a single large refuelling station, but trains are bunching up there; each loco has in the region of 587 (of 600) coal on board, so there is clearly no need for them to refuel for a long time. Amending the GUI settings in the client seems to correctly influence the first visit, but as the station remains in the schedule, the setting becomes irrelevant thereafter.

Can this be resolved please? It really affects the usability of the mod (and heaven forfend having to do without auto-refuelling).

Great mod otherwise :O)

Adding image to show the effect:
Attachments
refuel.PNG
refuel.PNG (99.03 KiB) Viewed 7914 times

Choumiko
Smart Inserter
Smart Inserter
Posts: 1352
Joined: Fri Mar 21, 2014 10:51 pm
Contact:

Re: [MOD 0.14] SmartTrains 1.1.6

Post by Choumiko »

I did a quick test and it seems to work for me.
Thinks to consider:
- For refueling to work, the Refuel checkbox in the has to be ticked, but since the stations get added that should be the case.
- The refueling station gets removed if every locomotive in the train has enough fuel (So if even one loco has 1 coal/whatever fuel less, refueling is not done). It will be removed when the train arrives at the next station.

To get a bit more info you can use /c remote.call("st", "toggleFlyingText") in the console. It will show some info above the train. For refueling that would be: "Refuel station added" -> "refueling" -> "Refueling done" -> "Refueling station removed"
Chel wrote:I have a single large refuelling station, but trains are bunching up there; each loco has in the region of 587 (of 600) coal on board, so there is clearly no need for them to refuel for a long time. Amending the GUI settings in the client seems to correctly influence the first visit, but as the station remains in the schedule, the setting becomes irrelevant thereafter.
A vanilla loco can hold 150 coal, are you using modded locomotives and/or increased stack sizes? I looked at the code and it shouldn't matter, but just to make sure. A modlist would be helpfull i think.

SoZ
Manual Inserter
Manual Inserter
Posts: 2
Joined: Sun Nov 13, 2016 3:19 pm
Contact:

Re: [MOD 0.14] SmartTrains 1.1.6

Post by SoZ »

Yesterday was running fine, but today, everytime I open a train GUI I get this error:

Error while running event Custom event (ID 56) _ _ SmartTrais_ _/gui.lua:252:attemp to perform arithmetric on fields 'ticks'(a nil value) stack traceback: _ _SmartTrains_ _/control.lua:1478: in function <_ _SmartTrains_ _/control.lua:1474> [C]: in function 'pcal' _ _SmartTrains_ _/control.lua:1474: in functions <_ _SmartTrains_ _/control/lua:1383>

What is this?

Post Reply

Return to “Mods”