Commit graph

26 commits

Author SHA1 Message Date
Zach Toogood
9d5c0ce05e
Core: Disable hot-reloading of spec files (#10172)
* Core: Disable hot-reloading of spec files

* Commands: Use setfenv() in !exec for safety

* Core: Use string_view in CCommandHandler
2026-05-28 09:34:57 +01:00
claywar
55de6a5440
Fix issues reported in command scripts
Additional nil checks
2024-08-25 12:01:53 -04:00
claywar
1af0cee384
[type] Add Command type, command script annotations 2024-08-25 10:54:45 -04:00
claywar
d066a186a3
Fix or Ignore remaining Lua Language Server warnings and errors
* Separated Cruor Prospector tables with different data structures
* Remove unnecessary bit.bor call with missing parameter
* Nil check manaclipper nextEvent variable
* Nil check Lower Jeuno Treasure Coffer 'prize' variable
* Add LLS exception for __eq and new for missions and hidden quests
* Nil check dynamis 'te' variable
* Change default table data type for caskets timeTable
* Nil check logInfo in setMissionStatus GM Command
* Define variables on need, remove debug print in avatar code
* Add TODOs and exceptions for remaining LLS errors and warnings
2024-08-20 14:11:00 -04:00
Zach Toogood
e98de08e90 [core, Lua] Rename PrintToPlayer and PrintToArea to lowercase 2023-12-09 23:54:00 +00:00
claywar
8d17652f97
[chore] Update command scripts to return table
Update remaining commands

Remove unused, and correct missing items
2023-09-02 07:01:35 -04:00
claywar
aa87e30e4d
[chore] Replace double-quote strings with single-quotes 2023-08-28 21:02:36 -04:00
claywar
5a517f5c95
[chore] Remove underscores from local var declarations 2022-12-03 09:20:16 -05:00
claywar
84152cffd1
[chore] Remove explicit boolean comparisons from conditions (1) 2022-11-04 13:16:24 -04:00
claywar
a24cee9a62
[chore] Remove outer parens from Lua conditions (12) 2022-11-04 10:44:34 -04:00
Zach Toogood
7e93e972f7 [lua] Various linting changes 2021-05-28 17:49:13 +03:00
wrenffxi
0ed5cb8f59 [sol refactor] scripts/commands headings 2021-01-18 13:34:00 -05:00
Zach Toogood
9ddba57610 Roll back tpz.core global function binding 2021-01-09 08:01:35 +02:00
Zach Toogood
eb44c9a638 LuaRefactor: GetPlayerByName, GetPlayerByID 2020-12-28 16:37:20 +02:00
Zach Toogood
b6da2d0d6e Make error string clearer 2020-07-05 20:12:47 +03:00
Zach Toogood
e8d1df15c1 Define "player" and "target" in exec command 2020-07-05 20:09:21 +03:00
Mark Klara
c52431e2c4
Remove trailing whitespace from script/ files. (#426)
Commands used (on Mac):
```
  export LC_CTYPE=C
  export LANG=C
  find . -not \( -name .svn -prune -o -name .git -prune \) -type f -print0 | xargs -0 sed -i '' -E "s/[[:space:]]*$//"
```
2020-03-20 01:41:42 +00:00
MrHappyAsthma
36fdb3ea7e Bulk remove semicolons from Lua scripts/commands.
This may not actually be every file, but I did the best I could.

Command applied:
    find . -type f -name "*.lua" | xargs -d '\n' sed -i 's/;//g'

Semicolons are not appropriate in Lua per the style guidelines:
    https://github.com/project-topaz/topaz/blob/master/CONTRIBUTING.md
2020-02-19 21:42:47 -08:00
Ninjistix
3b629bcd2d update comments in cmds to reflect change from @ to ! 2017-08-22 20:44:32 -04:00
wrenffxi
ae101604fd command input validation and standardization [d-e] 2017-08-04 14:23:31 -04:00
Tyler Schneider
41169a5a9c Revert "Deprecated @ symbol use in GM commands. It still works for now alongside its replacement $ and all documentation has been updated."
This reverts commit 88c2a81735.
2016-07-29 08:35:15 -06:00
TeoTwawki
88c2a81735 Deprecated @ symbol use in GM commands. It still works for now alongside its replacement $ and all documentation has been updated.
I cannot guarantee that the automation didn't mangle the human readability of a line or two someplace, but I did make sure the console log was clean of errors after.

Also, during this process a great many script errors were spotted. Most incidents were missing requires in quest scripts and these are now corrected.

Reasoning:
Many modern sites and services use the AT symbol (`@`) to direct messages to users, including the service currently hosting our repository. Someone unfamiliar with this (or simply doesn't consider it or doesn't care) can easily create situations where persons not involved in the project could be spammed.
2016-07-29 01:49:37 -04:00
teschnei
d2557c5bc0 SCRIPTS: cleaned up GM commands
removed setpvp as its binding was removed already
removed deprecated resetplayer
2015-04-29 17:21:36 -06:00
teschnei
c32a4be26b Revert "Merge branch 'master' of https://github.com/DarkstarProject/darkstar"
This reverts commit ffd78c3739, reversing
changes made to fa483614c1.
2015-02-20 00:12:53 -07:00
teschnei
ffd78c3739 Merge branch 'master' of https://github.com/DarkstarProject/darkstar
Conflicts:
	sql/spell_list.sql
2015-02-19 23:43:26 -07:00
atom0s
1525f6169f CORE: Added special case for single-string commands to allow spaces.
SCRIPT: Added exec GM command to execute raw Lua from chat.

WARNING: Having access to @exec can be potentially harmful! This can crash the server if used improperly! It is advised that you do not give access to this command to normal players / GMs. But instead, restrict the command to GM level 4. (By default this command requires Lv4 GM.)

I have coded this script to block the usage of os commands for safety purposes.
2014-01-22 03:59:51 -08:00