[FIXED] Raid bosses minions not spawn on server launch
Forum rules
READ NOW: L2j Forums Rules of Conduct
READ NOW: L2j Forums Rules of Conduct
-
- Posts:3
- Joined:Wed Sep 19, 2018 10:21 pm
Hello. So i have problem and seems cant find solution. I using latest development branch of h5.
So problem is when gameserver just launched, all bosses that must have minions just standing alone. If rb get killed and respawned by normal means or another instance of rb is spawned through admin console, minions are spawned as well and all seems working fine, but if server restarted after that minions are gone again.
And there is no any errors in console output, so i even dont know where to look...
So problem is when gameserver just launched, all bosses that must have minions just standing alone. If rb get killed and respawned by normal means or another instance of rb is spawned through admin console, minions are spawned as well and all seems working fine, but if server restarted after that minions are gone again.
And there is no any errors in console output, so i even dont know where to look...
-
- Posts:58
- Joined:Wed Mar 23, 2016 2:05 am
- Location:Russia
- Contact:
Re: Raid bosses minions not spawn on server launch
I confirm, there is such a problem on the server. And how to fix, too, can not find.
-
- Posts:3
- Joined:Wed Sep 19, 2018 10:21 pm
Re: Raid bosses minions not spawn on server launch
Looks like at last i found problem.
In gameserver.java its needed to be RaidBossSpawnManager.getInstance().load(); not just RaidBossSpawnManager.getInstance();
At least all rb now spawning with minions, and no any compile errors
In gameserver.java its needed to be RaidBossSpawnManager.getInstance().load(); not just RaidBossSpawnManager.getInstance();
At least all rb now spawning with minions, and no any compile errors
-
- Posts:58
- Joined:Wed Mar 23, 2016 2:05 am
- Location:Russia
- Contact:
Re: Raid bosses minions not spawn on server launch
Checked, everything works fine. Thank you jonhanon! 

-
- Advanced User
- Posts:1025
- Joined:Thu Aug 14, 2014 6:31 am
- Location:Spain
Re: Raid bosses minions not spawn on server launch
Code: Select all
RaidBossSpawnManager.getInstance();
Code: Select all
load();

RaidBossSpawnManager class require too much rework and not only 6 characters that you're adding.
Without no mention internal class
Code: Select all
MinionData

Retail GameMaster and Developer using Eclipse for Java Developers (64 bits), OpenJDK14 (64 bits), MySQL 8.0+ (64 bits).
-
- Posts:58
- Joined:Wed Mar 23, 2016 2:05 am
- Location:Russia
- Contact:
Re: Raid bosses minions not spawn on server launch
I understand, but here it works (RaidBossSpawnManager.getInstance (). load ()) and all raid bosses stand with minenes, and when spelled out (RaidBossSpawnManager.getInstance ()) then redBosses stand without miniens.Sacrifice wrote: ↑Tue Jun 25, 2019 4:37 pmin gameserver class is sufficient for all, because the constructor calls, on instantiation of the class at the methodCode: Select all
RaidBossSpawnManager.getInstance();
or something like that, that's meaning that you're duplicating things if you completed the code with this stuff...Code: Select all
load();
RaidBossSpawnManager class require too much rework and not only 6 characters that you're adding.
Without no mention internal class... That require some things more...Code: Select all
MinionData
![]()
-
- Advanced User
- Posts:1025
- Joined:Thu Aug 14, 2014 6:31 am
- Location:Spain
Re: Raid bosses minions not spawn on server launch
I tell you that this is not the best fix, does it work? Yes, but it is not the best fix.
At least I edited about 100 lines of that class and eliminated many more, and in the datapack I also made quite a few deletions and editions related to that.
If that makes you happy ... Ole!
At least I edited about 100 lines of that class and eliminated many more, and in the datapack I also made quite a few deletions and editions related to that.
If that makes you happy ... Ole!
Retail GameMaster and Developer using Eclipse for Java Developers (64 bits), OpenJDK14 (64 bits), MySQL 8.0+ (64 bits).
-
- Posts:58
- Joined:Wed Mar 23, 2016 2:05 am
- Location:Russia
- Contact:
Re: Raid bosses minions not spawn on server launch
it's not about happiness. I'm not saying that this is a panacea, it can just be used until the fix for this bug is released.Sacrifice wrote: ↑Thu Jun 27, 2019 4:44 amI tell you that this is not the best fix, does it work? Yes, but it is not the best fix.
At least I edited about 100 lines of that class and eliminated many more, and in the datapack I also made quite a few deletions and editions related to that.
If that makes you happy ... Ole!
-
- Advanced User
- Posts:1025
- Joined:Thu Aug 14, 2014 6:31 am
- Location:Spain
Re: Raid bosses minions not spawn on server launch
Okey, no problem them



