Factorio-Access / FactorioAccess

An accessibility mod for the video game Factorio, making the game accessible to the blind and visually impaired.
Other
24 stars 9 forks source link

audio rulers #161

Open ahicks92 opened 6 months ago

ahicks92 commented 6 months ago

1. Is your feature request related to a problem? Please describe.

Sort of: if you have to zigzag, getting back to the original line is slow and this gets worse the further away you get. If using build lock, undercounting is a problem and overcounting can weirdly be worse if you sideload another belt.

For an example look at my attached save. There's the rail line on the east and the pumpjack on the west. To get across around all those cliffs and whatnot requires maintaining the horizontal line across all of those cliffs even when you've got to turn and also use underground belts.

2. Describe the solution you'd like

Something I've talked about on Discord a few times is "cursor stops". We figured out that calling them audio rulers is way better and now that I have an example save for us to discuss somewhat it seemed like the right time. There's a lot audio rulers could do, but this is what I think the basic flow should look like:

So, how you can use it, and why I think it justifies the complexity:

There's a lot of other places I can see it being used. One other thing it does is lets your cursor move away from the line to go check on something without having to go nuts finding it again. Another example is that you can place a ruler 2 tiles from a machine to know where to bring the belt in to be lined up for inserters.

There may be cases for other tools that specifically solve a specific problem, but this would solve most of those. Indeed while it might make sense to control the width of the ruler as well as the length, you could even get that just by using two of them side to side.

3. Describe alternatives you've considered, if any, perhaps including previous discussions

Basically everything else the mod does. This is one option for taking a lot of smaller isolated pieces and pulling them together into a workflow that scales in a way which doesn't require counting off accurately and leads to mistakes like mixing belts and having to go fix the 200-unit lane because it's now holding 3 items, etc..:

That's just not something we've really started on.

4. Additional context

See my save.

There's a lot of room for tools like this but this is the immediately useful one. As one other future direction, projecting grids of these lines has other good uses, for example if you can do 3x3 then you now have the ability to place assemblers and lanes between them and that literally would mean having two blueprints to alternate between and "fill out the tiles".

For a use case for 3x3 with a 1-tile gab between them, see my lab array (it's flawed in other ways but...).

100% not saying we should do this, just offering what I consider obvious future directions for such things. We should see how much people like the first version.

Not sure how to teach this. There's probably lots of places in the tutorial we could fit it in. Early ones at that. Depends on if people find this to be an unnecessary digression or something super useful, but that's chicken-and-egg because first they need to know how...

ruler.zip

ahicks92 commented 4 months ago

So here's another use case, and in particular a use case for two instead of just one. If we had a way to specifically skip to the next ruler in a given direction, you can line a bus with them. The typical bus doesn't work well with other kinds of cursor skipping because it's belts with gaps, so my 70-something tile wide bus is like 20 skips. That is, another way to view this is bookmarks for lines. Like how bowling alleys have gutters to use a somewhat visual metaphor.

I could see up to 4 getting involved: west side/basic plates/fluids/right side. Makes a "category selector" for lack of better phrasing.

LevFendi commented 4 months ago

So this week i made a first prototype by converting the single cursor bookmark into a basic audio ruler.

features so far

It uses the game's own programmable speaker instrument sounds, with different instruments for cardinals versus diagonals, and different pitch for full aligment versus 1-tile-off-alignment.

You turn it on by setting the bookmark and vice versa. It has no range limit.

Improvements quick list

  1. Cursor skipping should be interrupted when intersecting with the outer edge of a ruler. Same for build lock.
  2. The mod should support at least two bookmarks to enable more use cases
  3. You should be able to control the ruler length for each bookmark separately, including zero for turning it off. Maybe just allow typing it in.
  4. We can use better sounds, like maybe the speaker piano group.

bookmarks versus fast travel points

We might want to name bookmarks too but then we are already blurring the boundaries between bookmarks and travel points. Perhaps we should combine the features. The remaining issue after that would be adding travel categories so that the list is shorter.

ahicks92 commented 4 months ago

Yeah, let's just move discussion here. You captured Discord above.

I think we should move the sounds to be "thematically correct". The rest of the mod has done a good job at that. The current option isn't really so great as has already been discussed, but the other thing is that this would be the only place in the mod which isn't matching theme, and it's a bit jarring. Weirdly the diagonals sort of make sense. Also Factorio is weird about sound too, in that even things like constant hums aren't used when they'd make sense. I have actually weirdly enough heard a real-life steam turbine and after that the steam engines are quite, quite amusing. If I had to describe the Factorio "theme", I'd say quiet synth percussive. I will look into this. If the programmable speaker isn't sufficient I believe I may have some public domain sounds which would be appropriate around.

I don't understand the use for diagonals which is code for let's drop them but you probably had a use case in mind. If you imagine how two vertical rulers would intersect you can see that what really begins to happen is the formation of a square grid with squares rotated to 45 degrees on top of a grid with squares in the cardinal direction. Add horizontal ones, and it starts to become a grid of triangles. All of non-uniform size. Since the only thing that can move at an angle is trains, I'm not sure that these are useful in any way. But if there is a use case do share, it may very well be useful to even myself.

ahicks92 commented 4 months ago

I verified that pan issues are from programmable speaker's sound base itself.

Few things in there that might be more fitting. Few things in there that might also be workable for prototypes of graphing stuff. But sadly few is doing much heavy lifting, in my opinion.

LevFendi commented 4 months ago

As another short term improvement before releasing our current version, I propose that we modify CONTROL + SHIFT + B to toggle the ruler functions on or off rather than to clear the bookmark (which happens anyway when you set a new one).

LevFendi commented 3 months ago

In PR #223 for Update 0.13.0 we have released a prototype version of a single audio ruler. It needs to be interfaced with cursor skipping and build lock mode but it works.