• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Lua Modify Script

russogracie

New Member
Joined
Sep 9, 2010
Messages
205
Reaction score
2
This is a script of war of emperium, this is a creaturescripts ondeath:

Code:
dofile("./_woe.lua")

local config = woe_config
	
function onDeath(cid, corpse, deathList)
	local killer = deathList[1]
	Woe.getInfo()
	if Woe.isTime() then
		if isPlayer(killer) == true then
			if Woe.isRegistered(killer) then
				local Guild_ID = getPlayerGuildId(killer)
				Woe.updateInfo({infoLua[1], Guild_ID, getPlayerGUID(killer), os.time()})
				doBroadcastMessage("The Castle " .. Castle.name .. " has been conquest by " .. getCreatureName(killer) .. " for " .. getPlayerGuildName(killer) .. ".", config.bcType)
				Woe.deco("Actually the castle " .. Castle.name .. " is owned by " .. getPlayerGuildName(killer) .. ".")
				Woe.expulsar(Guild_ID, Castle.salas.a.fromx, Castle.salas.a.tox, Castle.salas.a.fromy, Castle.salas.a.toy, Castle.salas.a.z, Castle._exit)
				Woe.expulsar(Guild_ID, Castle.salas.b.fromx, Castle.salas.b.tox, Castle.salas.b.fromy, Castle.salas.b.toy, Castle.salas.b.z, Castle._exit)
				Woe.expulsar(Guild_ID, Castle.salas.c.fromx, Castle.salas.c.tox, Castle.salas.c.fromy, Castle.salas.c.toy, Castle.salas.c.z, Castle._exit)
			end
		end
		if isCreature(cid) == true then
			doRemoveCreature(cid)
		end
		Woe.removePre()
		Woe.removePortals()
		Woe.remove()
		setGlobalStorageValue(24503, -1)
		doSummonCreature("empe", Castle.empePos)
		doSummonCreature("pre1", Castle.PreEmpes[1])
		doSummonCreature("pre2", Castle.PreEmpes[2])
	end
	return true
end

Because I wanted the domain of the castle were made ​​to climb into a seat so we wanted to transform them into Movements.
 
Back
Top