The issue is that the \button fragments in SatCom are replaced with
invalid UTF-8 bytes, hence those bytes need to be handled as a special
case when checking for UTF-8 character length.
When the text is processed e.g. in `Gfx::CText::Justify`, there are
generally two arrays: `text` and `format`. The second one is interpreted
as a font for a given character, e.g. `text[i]` has font `format[i]`.
Now, in the loops the index for `text` is increased by the length of
the character, e.g. 1 to 4 bytes, whereas index for `format` is
only incremented. It seems there's an assumption that `format` treats
multibyte characters as one byte, which doesn't seem to be true by
looking at the process of filling up the `format` array. This can result
in using wrong font e.g. FONT_SATCOM for the \button character which
should be FONT_BUTTON, hence the `StrUtils::Utf8CharSizeAt` method
complains about unexpected continuation byte via exception, causing
the crash.
Incrementing the index by the UTF-8 length seems to have fixed the
issue. However, I am not sure if I haven't broken anything else by this
and if I analyzed the intended behaviour correctly.
Gfx::CText needs a major refactor IMHO.
Signed-off-by: suve <veg@svgames.pl>
Jeff's patch was written for the 0.1.12 stable release.
Adapted to work with the "dev" branch (as of commit 13098ee).
GNU Guix is a transactional package manager and an advanced distribution of the GNU system that respects user freedom. Guix can be used on top of any system running the kernel Linux, or it can be used as a standalone operating system distribution for i686, x86_64, ARMv7, and AArch64 machines.
In addition to standard package management features, Guix supports transactional upgrades and roll-backs, unprivileged package management, per-user profiles, and garbage collection. When used as a standalone GNU/Linux distribution, Guix offers a declarative, stateless approach to operating system configuration management. Guix is highly customizable and hackable through Guile programming interfaces and extensions to the Scheme language.
This fixes the issue with objects and terrain being darker than they should be. As it turns out, most levels have not normalized light direction which happens to make light brighter and this is the expected result. To keep in line with GL14 engine, newer engines should use the length of the vector to make light brighter.
The code left a byte from the previous text in CEdit UI control if
the new text is shorter than the old one. So an exception was thrown
because it's an invalid UTF-8 byte.
It's just listing directories of a mod for now, but should give some
idea what the mod changes.
Also moved some functionality from pathman to modman.
Mods added with the `-mod` parameter are now managed by modman.
The arrow buttons are smaller and the up button is now above the down
button. What is more, the width of the back button is now the same as
in other places.
* Clamped power variable before assignment to params in object manager. Attempted to fix formatting issues.
* Fixed Clamp function not implemented correctly.
* Fixed formatting issue, space after commas.
* Created ClampPower method in object_manager.h and implemented in object_manager.cpp, Removed similar code from robotmain.cpp
* Removed redundant call to ClampPower in object_manager.cpp
* Added second call to ClampPower back to object_manager.cpp. Made ClampPower method private. Attempted to fix whitespace issues.
* Fixed missing assignment to params.power in CreateObject method of object_manager.cpp
* fixed white space at end of line 182 in object_manager.h
* Fixed doxygen compatibility issue.
The GITHUB_TOKEN is readonly when running from a fork... and I've found exactly 0 workarounds for this issue
I wanted to check permissions on the actual token rather than if we are running inside a fork, but the header that is supposed to specify the permissions doesn't exist under GH Actions (╯°□°)╯︵ ┻━┻