Page 1 of 1

Grand Boss ai and respawn time formula (lil help here)

Posted: Sun Sep 13, 2009 9:39 pm
by chobito
Im having big trouble in getting the correct numbers in respawn ai formula :l

I want to make my grand bosses via ai.java to respawn in 6 hours.
But i try to put the correct values and sometimes they respawn in minutes D: .


this are the default values in the ai

Code: Select all

Core:             //time is 60hour	+/- 23hour            long respawnTime = (27 + Rnd.get(47)) * 3600000;            startQuestTimer("core_unlock", respawnTime, null, null); Baium         // "lock" baium for 5 days and 1 to 8 hours [i.e. 432,000,000 +  1*3,600,000 + random-less-than(8*3,600,000) millisecs]        long respawnTime = ((121 + Rnd.get(8)) * 3600000);        GrandBossManager.getInstance().setBossStatus(LIVE_BAIUM,DEAD);        startQuestTimer("baium_unlock", respawnTime, null, null); Antharas        GrandBossManager.getInstance().setBossStatus(ANTHARAS,DEAD);        long respawnTime = ((192 + Rnd.get(145) ) * 3600000);        this.startQuestTimer("antharas_unlock", respawnTime, null, null); Zaken             //time is 36hour	+/- 17hour            long respawnTime = ((19 + Rnd.get(35) ) * 3600000);            startQuestTimer("zaken_unlock", respawnTime, null, null);            cancelQuestTimer("1001", npc, null);            cancelQuestTimer("1003", npc, null); Valakas         //GrandBossManager.getInstance().setBossStatus(VALAKAS,DEAD);        long respawnTime = ((192 + Rnd.get(145) ) * 3600000);        this.startQuestTimer("valakas_unlock", respawnTime, null, null); Orfen             //time is 48hour	+/- 20hour            long respawnTime = (28 + Rnd.get(41) * 3600000);            this.startQuestTimer("orfen_unlock", respawnTime, null, null); Queen ant             //time is 36hour	+/- 17hour            long respawnTime = ((19 + Rnd.get(35) ) * 3600000);            startQuestTimer("queen_unlock", respawnTime, null, null);            cancelQuestTimer("action", npc, null);

the problems they have diferent numbers an variables :l

I need a lil tut or a good samarithan to help me make them 6 hour respawn via ai.


thnx in advance

Re: Grand Boss ai and respawn time formula (lil help here)

Posted: Sun Sep 13, 2009 9:54 pm
by janiii
change the respawn time in each GB file, or is it a problem?

Re: Grand Boss ai and respawn time formula (lil help here)

Posted: Sun Sep 13, 2009 10:22 pm
by chobito
im not good at l2j yet i worked in off for like 7 years :l java for me is kind of new.


trying to learn quickly.


i didnt get ur answer janiii.

my problem is the variables in each .java of the bosses. cause all are multiplicated with 360000 and thats a big number if it is in seconds,, i multiplicated with 6 hours in seconds and grand bosses respawned in minutes X.x


should i edit and put this:
default
long respawnTime = (27 + Rnd.get(47)) * 3600000;


edited?

long respawnTime = (21600;

Re: Grand Boss ai and respawn time formula (lil help here)

Posted: Mon Sep 14, 2009 12:18 am
by momo61

Re: Grand Boss ai and respawn time formula (lil help here)

Posted: Mon Sep 14, 2009 12:56 am
by chobito
looked xD


but it worked for me this formula


deleting all multiplications and just typing 6 hours in miliseconds =)