mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-04-02 19:42:05 -04:00
Added missing gl scripts.
This commit is contained in:
parent
a80c80454b
commit
c7acef20a9
@ -0,0 +1,27 @@
|
||||
require ("global")
|
||||
require ("guildleve")
|
||||
|
||||
--DirectorId, GuildleveId, Aetheryte Location (6 or ~6), exMarkerX, exMarkerY, exMarkerZ
|
||||
|
||||
local guildleveId;
|
||||
|
||||
function init(thisDirector, glId)
|
||||
guildleveId = glId;
|
||||
|
||||
guildleveData = GetGuildleveGamedata(glId);
|
||||
members = thisDirector:GetPlayerMembers();
|
||||
|
||||
if (members ~= nil and #members ~= 0) then
|
||||
player = members[0];
|
||||
player:SendGameMessage(GetWorldMaster(), 50036, 0x20, glId, player, 0); --"You have started the leve..."
|
||||
player:PlayAnimation(getGLStartAnimationFromSheet(guildleveData.borderId, guildleveData.plateId, false));
|
||||
end
|
||||
|
||||
return "/Director/Guildleve/PrivateGLBattleDetectNormal", 0x4e25, glId, 6, 0, 0, 0;
|
||||
end
|
||||
|
||||
function mainLoop(thisDirector)
|
||||
|
||||
|
||||
|
||||
end
|
@ -0,0 +1,11 @@
|
||||
require ("global")
|
||||
|
||||
--DirectorId, GuildleveId
|
||||
|
||||
function init()
|
||||
return "/Director/Guildleve/PrivateGLBattleGatherNormal", 0x4e26, 1220, 6, 100, 0.0, -100;
|
||||
end
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
end
|
@ -0,0 +1,11 @@
|
||||
require ("global")
|
||||
|
||||
--DirectorId, GuildleveId, Aetheryte Location (6 or ~6), exMarkerX, exMarkerY, exMarkerZ
|
||||
|
||||
function init()
|
||||
return "/Director/Guildleve/PrivateGLBattleHuntNormal", 0x4e25, 10844, 6, 32.1, 45.1, -35.1;
|
||||
end
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
end
|
32
data/scripts/guildleve.lua
Normal file
32
data/scripts/guildleve.lua
Normal file
@ -0,0 +1,32 @@
|
||||
--[[
|
||||
|
||||
Guildleve constants and functions
|
||||
|
||||
--]]
|
||||
|
||||
--Helper functions
|
||||
|
||||
function glBorderIconIDToAnimID(iconId)
|
||||
return iconId - 20000;
|
||||
end
|
||||
|
||||
function glPlateIconIDToAnimID(iconId)
|
||||
return iconId - 20020;
|
||||
end
|
||||
|
||||
function getGLStartAnimationFromSheet(border, plate, isBoost)
|
||||
return getGLStartAnimation(glBorderIconIDToAnimID(border), glPlateIconIDToAnimID(plate), isBoost);
|
||||
end
|
||||
|
||||
function getGLStartAnimation(border, plate, isBoost)
|
||||
borderBits = border;
|
||||
plateBits = bit32.lshift(plate, 7);
|
||||
|
||||
if (isBoost) then
|
||||
boostBits = 0x8000; --1 shifted 15 left
|
||||
else
|
||||
boostBits = 0x0;
|
||||
end
|
||||
|
||||
return bit32.bor(0x0B000000, boostBits, plateBits, borderBits);
|
||||
end
|
Loading…
Reference in New Issue
Block a user