oualid6496
Well-Known Member
Srry don't know what the problem is then :/
Sure you copied everything right? Because it's working perfect with mine
works ok and thanks for your help
Greetings[/QUOTE]
what was the problem then ? ;p
Srry don't know what the problem is then :/
Sure you copied everything right? Because it's working perfect with mine
what was the problem then ? ;p[/QUOTE]works ok and thanks for your help
Greetings
I dont even think its supposed to create a teleporter, you are supposed to put the actionID or uniqueID on a tile, or even put it on a teleporter.it doesn't create teleport when the event start you have to use !zombie to get teleported to the waiting room
I dont even think its supposed to create a teleporter, you are supposed to put the actionID or uniqueID on a tile, or even put it on a teleporter.
Is there any problem with the zombies spawning? because I cant manage to get it to work, any suggestions? @Printer
<monster name="Zombie_Event" file="Zombie_Event.xml"/>
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Zombie" nameDescription="a zombie" race="undead" experience="0" speed="100" manacost="0">
<health now="500" max="500"/>
<look type="311" corpse="0"/>
<targetchange interval="4000" chance="10"/>
<strategy attack="100" defense="0"/>
<flags>
<flag summonable="0"/>
<flag attackable="1"/>
<flag hostile="1"/>
<flag illusionable="0"/>
<flag convinceable="0"/>
<flag pushable="0"/>
<flag canpushitems="1"/>
<flag canpushcreatures="1"/>
<flag targetdistance="1"/>
<flag staticattack="90"/>
<flag runonhealth="0"/>
</flags>
<attacks>
<attack name="melee" interval="2000" skill="9999999" attack="9999999"/>
</attacks>
<defenses armor="15" defense="15"/>
<elements>
<element firePercent="50"/>
</elements>
<immunities>
<immunity death="1"/>
<immunity energy="1"/>
<immunity ice="1"/>
<immunity earth="1"/>
<immunity drown="1"/>
<immunity drunk="1"/>
<immunity lifedrain="1"/>
<immunity paralyze="1"/>
</immunities>
<voices interval="5000" chance="10">
<voice sentence="Mst.... klll...."/>
<voice sentence="Whrrrr... ssss.... mmm.... grrrrl"/>
<voice sentence="Dnnnt... cmmm... clsrrr...."/>
<voice sentence="Httt.... hmnnsss..."/>
</voices>
<script>
<event name="ZE_Mon_Death"/>
</script>
</monster>
Yeah I added the monster x'DI know it isn't supposed to create a teleported that's what I tryd to say ;p
Did you add the zombie in your monster file?
data\monster\monsters.xml
Code:<monster name="Zombie_Event" file="Zombie_Event.xml"/>
data\monster\Zombie_Event.xml
Code:<?xml version="1.0" encoding="UTF-8"?> <monster name="Zombie" nameDescription="a zombie" race="undead" experience="0" speed="100" manacost="0"> <health now="500" max="500"/> <look type="311" corpse="0"/> <targetchange interval="4000" chance="10"/> <strategy attack="100" defense="0"/> <flags> <flag summonable="0"/> <flag attackable="1"/> <flag hostile="1"/> <flag illusionable="0"/> <flag convinceable="0"/> <flag pushable="0"/> <flag canpushitems="1"/> <flag canpushcreatures="1"/> <flag targetdistance="1"/> <flag staticattack="90"/> <flag runonhealth="0"/> </flags> <attacks> <attack name="melee" interval="2000" skill="9999999" attack="9999999"/> </attacks> <defenses armor="15" defense="15"/> <elements> <element firePercent="50"/> </elements> <immunities> <immunity death="1"/> <immunity energy="1"/> <immunity ice="1"/> <immunity earth="1"/> <immunity drown="1"/> <immunity drunk="1"/> <immunity lifedrain="1"/> <immunity paralyze="1"/> </immunities> <voices interval="5000" chance="10"> <voice sentence="Mst.... klll...."/> <voice sentence="Whrrrr... ssss.... mmm.... grrrrl"/> <voice sentence="Dnnnt... cmmm... clsrrr...."/> <voice sentence="Httt.... hmnnsss..."/> </voices> <script> <event name="ZE_Mon_Death"/> </script> </monster>
You never know ;pYeah I added the monster x'D
Well im using it and it works perfect Can't imagine what could be betterI feel so ashame when i see these old codes I could make the event faster, shorter, simple and more new functions. With the new functions, which tfs got But i'm no time...
Just do it man, go crazy XDI feel so ashame when i see these old codes I could make the event faster, shorter, simple and more new functions. With the new functions, which tfs got But no time...
Well, i can do it. But i won't be able to test it You guys have to test it instead ^^
What do you guys want to see?
Create teleport when event start?
Talkaction?
edited (I know the waiting place looks a little bit ugly )Use imgland to upload the images. I can't view them.
create teleport when the event starts is not necessary, and the magic wall & wild growth function would be a really nice idea actually.Well, i can do it. But i won't be able to test it You guys have to test it instead ^^
What do you guys want to see?
Create teleport when event start?
Talkaction?
-- Zombie Variables
zeZombieName = 'Zombie_Event' --Zombie Name
zombieSpawnInterval = 10 --how many seconds until a new zombie spawns
zeMaxZombies = 20 --max zombies in the arena?
zeJoinedCountGlobalStorage = 100 --Player joined event count
-- Players Variables
zeJoinStorage = 19999 --player join storage
zeMinPlayers = 1 --min players needed when time runout
zeMaxPlayers = 20 --max players to join
zeTrophy = 10139 --trophy itemid
zeJoinedCountGlobalStorage = 101 --Zombie spawned Count
-- Other Variables
zeWaitMinutes = 1 --when event has opened, how long until it starts?
zeWaitingRoomPos = Position(1550, 1911, 7) --middle of waiting room
zeZombieArena = Position(1322, 1917, 7) --when even start where should player be teleported in the zombie arena?
zeArenaFromPosition = Position(1288, y = 1890, z = 7) --pos of top left corner
zeArenaToPosition = Position(1342, y = 1923, z = 7) --pos of bottom right corner
zeMiddleZombieArena = Position(1315, y = 1905, z = 7) --Middle pos of the arena
zeWaitingRoomRadiusX = 20 --depends how big the waiting room is 20sqm to x
zeWaitingRoomRadiusY = 20 --depends how big the waiting room is 20sqm to y
zeZombieArenaRadiusX = 50 --Depends how big the zombie arena is 50sqm to x
zeZombieArenaRadiusY = 50 --Depends how big the zombie arena is 50sqm to y
zeStartedGlobalStorage = 102 -- Value: 0 == false, 1 == true, 2 == started
zeCreateTeleportPosition = Position(158, 54, 7) --Where should the teleport be created?
function startZombie()
local specs = Game.getSpectators(zeWaitingRoomPos, false, true, 0, zeWaitingRoomRadiusX, 0, zeWaitingRoomRadiusY)
if Game.getStorageValue(zeJoinedCountGlobalStorage) < zeMinPlayers then
for i = 1, #specs do
specs[i]:teleportTo(specs[i]:getTown():getTemplePosition(), false)
specs[i]:setStorageValue(zeJoinStorage, 0)
end
resetVariables()
Game.broadcastMessage('Zombie Event failed to start, because of to little players joined the event!', MESSAGE_STATUS_WARNING)
return true
end
for i = 1, #specs do
specs[i]:teleportTo(zeZombieArena)
end
Game.broadcastMessage("Zombie Event has started, good luck to all participant.", MESSAGE_STATUS_WARNING)
Game.setStorageValue(zeStartedGlobalStorage, 2)
doStartZombieEvasion()
end
function doSummonZombie()
if Game.getStorageValue(zeZombieCountGlobalStorage) > zeMaxZombies then
return false
end
local zombie = Game.createMonster(zeZombieName, {x = math.random(zeArenaFromPosition.x, zeArenaToPosition.x), y = math.random(zeArenaFromPosition.y, zeArenaToPosition.y), z = math.random(zeArenaFromPosition.z, zeArenaToPosition.z)})
if zombie then
Game.createMonster(zeZombieName, {x = math.random(zeArenaFromPosition.x, zeArenaToPosition.x), y = math.random(zeArenaFromPosition.y, zeArenaToPosition.y), z = math.random(zeArenaFromPosition.z, zeArenaToPosition.z)})
end
Game.setStorageValue(zeZombieCountGlobalStorage, Game.getStorageValue(zeZombieCountGlobalStorage) + 1)
end
function doStartZombieEvasion()
if Game.getStorageValue(zeStartedGlobalStorage) == 2 then
doSummonZombie()
addEvent(doStartZombieEvasion, 5 * 1000)
end
end
function resetVariables()
Game.setStorageValue(zeJoinedCountGlobalStorage, 0)
Game.setStorageValue(zeZombieCountGlobalStorage, 0)
Game.setStorageValue(zeStartedGlobalStorage, 0)
end
function doClearZombieArena()
local specs = Game.getSpectators(zeMiddleZombieArena, false, false, 0, zeZombieArenaRadiusX, 0, zeZombieArenaRadiusY)
for i = 1, #specs do
if specs[i]:getName() == zeZombieName then
specs[i]:remove()
end
end
end