mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-04-21 04:07:48 +00:00
26 lines
No EOL
738 B
Lua
26 lines
No EOL
738 B
Lua
require("global");
|
|
|
|
properties = {
|
|
permissions = 0,
|
|
parameters = "s",
|
|
description =
|
|
[[
|
|
Changes appearance for equipment with given parameters.
|
|
!graphic <slot> <wID> <eID> <vID> <vID>
|
|
]],
|
|
}
|
|
|
|
function onTrigger(player, argc, actorClassId)
|
|
local messageID = MESSAGE_TYPE_SYSTEM_ERROR;
|
|
local sender = "[setappearance] ";
|
|
|
|
local actorClassId = tonumber(actorClassId) or 0;
|
|
player:SendMessage(messageID, sender, string.format("appearance %u", actorClassId));
|
|
|
|
local actor = player.CurrentArea:FindActorInArea(player.currentTarget);
|
|
|
|
if actor then
|
|
actor:ChangeNpcAppearance(actorClassId);
|
|
player:SendMessage(messageID, sender, string.format("appearance %u", actorClassId));
|
|
end
|
|
end |