## About The Pull Request
This adds ~~3~~ 8 wrappers for SDQL2/Lua: `_floor(x)`, `_ceil(x)` (we
already had `_round(a, b = 1)`), and `_typesof(a, subtypes_only)`
`_typesof` has a second argument, `subtypes_only` (default false), which
makes it act like `subtypesof` instead, to save from having to manually
remove the base type (especially since removing by value is kind of
annoying in Lua)
the Lua SS13 library has had a `SS13.typesof` function added, which does
exactly what it says on the tin (also with the second `subtypes_only`
argument)
also added `_uppertext`, `_html_encode`, `_html_decode`, `_url_encode`,
and `_url_decode`. these should all be selfexplanatory
## Why It's Good For The Game
more utility for Lua and SDQL2
## Changelog
🆑
admin: Added some more Lua/SDQL2 wrappers: _floor(), _ceil(),
_typesof(), _uppertext(), _html_encode(), _html_decode(), _url_encode(),
and _url_decode()
/🆑
## About The Pull Request
I added new helpers to the default SS13 lua library: `SS13.ispath`,
`SS13.typecacheof`, `SS13.is_type_in_typecache`, `SS13.get_turf`, and
`SS13.get_area`, which pretty much behave like their actual DM
counterparts (albeit `SS13.typecacheof` lets you just input string
typepaths, instead of needing to manually `SS13.type` each one)
In addition, I discovered an issue with `SS13.register_signal`: `not
type(func) == "function"` is the same as `(not type(func)) ==
"function"` - so the proper check is `type(func) ~= "function"`.
## Why It's Good For The Game
## Changelog
🆑
admin: Added some new Lua functions: SS13.ispath, SS13.typecacheof,
SS13.is_type_in_typecache, SS13.get_turf, and SS13.get_area
fix: Fixed a broken check in the SS13.register_signal Lua function.
/🆑
## About The Pull Request
This adds a new function for Lua scripts: `SS13.check_tick()` - it acts
pretty much exactly like the `CHECK_TICK` macro in DM.
It accepts a single argument, a boolean, which if true - it will act
like `CHECK_TICK_HIGH_PRIORITY` instead.
## Why It's Good For The Game
this function is a repeated code pattern in lua scripts, so having it in
the SS13 lua library is useful.
## Changelog
🆑
admin: Added a new function in Lua scripting, SS13.check_tick, to avoid
causing too much lag during loops and such.
/🆑
## About The Pull Request
As title says.
## Why It's Good For The Game
Bugfix
## Changelog
🆑
fix: Fixed a bug that breaks signal handlers on an object if one of the
signal handlers doesn't return a number value.
/🆑
Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com>
## About The Pull Request
Ever since byondapi went stable, I've been meaning to create a
replacement lua library that uses it instead of the auxtools-based
auxlua. After so many months, I've finally got the code just about into
a position where it's ready for a PR.
[Click here](https://hackmd.io/@aloZJicNQrmfYgykhfFwAQ/BySAS18u0) for a
guide to rewriting auxlua scripts for dreamluau syntax.
## Why It's Good For The Game
Code that runs on production servers should not depend on memory hacks
that are liable to break any time Dream Daemon updates.
## Changelog
🆑
admin: Admin lua scripting uses a new library that (probably) will not
break when BYOND updates.
/🆑
## TODO:
- [x] Convert the lua editor ui to TS
- [x] Include a guide for converting scripts from auxlua syntax to
dreamluau syntax
## About The Pull Request
Signals don't get removed on turfs when they're deleted. This fixes that
so that it is reflected in lua as well.
## Why It's Good For The Game
Lua bugfixes
## Changelog
🆑
fix: Fixed lua scripts breaking when turfs with registered signals get
deleted.
/🆑
---------
Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com>
## About The Pull Request
See title
## Why It's Good For The Game
More descriptive error message
## Changelog
🆑
fix: LUA: Registering a signal on a deleted datum will throw a more
descriptive error message.
/🆑
---------
Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com>
## About The Pull Request
Cleaned up the SS13.register_signal and SS13.unregister_signal, removing
the weird list shifting.
Also adds a new lua file that can be included for the use of registering
different signals on various datums and being able to clear them all in
1 function.
Removed the make_easy_clear_function option when registering a signal
via lua because I don't think it's used by anyone and it lacks any sort
of versatility. Users can just create their own function for clearing
signals from a datum.
Also updates the documentation for HARDDELETES.md as
COMSIG_PARENT_QDELETING was renamed to COMSIG_QDELETING
## Why It's Good For The Game
New handler file makes registering signals in batches a lot easier if
you want to clear them in one go without clearing unrelated callbacks on
the same datum. The list shifting in SS13.register_signal had pretty
significant performance problems, so removing that will make registering
and unregistering signals faster.
## Changelog
🆑
admin: LUA - Adds a new library called handler_group. Include it in your
files by doing require('handler_group')
/🆑
---------
Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com>
## About The Pull Request
Lua uses the timer subsystem, which can end up holding the entire timer
subsystem if lua is creating a lot of timers.
The solution to this is to use an internal scheduler instead so that the
load gets placed onto the lua subsystem.
## Why It's Good For The Game
Performance improvement when using lua scripts.
## Changelog
🆑
refactor: Auxlua no longer uses the timer subsystem to get stuff done,
lua scripts shouldn't slow down timers anymore.
/🆑
---------
Co-authored-by: Watermelon914 <3052169-Watermelon914@users.noreply.gitlab.com>