1
Fork 0
mirror of https://bitbucket.org/Ioncannon/project-meteor-server.git synced 2025-04-22 20:57:47 +00:00
project-meteor-server/data/scripts/commands/ActivateCommand.lua

25 lines
472 B
Lua
Raw Normal View History

--[[
ActivateCommand Script
Switches between active and passive mode states
--]]
function onEventStarted(player, command, triggerName)
2016-06-15 03:41:23 +01:00
if (player:GetState() == 0) then
player:changeState(2);
2016-06-15 03:41:23 +01:00
elseif (player:GetState() == 2) then
player:changeState(0);
end
2016-06-15 03:41:23 +01:00
player:EndCommand();
--For Opening Tutorial
if (player:hasQuest("Man0l0") or player:hasQuest("Man0g0") or player:hasQuest("Man0u0")) then
2016-06-15 03:41:23 +01:00
player:GetDirector():OnCommand(command);
end
end