`local varname = value` results in `varname` being inaccessible in
the next REPL input. This is often unintended and can lead to confusing
behaviour. We produce a warning when this occurs.
This uses the system described in #409, to render monitors in a more
efficient manner.
Each monitor is backed by a texture buffer object (TBO) which contains
a relatively compact encoding of the terminal state. This is then
rendered using a shader, which consumes the TBO and uses it to index
into main font texture.
As we're transmitting significantly less data to the GPU (only 3 bytes
per character), this effectively reduces any update lag to 0. FPS appears
to be up by a small fraction (10-15fps on my machine, to ~110), possibly
as we're now only drawing a single quad (though doing much more work in
the shader).
On my laptop, with its Intel integrated graphics card, I'm able to draw
120 full-sized monitors (with an effective resolution of 3972 x 2330) at
a consistent 60fps. Updates still cause a slight spike, but we always
remain above 30fps - a significant improvement over VBOs, where updates
would go off the chart.
Many thanks to @Lignum and @Lemmmy for devising this scheme, and helping
test and review it! ♥
Unknown blit colours, such as " " will be translated to black for the
background or white for the foreground. This restores the behaviour from
before #412.
- Write to a PacketBuffer instead of generating an NBT tag. This is
then converted to an NBT byte array when we send across the network.
- Pack background/foreground colours into a single byte.
This derives from some work I did back in 2017, and some of the changes
made/planned in #409. However, this patch does not change how terminals
are represented, it simply makes the transfer more compact.
This makes the patch incredibly small (100 lines!), but also limited in
what improvements it can make compared with #409. We send 26626 bytes
for a full-sized monitor. While a 2x improvement over the previous 58558
bytes, there's a lot of room for improvement.
This functions the same as shell.run, but does not tokenise the
arguments. This allows us to pass command line arguments through to
another program without having to re-quote them.
Closes#417
- Remove the parenthesis around the text (so it's now
"Computer ID: 12"), rather than "(Computer ID: 12").
- Show the tooltip if the computer has an ID and no label (as well as
when in advanced mode).
- Lint references to unknown fields of modules, excluding the keys and
colours modules. This caught several silly errors in our stub files,
but nothing else.
- Lint on using unknown globals. This highlighted a couple of really
silly mistakes. Fixes#427.
- Add documentation for fs.attributes, fs.getCapacity and pocket, as
they were not defined before.
Co-authored-by: JackMacWindows <jackmacwindowslinux@gmail.com>
- I'm excluding pocket computers, as they have such a tiny screen I'm
not sure the screen estate is worth it.
Pocket computers /generally/ aren't people's starter machine, so I
think this is fine.
- Prune the motd list, and try to make them a little shorter. I think
this list is more of the interesting ones. We can modify this list in
the future, as we get more feedback.[^1]
- Also fix paint/edit not adding an extension when they should. This
was caused by the settings rewrite, as the explicitly provided
default shadowed the one provided by bios.lua.
[^1]: ~5 months ago I asked for some feedback about enabling motds by
default. I only got something constructive back today >_>.
This replaces the allow/block lists with a series of rules. Each rule
takes the form
[[http.rules]]
host = "127.0.0.0/8"
action = "block"
This is pretty much the same as the previous config style, in that hosts
may be domains, wildcards or in CIDR notation. However, they may also be
mixed, so you could allow a specific IP, and then block all others.