Retail GameMaster and Developer using Eclipse for Java Developers (64 bits), OpenJDK14 (64 bits), MySQL 8.0+ (64 bits).
- Avanael92
- Advanced User
- Posts:189
- Joined:Thu Aug 07, 2014 5:26 pm
- Location:Germany
Re: Raid bosses minions not spawn on server launch
I don't think that's the problem. With your "fix" you're calling load() twice, nothing else. You're just putting a band-aid on without knowing what's the cause. What about codes that are supposed to launch one time? That's really bad practice what you're doing.
For me minions are spawning just fine after launch and restart. So I guess the problem lies somewhere else.
For me minions are spawning just fine after launch and restart. So I guess the problem lies somewhere else.
-
- Posts:58
- Joined:Wed Mar 23, 2016 2:05 am
- Location:Russia
- Contact:
Re: Raid bosses minions not spawn on server launch
here is a completely revised and revised script. Now everything will spawn without the above mentioned addition.Avanael92 wrote: ↑Sat Jun 29, 2019 11:27 amI don't think that's the problem. With your "fix" you're calling load() twice, nothing else. You're just putting a band-aid on without knowing what's the cause. What about codes that are supposed to launch one time? That's really bad practice what you're doing.
For me minions are spawning just fine after launch and restart. So I guess the problem lies somewhere else.
You do not have the required permissions to view the files attached to this post.
- Avanael92
- Advanced User
- Posts:189
- Joined:Thu Aug 07, 2014 5:26 pm
- Location:Germany
Re: Raid bosses minions not spawn on server launch
I don't see how that's revised. You didn't change anything related to minions not spawning. The code is literally 99% the same as mine, you just shorted the code a little bit and changed respawntime from long to int. 
You should consider changing respawntime back to long asap. The respawn time is saved as unix timestamp in milliseconds and those go way over the max value of int.
Example:
Unix Timestamp: +1,561,916,406,096
Max int value: +2,147,483,647

You should consider changing respawntime back to long asap. The respawn time is saved as unix timestamp in milliseconds and those go way over the max value of int.
Example:
Unix Timestamp: +1,561,916,406,096
Max int value: +2,147,483,647
-
- Advanced User
- Posts:1025
- Joined:Thu Aug 14, 2014 6:31 am
- Location:Spain
Re: Raid bosses minions not spawn on server launch
Avanael92, will he have to learn one day? Don't?...
Edoogel, not are sufficient mister.
Edoogel, not are sufficient mister.
Retail GameMaster and Developer using Eclipse for Java Developers (64 bits), OpenJDK14 (64 bits), MySQL 8.0+ (64 bits).
-
- Posts:1
- Joined:Fri Jun 26, 2020 4:42 pm
Re: Raid bosses minions not spawn on server launch
Hello.
In public void addNewSpawn() function in RaidBossSpawnManager class, i have added after the following line:
this:
This activates the scheduling mechanism. The raid bosses that are alive should not be loaded directly, but should simulate being loaded with a delay. This way you can "temporarily" fix the problem without affecting the overall system performance.
Obviously, this technique should be improved and implemented in a better way or keep looking for the previous error.
I'm not quite sure, but I think something must be happening in the script loading order.
Regards!
In public void addNewSpawn() function in RaidBossSpawnManager class, i have added after the following line:
Code: Select all
final long time = Calendar.getInstance().getTimeInMillis();
Code: Select all
...
if (respawnTime == 0L) {
respawnTime = time + 50000;
}
...
Obviously, this technique should be improved and implemented in a better way or keep looking for the previous error.
I'm not quite sure, but I think something must be happening in the script loading order.
Regards!
- Zoey76
- L2j Inner Circle
- Posts:7004
- Joined:Tue Aug 11, 2009 3:36 am
Re: Raid bosses minions not spawn on server launch
The problem seems to be that MinionSpawnManager (datapack script) is loaded after onSpawn() event was already notified, seems it was not tested when it was moved from core to datapack.