mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-06-09 05:54:50 +02:00
Updated Map Server namespace. Moved all other data folders (www and sql) to data folder. Renamed boot name to Project Meteor.
This commit is contained in:
parent
18ef69f3d1
commit
91549bff7a
1823 changed files with 102704 additions and 901 deletions
39
Data/scripts/commands/gm/warpid.lua
Normal file
39
Data/scripts/commands/gm/warpid.lua
Normal file
|
@ -0,0 +1,39 @@
|
|||
require("global");
|
||||
|
||||
properties = {
|
||||
permissions = 0,
|
||||
parameters = "s",
|
||||
description = "Teleports to Actor uniqueId's position",
|
||||
}
|
||||
|
||||
function onTrigger(player, argc, uID)
|
||||
local messageID = MESSAGE_TYPE_SYSTEM_ERROR;
|
||||
local sender = "[warpid] ";
|
||||
local message = "unable to find actor";
|
||||
local worldManager = GetWorldManager();
|
||||
|
||||
if not player then
|
||||
printf("[Command] [warpid] Player not found!");
|
||||
return;
|
||||
end;
|
||||
|
||||
actor = GetWorldManager():GetActorInWorldByUniqueId(uID);
|
||||
|
||||
if (actor ~= nil) then
|
||||
local actorPos = actor:GetPos();
|
||||
local playerPos = player:GetPos();
|
||||
|
||||
if actorPos[4] == playerPos[4] then
|
||||
worldManager:DoPlayerMoveInZone(player, actorPos[0], actorPos[1], actorPos[2], actorPos[3], 0x00);
|
||||
else
|
||||
worldManager:DoZoneChange(player, actorPos[4], nil, 0, 0x02, actorPos[0], actorPos[1], actorPos[2], actorPos[3]);
|
||||
end
|
||||
|
||||
message = string.format("Moving to %s 's coordinates @ zone %s, %.3f %.3f %.3f ", uID, actorPos[4], actorPos[0], actorPos[1], actorPos[2]);
|
||||
end ;
|
||||
|
||||
player:SendMessage(messageID, sender, message);
|
||||
|
||||
end
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue