#STL progress updates
1 messages · Page 1 of 1 (latest)
and I also have no video to attach as I pressed my recording hotkeys without OBS open
there we go

I can't imagine how many bugs this thing has currently
I'm scared to even mess with players modifying the schedule
Can you disable that in /permissions ?
there's add station and drag schedule
yeah disabling both of those work, and I think I'll end up doing that for the actual mod
something something entity copy paste though
hmm
okay I did some testing with permissions and I think I have to allow people to add stations to the schedule, but everything else can be disabled
as in removing stations, pressing the go to station button, that kind of stuff is a no no
Although personal trains are taking a bit of a hit
yeah I'm trying to keep that in mind
I think I might just set a flag on the LuaTrain to see if it's in automatic automatic mode
I'm trying to make it so vanilla schedules can be done completely in the gui as well
and so far it looks like they can
like I don't want people to be able to do vanilla train schedules in the train gui at all, but there still needs to be some way to have a train in automatic mode without triggering all of the modded logic
specifically so people can do temporary stops while riding
I think I'm just going to ignore it completely and focus on getting the mod to function, then after that I would have a clear idea of what needs to happen regarding the player
Be warned that messing with permissions will invoke the ire of some scenario authors for some reason. They hate it when mods mess with permissions.
If it's the best solution, then go for it, but some people are gonna complain 🙂
yeah the main problem I'm facing with vanilla schedules being possible with the mod is I don't know if I want to enforce it
since you can (or at least will be able to) do everything in vanilla with the mod, I'm heavily considering turning all existing schedules into the mod format and not allowing people to do it otherwise
IMO I think you should keep the vanilla GUI interactable
the main reasoning behind that is if you want vanilla schedules in the train gui, why have the mod installed in the first place
I can have the GUI be interactable while still disallowing vanilla schedule creation in said GUI though
That's what I meant, sorry. I don't think you should prevent editing the schedule
Someone will probably report it as a bug if you disable it 😄
maybe I'll make it so you can't add more than 1 non-temporary station to the gui
¯_(ツ)_/¯
that way you can still make trains go to specific stations, but the mod is still in control
Whatever you decide, I hope it works out for the best
thanks
it's a bit much to think about this early without some of the underlying logic in place yet
Definitely get the mod working semi fully before worrying about details like that though
Yeah
I mean the mod technically works right now, it just picks a random station in it's list or does that "repath" if there isn't one
still need to implement wait conditions, priorities, fuel stops, and all the bells and whistles
not that it's necessarily important, but do you guys think I should have physical confirm buttons for anything that needs a confirmation? right now it's just the add category button, you either have to press enter to create it or esc/press the add button again to cancel it
that way people don't get confused on where buttons are
I just had the horrible idea of storing data in the wait conditions of a temporary stop so I don't have to store state of trains
but that's probably a bad idea
huh, if you hover over the station x button it highlights all of the wait conditions as well
Yeah, because it'll delete all of them
well yeah, but you'd think that would be obvious since you're deleting the station
should have posted this earlier but styling on the wait conditions is done, still need to figure out how to do the or/and button
I also forgot that deleting categories in the destination list is completely broken so that's getting fixed soon
you know what's weird is that ever since I've started working on this mod I've been seeing mentions of LTN everywhere
probably confirmation bias at it's finest, but at least it motivates me to keep doing this
lol, destinastions
any ideas on how to make the "Categories" and "Stations" headers look like headers? currently they're just subheader frames which look almost exactly like list buttons, and I don't really want to change the height
could change the text color, could make the frame the same color as the surrounding frame to make it look more like there's two separate lists
color would definitely be good. all titles have a slight yellow tint (you can use predefined styles for lables)
I still kinda want to change the frame style as well cause it looks a little weird mixing subheader and list button styles
label color will definitely change
I've had a mega brain moment
what if I move the add buttons to be the headers for the things
saves me some header space that I could use for other things
okay this looks way better
besides the dumb scroll pane frame + subheader frame border thingy
trying it out since I don't know if I'll like things until I see them, not sure how I feel about centered text
Eh not sure I like the buttons being below, except if there really is no space in the toolbar
Could make the text shorter by removing the 'Add ', the plus sign should explanative enough
But I think having non-square buttons there is fine actually
there's a feature I haven't implemented yet that I need the subheader space for (multiple lists per station)
so that would probably be a + tool button with a toggled textbox and a dropdown
Alright
Well it‘ll be easier to judge once that‘s in there too, for me at least
Always gotta see it in the flesh :p
yeah I'll put a dummy in there
Oh, what might be an improvement is to have the + buttons be on one line side-by-side, not one after the other
Might also be weird though
It‘s weird anyways for them to be part of the list, and they add to that list which makes sense, but they add two different things, but are visually on the same level, if that makes sense
Feels like they should be differentiated somehow if possible
Oh wait
Do this!
Makes the most semantic sense
Meaning have the header 'Stations' with a plus button after it
Sorry I might have misinterpreted your thing before, but yeah I‘d just add a + button to each header
instead of making the header the whole button
I should clarify: there are two lists, one for stations and one for categories, but in the example image there are no categories in the category list so it looks like they're just both at the top
Yeah I missed that part. I don‘t like the buttons as headers idea tbh
Esp since the buttons to add things tend to be at the bottom of the list as the last item, not the first
So I‘d either put them there or do a simple + button next to the header text
yeah it would definitely be at the bottom if it weren't for the fact that there were two lists that need differentiation
anyway that's what it looks like in context, I added the dummy drop down and add button, and put some categories in there for example purposes
Don‘t like it in context either, breaks with convention too much 😅
fair enough
You do you of course
yeah I'm open to ideas, my main issue was the distinction between the two lists
if I did headers with add buttons in them, I'm not sure how to make the headers look
Like you had them here I‘d say
And add a green square button with '+' in it
I could also have the wide add buttons in the list at the bottom like vanilla does with things
and just have both the header and the wide button
Yeah that‘s an option
It‘s funny, I thought about this before since I‘ll have a similar situation in FP when adding multiplayer sharing. Hence the strong opinion :p
what about
cut the list in half vertically
Yeah I imagined my thing as more separate lists as well
hmm
I was considering having split lists, however you're probably going to have more stations in the list than categories, if you're going to be having both types
you can add logic to automatically adjust the heights to fit more things
Or have a single scrollbar for both, but that might be worse.
it does that now /s
or just have a shorter categories lists in general if you prefer fixed sizes
it automatically adjusts the height of the station list to line up with the bottom of the category list 
aka vertical alignment
honestly even though it goes against the norm slightly, I kind of like the buttons the way they are now since it's a very clear distinction between which list is stations and which list is categories
that's the main thing I wanted for this, having it be "one" list with distinction between which half of the list you're on
hmm, horizontal scroll bar appeared
that's where the policy comes in right
Scrollbars are black magic sometimes
scollpanes are probably one of the most broken things in gui, but I don't think that's the case here. Looks more like you set a fixed width on the content instead of making it horizontally stretchable and setting the width on the scroll pane. At least I'm expecting the latter to work
I'm pretty sure I set the width on the scroll pane
and never on any content? 🤔
I mean you can set the horizontal scrolling policy to never, probably better that way anyway
just thought of an interesting concept, not sure how I feel about it
currently when you add a category to a station's ruleset, it's essentially just a shortcut to any one of those stations
I was thinking if there was another dataset of stations called a group or something would be useful, where a train has to visit all stations in the group's list before going to a station in the group's next station ruleset
but I'm not sure if that's even useful, and I don't know how I would present that data in the gui
like you could effectively do the same thing currently by making a train go from station A to B to C, then D, since all a group would do is let you visit A B and C out of order
on a side note, I'm thinking of changing the left side of the GUI from a list box to a scroll pane with lost box styles and implementing the logic myself, that way instead if removing and adding things to the list when filtering I can just set the button's visible property, but I don't know if that would help anything
how will the next station be determined, I mean the train HAS to pick one right?
if there are no other things in the way like train limits or whatever, I suppose random
that or keeping track of which station was visited the longest time ago
if your aim is to simplify train logistics I suggest abstracting that part from the users. But for the sake of discussion, I just want to point out that the construct you described is similar to stations with same priority?
Cybersyn handles it in the backend by doing round-robin (like you have mentioned) if it is a provider deficit situation, and closest station if it is a provider surplus situation.
well there's no internal difference between any one station or another so round robin is probably what I'll end up doing, but yeah I probably won't be doing the group thing cause it's just unnecessary
you technically don't need categories either, but that makes it so much nicer to add new stations to every ruleset
also, it technically doesn't
it can sit at the previous station and "repath"
🤔 I have just joined this discussion, I have no idea what black magic was involved
is the mod trying to insert a new schedule everytime the inactivity timer is up?
yeah pretty much
there's only ever one station in the trains schedule
it's completely event based
do you have a repo for us to play around?
I'll probably have some flying text about no station or something
^ ye that seems like a good idea
it's local for now, but I'm not against it
I can upload it to github if you want (or just send the zip lmao)
hmm it is your decision, uploading to github means we can follow it easily
oo... there's no read-only access for personal private repo on github
it's all-or-none
heh
hmm
I forgot that I'm using my personal gui library so here's both of them that way I don't keep you waiting
I was in the middle of doing wait conditions so they're going to appear on the right but they don't do anything yet
so in your mod a train's schedule is determined by the stop? Any other way to branch differently? Say the stop is serving as a multi-item requester
currently no, but you will be able to have multiple lists per station and you can choose which list a train will be able to go to
for that multi item requester let's say it's a green circuit input station, you'll be able to specify list 1 and list 2, list 1 will be the iron plates dropoff and list 2 will be the copper plates dropoff
however you could get away without doing that by just naming the station "Green Circuit Input" and telling both the iron and copper provider stations that they're allowed to go to that station
since it's going to be empty afterward, it doesn't matter where it goes
you know that's kind of funny that it gets simpler if you don't do it like vanilla
this is worded weirdly, I'll rephrase
let's say you wanted two individual resource loops, one for iron and one for copper, and you wanted them both to go to the same station
in that station's lists, one would have the iron provider and the other would have the copper provider, then in the iron provider's list it would have the specific list for green circuits to go back to the iron provider, and the same for the copper
however if you allow a train to go to any provider station after leaving the circuit station, you can simplify that completely by having the circuit station allow going to either one of those stations after leaving, since the train would be empty
the keybind to open the gui is shift + T by the way
that was after I tried to delete the old station name
yea, I had the old station name in the list before renaming
rename -> saw the old station name still in the list -> proceed to click delete -> boom
okay I can't repro it, let me see...
yeah no I got it
that didn't use to happen but I just changed around the station and category lists
somehow only one of the old names is left in the list, tried it with three stations
ah okay
if you do it with one station it happens
place one, add it to it's own list, rename, then delete the old name from it's own list
okay... so how do I get the train to move? I have this and the train is at AmbientKiller but it is not moving
is it in automatic and does it have that station in it's schedule already
right now you have to tell it to go to that station once to kickstart it
interesting
I didn't actually check if the mod was working before zipping it
there's a do return end in trains.lua
I put that in there cause I was trying to load an existing save and I haven't made it work with that yet
since you'll be able to do vanilla train schedules with this mod I'm probably just going to auto convert all existing schedules into this mod's format and force people to do it through the GUI, that way I don't have to have the headache of having two systems operating at once
okay I commented that line and it started working
nice
is the category function similar to rai's train groups?
yeah, except it's for stations and not trains
interesting concept 🤔
say for example you make a "provider" category and tell all requester stations to go to that category
any station you put in the provider category effectively gets added to all requester station's lists automatically
that way it's super easy to introduce new resources into the hypothetical many to many network
this is like tagging but for stations 🧐
I'll need to internalise the concept more before coming back with more horrible feedbacks
lol
thanks for the share
yeah it takes a little bit of getting used to
once you wrap your head around the concept that stations are controlling everything instead of trains it gets a lot easier
you can also think of it like a graph where nodes are the stations and all of the connections are one directional
then trains are traveling along the graph
I'm very proud of this concept as a whole, instead of forcing the provider requester mentality
How do you control the number of trains serving a path under this concept?
you don't
Do I have to?
not really
Sorry but it is still new to me lol
I mean if you have a closed loop system you might want to monitor how many trains are in there but if it's a closed loop the number of trains in it will never change
I'll most likely be adding number labels to the stations so you can see how many trains are going to or at each station
Say I see a path is underserved, I just throw more train to the depot and it solves it magically?
Cool
if that's the way you have your network set up
Ye was about to suggest that
this mod is more of a generic tool to create your own system
but yeah if your network is many to many and it's one large graph, you can absolutely just throw more trains in if you're running low
You can even extend the mod to provide visualisation for the user's system to show where the trains are in the graph
I was just thinking that
Instead of just numbers
Pretty sure you need another name for this, instead of "Simple" 
yeah scope creep
it's low priority, making graph visualizations look good is hard
but it's not off the table :P
to be fair, the rules of the system are simple
each station has a list of next stations that the train picks from
Is there an easy way to set train limit from your mod?
no, that is still vanilla
Yea
ah yeah that wouldn't be too hard
Since the flow of trains in a system is gated by station limit
I was thinking more along the lines of dynamic limits where it turns to 1 if it is accepting items
and 0 if it's closed
that you definitely can't do with the mod
But the upper limit will be dependent on how the user designed their rail?
if they decide to do that yes
Default 1 when there is a need for inc train will avoid problems yea
I don't see why it wouldn't work with dynamic limits that go above 1
it would be the almost the same as it would vanilla trains, except I somehow have to make trains choose stations that don't have their limits fulfilled
don't know if there's API for that but I'm ignoring the problem until I have to deal with it
If a user designed a station that can only accept one train then it will jam their rail?
if it can only accept one train then only one train will go there
the mod isn't going to tell trains to go to full stations
unless that's the only station in the list, then it will wait
and if all stations in the list are full, it will sit there "repathing" until one opens up
(again it doesn't do that yet but it's planned)
Sorry but I cannot get your concept of dynamic limits, sounds like static to me in this case
it doesn't matter what kind of limit system you use, when a train is picking it's next station it will attempt to go to one that's not destination full
if you're asking what happens in a system when there are a bunch of static limit 1 stations and not enough trains to fulfill all of them at once, and they get "stuck" at the station eventually, that's user design error
Ok let's put dynamic limits aside for now. My point was that I felt that it will be useful if one is able to easily adjust the static train limit from your mod.
If it doesn't crash
shush I already fixed that in dev
hmm
minor thing I have just noticed
since the system currently only has it so a train has one non-temporary station in the list at once, I'm pretty sure you can't make a train go to a station of the same name that it's currently at
however in vanilla you can list the same station in the schedule twice to make it go between stuff
when you assign new schedule put the temp stop before the named station?
or actually, I don't think I understand what's the problem here lol
it's the fact that I'm not making trains progress from station to station in their schedules and instead writing over each other
normally in vanilla if you put two station A's in the schedule it would loop between any number of stations labeled A
with my mod, it's resetting the first schedule index to be A so it never leaves
I think
I haven't actually tested it but I'm 90% sure that's what would happen
I've broken my popup completely so I can't really test anything until I fix it
Make it so that when it is the only station in your mod's list, have two similar stops?
if it's actually an issue I might just hard code the edge case
I could see that potentially being useful for multi-item delivery, like one where each station provides a less-than-full-trainload quantity each of different items, before delivering them all to the last station. Or potentially the reverse, like resupplying outpost with steam, repair packs and bots. Something along those lines.
the only thing it actually does is randomize the order of visiting a few stations, which I don't think is necessary
you can just make the train visit each station in order and it will accomplish the same thing
That's true.
one of the main things I haven't figured out that I need to before working on the schedule conversion is looped schedules
where you have A B A B A B C repeat
conceptual
I can do that in lua easily, I just don't know how to make the interface for it
I mean technically you can do it with the different station list thing and fake it but that's just as bad as vanilla, if not worse
it would get the job done but it would be ugly
for some reason i just have the mental image of that playlist repeat symbol somewhere in your gui
maybe I can have another tab for "Routes" where you can create linear routes of stations and you can send trains to that route
or maybe the whole concept of having lists of valid stations per station is dumb and I should be doing routes from the start, but allow trains to switch routes
that would at least be a little more familiar for people who have vanilla experience already
i was sort of thinking you could er, 'lock' two or more stations together as a schedule and the trains would switch between these categories/groups as determined by your system
how would that differ from vanilla, if you don't mind me asking?
well trains wouldn't be locked to one
after finishing a route, they can choose from the outstanding list of routes or go to a depot or something
ah that sounds like what i was just describing 🙂
that doesn't really mesh too well with station prioritization though
actually wait, it might
I'd have to think about this
If we're talking a specific station, it might have to be done as a slightly differently named/grouped station + you having someway to prioritize a route being selected over others
but that's more complex
actually, have you already got/planned a way to 'disable' a category? For example all stations that accept green circuits have full buffers; i wouldn't want a train to enter into that category and get loaded up with green circuits and then just be stuck waiting for it to empty
yeah and have them stuck going

in the middle of an intersection
trains will remember the station they last visited and pick a different one if there's another in the list
This is going away in 1.2 anyway
however if they already loaded up with green circuits for example, then they will wait for a green circuit station to open up
you just prevent them from going to the green circuit pickup station in the first place by setting the limit to 0 when there's not a station that needs green circuits
yeah, i just wanted to make sure that the mod would be taking that into account