mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2025-06-28 19:54:44 +02:00
Fixing merge conflicts
This commit is contained in:
@ -9,7 +9,6 @@ import org.bukkit.entity.Ocelot;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.entity.Tameable;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.metadata.FixedMetadataValue;
|
||||
|
||||
import com.gmail.nossr50.mcMMO;
|
||||
import com.gmail.nossr50.locale.LocaleLoader;
|
||||
@ -68,7 +67,7 @@ public class CallOfTheWildEventHandler {
|
||||
return;
|
||||
|
||||
LivingEntity entity = (LivingEntity) player.getWorld().spawnEntity(player.getLocation(), type);
|
||||
mcMMO.p.placeStore.addSpawnedPet((Entity) entity);
|
||||
mcMMO.placeStore.addSpawnedPet((Entity) entity);
|
||||
|
||||
((Tameable) entity).setOwner(player);
|
||||
|
||||
|
@ -12,6 +12,7 @@ public class Taming {
|
||||
public static final int FAST_FOOD_SERVICE_ACTIVATION_CHANCE = advancedConfig.getFastFoodChance();
|
||||
public static final int FAST_FOOD_SERVICE_ACTIVATION_LEVEL = advancedConfig.getFastFoodUnlock();
|
||||
|
||||
public static final int GORE_CHANCE_MAX = AdvancedConfig.getInstance().getGoreChanceMax();
|
||||
public static final int GORE_BLEED_TICKS = advancedConfig.getGoreBleedTicks();
|
||||
public static final int GORE_MAX_BONUS_LEVEL = advancedConfig.getGoreMaxBonusLevel();
|
||||
public static final int GORE_MULTIPLIER = advancedConfig.getGoreModifier();
|
||||
|
@ -8,7 +8,6 @@ import org.bukkit.event.entity.EntityDamageEvent;
|
||||
import org.bukkit.event.entity.EntityDamageEvent.DamageCause;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
|
||||
import com.gmail.nossr50.config.AdvancedConfig;
|
||||
import com.gmail.nossr50.config.Config;
|
||||
import com.gmail.nossr50.datatypes.PlayerProfile;
|
||||
import com.gmail.nossr50.datatypes.SkillType;
|
||||
@ -92,15 +91,15 @@ public class TamingManager {
|
||||
|
||||
GoreEventHandler eventHandler = new GoreEventHandler(this, event);
|
||||
|
||||
int goreChanceMax = AdvancedConfig.getInstance().getGoreChanceMax();
|
||||
int goreMaxLevel = AdvancedConfig.getInstance().getGoreMaxBonusLevel();
|
||||
int randomChance = 100;
|
||||
|
||||
if (Permissions.luckyTaming(player)) {
|
||||
randomChance = (int) (randomChance * 0.75);
|
||||
}
|
||||
|
||||
final float chance = (float) (((double) goreChanceMax / (double) goreMaxLevel) * skillLevel);
|
||||
float chance = (float) (((double) Taming.GORE_CHANCE_MAX / (double) Taming.GORE_MAX_BONUS_LEVEL) * skillLevel);
|
||||
if (chance > Taming.GORE_CHANCE_MAX) chance = Taming.GORE_CHANCE_MAX;
|
||||
|
||||
if (chance > Taming.getRandom().nextInt(randomChance)) {
|
||||
eventHandler.modifyEventDamage();
|
||||
eventHandler.applyBleed();
|
||||
|
Reference in New Issue
Block a user