|
|
|
@ -9,7 +9,6 @@
@@ -9,7 +9,6 @@
|
|
|
|
|
|
|
|
|
|
package engine.objects; |
|
|
|
|
|
|
|
|
|
import ch.claude_martin.enumbitset.EnumBitSet; |
|
|
|
|
import engine.gameManager.DbManager; |
|
|
|
|
import engine.gameManager.LootManager; |
|
|
|
|
import engine.loot.BootySetEntry; |
|
|
|
@ -39,7 +38,7 @@ public class MobBase extends AbstractGameObject {
@@ -39,7 +38,7 @@ public class MobBase extends AbstractGameObject {
|
|
|
|
|
private float damageMin; |
|
|
|
|
private float damageMax; |
|
|
|
|
private float hitBoxRadius; |
|
|
|
|
private EnumBitSet<mbEnums.MobFlagType> flags; |
|
|
|
|
private EnumSet<mbEnums.MobFlagType> flags; |
|
|
|
|
private int mask; |
|
|
|
|
private int goldMod; |
|
|
|
|
private int seeInvis; |
|
|
|
@ -77,7 +76,7 @@ public class MobBase extends AbstractGameObject {
@@ -77,7 +76,7 @@ public class MobBase extends AbstractGameObject {
|
|
|
|
|
|
|
|
|
|
this.fsm = mbEnums.MobBehaviourType.valueOf(rs.getString("fsm")); |
|
|
|
|
|
|
|
|
|
this.flags = EnumBitSet.asEnumBitSet(rs.getLong("flags"), mbEnums.MobFlagType.class); |
|
|
|
|
this.flags = mbEnums.fromLong(rs.getLong("flags"), mbEnums.MobFlagType.class); |
|
|
|
|
this.notEnemy = mbEnums.fromLong(rs.getLong("notEnemy"), mbEnums.MonsterType.class); |
|
|
|
|
this.enemy = mbEnums.fromLong(rs.getLong("enemy"), mbEnums.MonsterType.class); |
|
|
|
|
|
|
|
|
@ -89,19 +88,19 @@ public class MobBase extends AbstractGameObject {
@@ -89,19 +88,19 @@ public class MobBase extends AbstractGameObject {
|
|
|
|
|
if (this.getObjectUUID() == 12021 || this.getObjectUUID() == 12022) |
|
|
|
|
this.isNecroPet = true; |
|
|
|
|
|
|
|
|
|
if (mbEnums.MobFlagType.HUMANOID.elementOf(this.flags)) |
|
|
|
|
if (this.flags.contains(mbEnums.MobFlagType.HUMANOID)) |
|
|
|
|
this.mask += MBServerStatics.MASK_HUMANOID; |
|
|
|
|
|
|
|
|
|
if (mbEnums.MobFlagType.UNDEAD.elementOf(this.flags)) |
|
|
|
|
if (this.flags.contains(mbEnums.MobFlagType.UNDEAD)) |
|
|
|
|
this.mask += MBServerStatics.MASK_UNDEAD; |
|
|
|
|
|
|
|
|
|
if (mbEnums.MobFlagType.BEAST.elementOf(this.flags)) |
|
|
|
|
if (this.flags.contains(mbEnums.MobFlagType.BEAST)) |
|
|
|
|
this.mask += MBServerStatics.MASK_BEAST; |
|
|
|
|
|
|
|
|
|
if (mbEnums.MobFlagType.DRAGON.elementOf(this.flags)) |
|
|
|
|
if (this.flags.contains(mbEnums.MobFlagType.DRAGON)) |
|
|
|
|
this.mask += MBServerStatics.MASK_DRAGON; |
|
|
|
|
|
|
|
|
|
if (mbEnums.MobFlagType.RAT.elementOf(this.flags)) |
|
|
|
|
if (this.flags.contains(mbEnums.MobFlagType.RAT)) |
|
|
|
|
this.mask += MBServerStatics.MASK_RAT; |
|
|
|
|
|
|
|
|
|
this.mobBaseStats = DbManager.MobBaseQueries.LOAD_STATS(this.loadID); |
|
|
|
@ -204,7 +203,7 @@ public class MobBase extends AbstractGameObject {
@@ -204,7 +203,7 @@ public class MobBase extends AbstractGameObject {
|
|
|
|
|
return this.defenseRating; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public EnumBitSet<mbEnums.MobFlagType> getFlags() { |
|
|
|
|
public EnumSet<mbEnums.MobFlagType> getFlags() { |
|
|
|
|
return this.flags; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|