mirror of
https://github.com/emagi/eq2emu-content
synced 2026-08-12 20:23:03 -04:00
38 lines
No EOL
1.1 KiB
Lua
Executable file
38 lines
No EOL
1.1 KiB
Lua
Executable file
--[[
|
|
Script Name : SpawnScripts/Zek/VigoCerebus.lua
|
|
Script Purpose : Open the gate to Deathfist Citadel upon death and close upon spawning
|
|
Script Author : Jabantiz
|
|
Script Date : 8/28/2016
|
|
Script Notes :
|
|
--]]
|
|
|
|
local GateLower = 1900304
|
|
local GateOpenedY = -38
|
|
require "SpawnScripts/Generic/NPCModule"
|
|
|
|
function spawn(NPC, Spawn)
|
|
NPCModule(NPC, Spawn)
|
|
Deathfist(NPC)
|
|
OrcArmorCommon(NPC)
|
|
|
|
local bridgeGate = GetSpawn(NPC, GateLower)
|
|
if bridgeGate ~= nil and GetY(bridgeGate) == GateOpenedY then
|
|
UseWidget(bridgeGate)
|
|
end
|
|
end
|
|
|
|
function respawn(NPC)
|
|
spawn(NPC)
|
|
end
|
|
|
|
function death(NPC, Spawn)
|
|
local bridgeGate = GetSpawn(NPC, GateLower)
|
|
if bridgeGate ~= nil and GetY(bridgeGate) ~= GateOpenedY then
|
|
UseWidget(bridgeGate)
|
|
local players = GetPlayersInZone(GetZone(NPC))
|
|
for index, player in pairs(players) do
|
|
SendPopUpMessage(player, "With the slaying of Vigo, the Deathfist Citadel gate is unlocked!", 255, 0, 0)
|
|
SendMessage(player, "With the slaying of Vigo, the Deathfist Citadel gate is unlocked!", "red")
|
|
end
|
|
end
|
|
end |