Commit Graph

295 Commits

Author SHA1 Message Date
Linden
aebe248e39 refactor: localise globals to prevent shadowing
See #456.
2023-12-07 08:36:40 +11:00
Andy
62ff7345b9 feat(imports): server-side entity iterators (#458)
Co-authored-by: Linden <65407488+thelindat@users.noreply.github.com>
2023-12-07 08:25:31 +11:00
Armands Vilciņš
2aeade72f0 feature(locale): support nested locales (#463) 2023-12-07 07:44:50 +11:00
Sergio
6c40dd2889 feat(imports/addKeybind): support secondary keybind (#450) 2023-11-28 10:34:53 +11:00
FjamZoo
e72c9bc1c8 fix(require): support asset protection garbage (#443) 2023-11-08 02:07:54 +11:00
Linden
167a068d85 feat(server/cron): getTimeAsString 2023-10-23 16:50:57 +11:00
Linden
2a1d6aa2ae refactor(server/cron): run jobs in a new thread
Better for error handling.
2023-10-23 16:50:29 +11:00
Austin Dunn
0b5ad76721 feat(math): add normal to rotation method (#431) 2023-10-23 16:49:58 +11:00
Manason
c9246bb392 feat: added lib.print to print different log levels to console (#425)
Co-authored-by: Linden <65407488+thelindat@users.noreply.github.com>
2023-09-22 16:39:00 +10:00
Linden
699884aa17 feat(require): external module support for require (#422) 2023-09-19 20:25:17 +10:00
Linden
02d935237d fix(client/callback): mark delay as optional 2023-09-16 22:11:23 +10:00
DokaDoka
4b99aa0953 fix(client/zones): force debug colour values to be integers
for some reason scripts not using oal treat any float above 0 as 255 when used as a colour value
2023-08-13 16:01:12 +10:00
GaDGeT
964e67f9a6 fix(client/zones): store debug colours as a table 2023-08-13 15:57:52 +10:00
Linden
a29ede22af Revert "refactor(server/cron): reduce wait to reschedule task"
This reverts commit d12f4845f2.
2023-08-13 09:28:40 +10:00
Linden
594fa73bfd refactor(require): use error from Lua_require on failed load 2023-08-13 08:55:54 +10:00
Linden
d268168dc7 fix(server/cron): invalid step return for indivisible values
Was reliant on some previously removed hacky-logic in scheduleTask.
Return value + max and rely on getNextTime/os.time to handle overflow.
2023-08-07 18:08:53 +10:00
Linden
8c9cdb1a13 refactor(server/cron): extra debug info 2023-08-06 17:36:40 +10:00
Linden
d12f4845f2 refactor(server/cron): reduce wait to reschedule task
Was a hacky solution to an obsolete issue.
2023-08-06 17:27:41 +10:00
Linden
becc29bcea fix(server/cron): getTimeUnit early return and +1 to minute 2023-08-06 17:14:32 +10:00
Linden
43e521e65b chore(zones): rename CZone field __type 2023-08-03 04:45:26 +10:00
Linden
1a74263949 fix(server/cron): stop all tasks with negative sleep values
Changes in 4536201 and other cron tweaks have improved the accuracy
of getNextTime. Negative values should now always be expired.
2023-08-03 00:53:39 +10:00
Linden
45362017c6 fix(server/cron): more scheduling woes
Schedule next-day tasks.
Some logic improvements and breaking changes from 8488dec.
2023-08-01 17:39:37 +10:00
Linden
9d98b9aada chore: types
mostly types anyway.
2023-07-31 16:29:27 +10:00
Linden
f11668b95c feat(imports): lib.waitFor 2023-07-31 16:17:50 +10:00
DokaDoka
f04534d879 refactor(client/zones): rename type property to __type to avoid conflicts 2023-07-30 17:50:34 +10:00
Linden
d2c5be8ea8 fix(client/zones): setDebug early return 2023-07-27 00:38:36 +10:00
Linden
fe0f28921f fix(client/zones): race condition when setting debug function 2023-07-25 14:13:09 +10:00
Linden
b06ba2d024 chore: type fixes 2023-07-25 01:59:39 +10:00
BerkieBb
8f5880aad7 feat(zones): add setDebug and debugColour (#369) 2023-07-23 19:37:29 +10:00
Linden
84b7f97a1c fix(server/logger): missing ) 2023-07-23 13:41:20 +10:00
Jellyton
2fafee41a0 refactor(server/logger): remove text formatting from hostname (#361) 2023-07-23 12:59:41 +10:00
Jag
65a799071a chore: various fix-ups from docs clean-up (#363)
- Add in missing js functions
  - getCurrentRadialId
  - requestScaleformMove
- Change up math.tohex to maintain lowercase `0x` prefix
- Add missing fields
- Removed extra whitespaces

Co-authored-by: Luke <39926192+LukeWasTakenn@users.noreply.github.com>
2023-07-21 13:54:29 +02:00
Linden
9c90b5be5f fix(server/cron): prevent scheduling tasks for new days
From 8488de.
2023-07-17 23:35:53 +10:00
Linden
149213032b fix(server/cron): getTimeUnit corrections
Consistency between range and lists.
Use different time comparisons for minute units.
2023-07-17 22:48:33 +10:00
Linden
8488dec3d3 refactor(server/cron): allow getNextTime minute and hour "overflow"
Per the Lua manual,
"if sec is -10, it means 10 seconds before the time specified by the other fields".
i.e. { min = 61, hour = 0 } is equal to { min = 1, hour = 1 }

Should improve scheduling and help with #368.
2023-07-17 20:07:30 +10:00
Linden
9e2076f5a5 refactor(server/cron): types and formatting, simplify getMaxDaysInMonth 2023-07-17 19:57:35 +10:00
Linden
6ab719654f fix(server/cron): list expression should use >=
Resolves #366.
2023-07-10 08:50:26 +10:00
Linden
8a0f5e946d fix(client/zones): prevent malformed polyzone deadlock with debug
Temp workaround.
2023-06-20 09:19:27 +10:00
daZepelin
d070c631b4 fix(cron) edge case fixes (#345) 2023-06-13 04:57:39 +10:00
Randolio
0a3edcbe4d fix(imports/getClosestPed): correct variable name (#348) 2023-06-13 04:51:20 +10:00
Linden
8ec19cf263 feat(imports/table): readonly tables 2023-05-28 15:14:52 +10:00
daZepelin
6486f995e1 feat(server/cron): getAbsoluteNextTime (#319) 2023-05-28 15:08:40 +10:00
mikigoalie
4fed5dc38d feat(imports/math): groupdigits (#338) 2023-05-26 09:06:28 +10:00
Linden
a8ab102bae refactor(imports/streaming): use coroutine.isyieldable 2023-05-25 14:56:56 +10:00
Linden
1ba5787ffd feat(imports): extended math lib 2023-05-22 06:47:57 +10:00
Demetrio
ca991bfeab fix(client/imports): correct return value for getClosestPed (#334) 2023-05-18 21:35:06 +10:00
Linden
ebd97f08ea feat(client/imports): getClosestPed 2023-05-18 21:10:20 +10:00
Demetrio
4d1f39512f feat(client/imports): getNearbyPeds (#328) 2023-05-18 21:06:21 +10:00
Linden
16875ca7e3 fix: type corrections 2023-05-18 15:38:53 +10:00
Linden
361ce6cca6 chore(imports/table): some types and annotations 2023-05-09 09:04:45 +10:00