Lottery Spawn Issues
Posted: Mon May 18, 2015 10:01 am
Hello, DSP
I am playing around with a server, but i realized that my lottery spawns dont seem to be working, I even tried to set the 5% to higher percents by editing the random math values and they still do not spawn, mostly tried Leapy and Emp..
(standard scripts no edits except settings)
So my question is: am i missing something somewhere?
I am playing around with a server, but i realized that my lottery spawns dont seem to be working, I even tried to set the 5% to higher percents by editing the random math values and they still do not spawn, mostly tried Leapy and Emp..
(standard scripts no edits except settings)
So my question is: am i missing something somewhere?
Code: Select all
----------------------------------
-- Area: Valkurm Dunes
-- NM: Valkurm Emperor
-----------------------------------
-----------------------------------
-- onMobDeath
-----------------------------------
function onMobDeath(mob,killer)
-- Set VE's Window Open Time
SetServerVariable("[POP]Valkurm_Emperor", os.time(t) + 3600); -- 1 hour
DeterMob(mob:getID(), true);
-- Set PH back to normal, then set to respawn spawn
PH = GetServerVariable("[PH]Valkurm_Emperor");
SetServerVariable("[PH]Valkurm_Emperor", 0);
DeterMob(PH, false);
GetMobByID(PH):setRespawnTime(GetMobRespawnTime(PH));
end;
-----------------------------------
-- onMobDespawn
-----------------------------------
function onMobDespawn(mob)
SetServerVariable("[POP]Valkurm_Emperor", os.time(t) + 3600); -- 1 hour
DeterMob(mob:getID(), true);
-- Set PH back to normal, then set to respawn spawn
PH = GetServerVariable("[PH]Valkurm_Emperor");
SetServerVariable("[PH]Valkurm_Emperor", 0);
DeterMob(PH, false);
GetMobByID(PH):setRespawnTime(GetMobRespawnTime(PH));
end;
Code: Select all
-----------------------------------
-- Area: Valkurm Dunes
-- MOB: Damselfly
-- Note: Place holder Valkurm Emperor
-----------------------------------
require("/scripts/zones/Valkurm_Dunes/MobIDs");
require("/scripts/globals/fieldsofvalor");
-----------------------------------
-- onMobDeath
-----------------------------------
function onMobDeath(mob,killer)
checkRegime(killer,mob,9,1);
checkRegime(killer,mob,10,2);
mob = mob:getID();
if (Valkurm_Emperor_PH[mob] ~= nil) then
VE_ToD = GetServerVariable("[POP]Valkurm_Emperor");
if (VE_ToD <= os.time(t) and GetMobAction(Valkurm_Emperor) == 0) then
if (math.random(1,20) == 5) then
UpdateNMSpawnPoint(Valkurm_Emperor);
GetMobByID(Valkurm_Emperor):setRespawnTime(GetMobRespawnTime(mob));
SetServerVariable("[PH]Valkurm_Emperor", mob);
DeterMob(mob, true);
end
end
end
end;
Code: Select all
-----------------------------------
-- Area: Valkurm Dunes (103)
-- Comments: -- posX, posY, posZ
--(Taken from 'mob_spawn_points' table)
-----------------------------------
-- Valkurm Emporer
Valkurm_Emperor=17199438;
Valkurm_Emperor_PH={
[17199434] = '1', -- -228.957, 2.776, -101.226
[17199437] = '1', -- -264.829, -0.843, -91.306
[17199420] = '1', -- -95.250, -0.268, -49.386
[17199419] = '1', -- -144.284, -1.103, 4.202
[17199435] = '1', -- -270.823, -2.168, -16.349
[17199436] = '1', -- -327.000, -1.000, -21.000
};