mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-06-08 21:44:35 +02:00
start of work moving commands to lua
This commit is contained in:
parent
1159c75ab8
commit
57b9d5ab99
20 changed files with 703 additions and 67 deletions
23
data/scripts/commands/gm/reloadzone.lua
Normal file
23
data/scripts/commands/gm/reloadzone.lua
Normal file
|
@ -0,0 +1,23 @@
|
|||
require("global");
|
||||
|
||||
properties = {
|
||||
permissions = 0,
|
||||
parameters = "s",
|
||||
description = "reloads <zone>",
|
||||
}
|
||||
|
||||
function onTrigger(player, argc, zone)
|
||||
if not zone or tonumber(zone) == 0 then
|
||||
printf("%s is not a valid zone!", zone);
|
||||
return;
|
||||
end;
|
||||
|
||||
zone = tonumber(zone);
|
||||
|
||||
if player then
|
||||
local messageID = MSG_TYPE_SYSTEM_ERROR;
|
||||
player:SendMessage(messageID, "[reloadzones] ", string.format("Reloading zone: %u", zone));
|
||||
end;
|
||||
|
||||
GetWorldManager():ReloadZone(zone);
|
||||
end;
|
Loading…
Add table
Add a link
Reference in a new issue