• 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!

TFS 0.X Boss spawn again after 5min from first death

vexler222

Active Member
Joined
Apr 22, 2012
Messages
714
Solutions
15
Reaction score
47
Hi, someone have script, for spawn boss again after 5min from first death? I dont know how do it :(

tfs 0.4
 
Solution
ondeath function triget 2x add event, first spawn monster, second send broadcast
use this one

Thanks guys, i have it! :D if someone need same script look at it:

Code:
local creatureName = "ghost of old pirate" -- First monster name
local newCreature = "ghost of old pirate" -- Name of a monster spawning after first monster death
local creatureSay = "TEXT TEXT TEXT" -- Orange text after kill first monster
local position = {x=1027,y=1016,z=7} -- Position where monster spawn

function Spawn_Msg()
    doBroadcastMessage("TEXT TEXT TEXT") -- Msg when monster spawn
end

function onDeath(cid, target, damage, flags)
    if isPlayer(target) then
        return...
use this one
 
ondeath function triget 2x add event, first spawn monster, second send broadcast
use this one

Thanks guys, i have it! :D if someone need same script look at it:

Code:
local creatureName = "ghost of old pirate" -- First monster name
local newCreature = "ghost of old pirate" -- Name of a monster spawning after first monster death
local creatureSay = "TEXT TEXT TEXT" -- Orange text after kill first monster
local position = {x=1027,y=1016,z=7} -- Position where monster spawn

function Spawn_Msg()
    doBroadcastMessage("TEXT TEXT TEXT") -- Msg when monster spawn
end

function onDeath(cid, target, damage, flags)
    if isPlayer(target) then
        return false
    end
   
    local name = getCreatureName(cid):lower()
    if name ~= creatureName:lower() then
        return false
    end
   
    doCreatureSay(cid, creatureSay, TALKTYPE_ORANGE_1, false, 0, position)
    addEvent(doCreateMonster, 60 * 1000 * 60, newCreature, position) -- Next monster spawn after 60 min from first death of Boss
    addEvent(Spawn_Msg, 60 * 1000 * 60)
    return true
end
 
Solution
Back
Top