You didn't read my post at all because I don't want to execute raid every ten hours. I asked if it's possible to set a CHANCE to execute raid every ten hours. To make it clear every ten hours you got five per cent chance to spawn f. ex. Orshabaal
<raid>
<announce delay="0" type="event" message="hiho" />
<singlespawn delay="2000" name="Necropharus" x="33044" y="32400" z="10" />
</raid>
<raid name="necropharus" file="necropharus.xml" interval2="480" margin="0"/>
[28/12/2008 19:32:27] [Error Raid::loadFromXml]: Could not load data/raids/necropharus.xml!
[28/12/2008 19:32:27] [Error Raids::loadFromXml]: failed to load raid necropharus
christiandb said:necropharus.xml
Code:<raid> <announce delay="0" type="event" message="hiho" /> <singlespawn delay="2000" name="Necropharus" x="33044" y="32400" z="10" /> </raid>
raids.xml
Code:<raid name="necropharus" file="necropharus.xml" interval2="480" margin="0"/>
Code:[28/12/2008 19:32:27] [Error Raid::loadFromXml]: Could not load data/raids/necropharus.xml! [28/12/2008 19:32:27] [Error Raids::loadFromXml]: failed to load raid necropharus
<singlespawn delay="2000" name="Necropharus" x="33044" y="32400" z="10" />
<singlespawn delay="2000" name="Necropharus" pos="33044;32400;10" />
I had that same error, for some weird reason when you write the code for singlespawn the old way, it doesn't work, which is like this:
And it doesn't report any error, instead it says the raid doesn't exist, but when you change it to the new way (elf way) it works perfectly, so you must remove that line, and replace it with this one:
Code:<singlespawn delay="2000" name="Necropharus" pos="33044;32400;10" />
Hope that solves your problem
<?xml version="1.0" encoding="UTF-8"?>
<raids>
<raid name="necropharus" file="necropharus.xml" interval2="480" margin="0"/>
</raids>
<raid>
<announce delay="0" type="event" message="hiho" />
<singlespawn delay="2000" name="Necropharus" pos="33044;32400;10" />
</raid>
[05/01/2009 11:27:18] [Error Raid::loadFromXml]: Could not load data/raids/necropharus.xml!
[05/01/2009 11:27:18] [Error Raids::loadFromXml]: failed to load raid necropharus
1. your raid file is named Necropharus.xml or necropharus.xml?
2. Raids were broken before TFS0.3beta1, and I don't know how it's in 0.2.
<globalevent name="raids" interval="3720" script="raids.lua"/>
local raids = {"Raid name1", "Raid name2", "Raid name3", "Raid name4", "Raid name5"}
function onThink(interval, lastExecution)
executeRaid(raids[math.random(1,#raids)])
return TRUE
end
<raid>
<script delay="0" file="checkBoss.lua"/>
<announce type="event" delay="0" message="Raid message!" />
<areaspawn delay="12000" fromx="980" fromy="960" fromz="7" tox="1048" toy="1024" toz="7">
<monster name="dragon lord" amount="100" />
</areaspawn>
<singlespawn delay="24000" name="Boss" x="1008" y="1008" z="7" />
</raid>
function onRaid()
if getCreatureByName("Boss") > 0 then
return TRUE
end
return FALSE
end
<globalevent name="raids" interval="900" script="raids.lua"/>
ocal raids = {"Ghazbaran", "Orshabaal", "Morgaroth", "Ferumbras"}
local number = math.random(1, 4)
function onThink(interval, lastExecution)
if number == 1 then
executeRaid(raids[math.random(1,#raids)])
end
return TRUE
end