mob loot system addressed
This commit is contained in:
@@ -76,8 +76,7 @@ public enum LootManager {
|
|||||||
|
|
||||||
public static void GenerateMobLoot(Mob mob) {
|
public static void GenerateMobLoot(Mob mob) {
|
||||||
|
|
||||||
//no loot for safezones
|
if(mob == null){
|
||||||
if(mob == null || mob.getSafeZone()){
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -186,14 +185,16 @@ public enum LootManager {
|
|||||||
|
|
||||||
|
|
||||||
// Iterate all entries in this bootySet and process accordingly
|
// Iterate all entries in this bootySet and process accordingly
|
||||||
|
Zone zone = ZoneManager.findSmallestZone(mob.loc);
|
||||||
for (BootySetEntry bse : entries) {
|
for (BootySetEntry bse : entries) {
|
||||||
switch (bse.bootyType) {
|
switch (bse.bootyType) {
|
||||||
case "GOLD":
|
case "GOLD":
|
||||||
|
if (zone != null && zone.getSafeZone() == (byte)1)
|
||||||
|
return; // no loot to drop in safezones
|
||||||
GenerateGoldDrop(mob, bse, inHotzone);
|
GenerateGoldDrop(mob, bse, inHotzone);
|
||||||
break;
|
break;
|
||||||
case "LOOT":
|
case "LOOT":
|
||||||
|
if (zone != null && zone.getSafeZone() == (byte)1)
|
||||||
if (mob.getSafeZone())
|
|
||||||
return; // no loot to drop in safezones
|
return; // no loot to drop in safezones
|
||||||
|
|
||||||
dropRate = LootManager.NORMAL_DROP_RATE;
|
dropRate = LootManager.NORMAL_DROP_RATE;
|
||||||
|
|||||||
@@ -884,7 +884,6 @@ public class MobAI {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
aiAgent.despawn();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user