Fix some affixes not working

This commit is contained in:
StartForKiller 2023-06-06 18:07:40 -04:00 committed by KingRainbow44
parent 1c9f32cbef
commit 0f43e18d70
No known key found for this signature in database
GPG Key ID: FC2CB64B00D257BE

View File

@ -113,7 +113,12 @@ public class EntityMonster extends GameEntity {
if(monster != null) affixes = monster.affix;
}
if (affixes != null) {
if (monsterData != null) {
if (affixes == null) affixes = monsterData.getAffix();
else affixes.addAll(monsterData.getAffix());
}
if(affixes != null) {
for(var affixId : affixes) {
var affix = GameData.getMonsterAffixDataMap().get(affixId.intValue());
if (!affix.isPreAdd()) continue;