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

Tp z Azerusa

Status
Not open for further replies.

Stefan1307

New Member
Joined
Mar 14, 2009
Messages
36
Reaction score
0
Witam, mam problem a mianowicie gdy po zabiciu azerusa tworzy sie tp dobrze ladnie smiga lecz wogole nie znika, prosze o pomoc z gory Dziekuje

// Jeśli nie rozumiesz co oznacza tag Tutorial, nie używaj go. //DD
 
Last edited by a moderator:
LUA:
local m = {
    ["Azerus"] = {
        message = "Escape through the teleport quickly before it closes!",
        cfg = 
        {
            {
                time = 15,
                to = {x = 1023, y = 1122, z = 8},
                tp = {x = 1006, y = 1120, z = 10}
            }
        }
    }
}

function onKill(cid, target)
    if isPlayer(target) then
        return true
    end
    local monster = m[getCreatureName(target)]
    if monster then
        for i = 1, #monster.cfg do
            local c = monster.cfg[i]
                local function deleteTeleport()
                local teleport = getTileItemById(c.tp, 1387).uid
                    if(teleport > 0) then
                        doRemoveItem(teleport)
                        doSendMagicEffect(c.tp, CONST_ME_POFF)
                    end
                    return true
                end
            doCreateTeleport(1387, c.to, c.tp)
            doSendMagicEffect(c.tp, CONST_ME_ENERGYAREA)
            addEvent(deleteTeleport, c.time * 1000)
        end
        doCreatureSay(cid, monster.message, TALKTYPE_ORANGE_1)
    end
    return true
end
 
LUA:
time = 15
 addEvent(deleteTeleport, c.time * 1000)
W sekundach
 
do items.xml musisz dodać jakieś tam linijki
 
Kłopot w tym ze nie mam w items.xml teleportu o id 9738, poprostu puste pole
 
x

Po szukaj troche...
IMPORTANT!

I forget about very important thing!.

in items.xml Add those lines to this item!!:
PHP Code:
<item id="9738" article="a" name="Magic Forcefield">
<attribute key="decayTo" value="0"/>
<attribute key="duration" value="120"/>
</item>
Without it, the portal won't disappear!!
 
Ten skrypt co marcinek99097 mi podales on spowoduje ze teleport zniknie po 2min, jak nie to napisz by znikal
 
Dzieki bardzo, rozwiązaliście mój odwieczny problem, ponad miesiac sie nie moglem z tym uporac a tu nagle dziala, jeszcze raz dzieki bardzo i pozdrawiam wszystkich, ktorzy sie w tym temacie wypowiedzieli, mozemy zamykac.
 
Last edited:
Status
Not open for further replies.
Back
Top