mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 21:26:46 +01:00
Version 1.0.02 of mcMMO
This commit is contained in:
parent
ecb03aebaf
commit
f016ce1a9d
@ -1,5 +1,21 @@
|
|||||||
Changelog:
|
Changelog:
|
||||||
#Versions without changelogs probably had very small misc fixes, like tweaks to the source code#
|
#Versions without changelogs probably had very small misc fixes, like tweaks to the source code
|
||||||
|
Version 1.0.02
|
||||||
|
Fixed bug where the Timer would start before everything else was ready
|
||||||
|
Fixed bug where mcrefresh also required mcability permission node
|
||||||
|
Fixed bug where Unarmed was not checking for disarm procs
|
||||||
|
Green Thumb now checks for herbalism permissions
|
||||||
|
Added "enableGreenThumbCobbleToMossy" to config file, this also changes Green Terra
|
||||||
|
AoE abilities now harm wolves
|
||||||
|
|
||||||
|
Version 1.0.01
|
||||||
|
Removed debug message when wolves are struck
|
||||||
|
Fixed issue with reloading mcMMO when MySQL was enabled
|
||||||
|
Fixed a NPE with MySpawn
|
||||||
|
Fixed a NPE with removing users from PlayerProfile
|
||||||
|
Unarmed no longer starts with a damage bonus
|
||||||
|
Unarmed apprentice DMG bonus changed from 3 to 2
|
||||||
|
|
||||||
Version 1.0
|
Version 1.0
|
||||||
Players can now repair Stone/Wood tools
|
Players can now repair Stone/Wood tools
|
||||||
Fixed duping bug with WG/Block Protection Plugins
|
Fixed duping bug with WG/Block Protection Plugins
|
||||||
|
@ -63,6 +63,11 @@ public class Combat {
|
|||||||
Axes.axeCriticalCheck(attacker, eventb); //Axe Criticals
|
Axes.axeCriticalCheck(attacker, eventb); //Axe Criticals
|
||||||
if(!Config.getInstance().isBleedTracked(event.getEntity())) //Swords Bleed
|
if(!Config.getInstance().isBleedTracked(event.getEntity())) //Swords Bleed
|
||||||
Swords.bleedCheck(attacker, event.getEntity());
|
Swords.bleedCheck(attacker, event.getEntity());
|
||||||
|
if(event.getEntity() instanceof Player){
|
||||||
|
Player defender = (Player)event.getEntity();
|
||||||
|
Unarmed.disarmProcCheck(attacker, defender);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
//Modify the event damage if Attacker is Berserk
|
//Modify the event damage if Attacker is Berserk
|
||||||
if(PPa.getBerserkMode())
|
if(PPa.getBerserkMode())
|
||||||
@ -70,9 +75,9 @@ public class Combat {
|
|||||||
|
|
||||||
//Handle Ability Interactions
|
//Handle Ability Interactions
|
||||||
if(PPa.getSkullSplitterMode() && m.isAxes(attacker.getItemInHand()))
|
if(PPa.getSkullSplitterMode() && m.isAxes(attacker.getItemInHand()))
|
||||||
Axes.applyAoeDamage(attacker, eventb);
|
Axes.applyAoeDamage(attacker, eventb, pluginx);
|
||||||
if(PPa.getSerratedStrikesMode() && m.isSwords(attacker.getItemInHand()))
|
if(PPa.getSerratedStrikesMode() && m.isSwords(attacker.getItemInHand()))
|
||||||
Swords.applySerratedStrikes(attacker, eventb);
|
Swords.applySerratedStrikes(attacker, eventb, pluginx);
|
||||||
|
|
||||||
//Experience
|
//Experience
|
||||||
if(event.getEntity() instanceof Player)
|
if(event.getEntity() instanceof Player)
|
||||||
@ -208,7 +213,6 @@ public class Combat {
|
|||||||
//Thick Fur
|
//Thick Fur
|
||||||
if(PPo.getTamingInt() >= 250)
|
if(PPo.getTamingInt() >= 250)
|
||||||
event.setDamage(event.getDamage() / 2);
|
event.setDamage(event.getDamage() / 2);
|
||||||
master.sendMessage("mcMMO Debug: Wolf Damage Taken "+event.getDamage());
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -77,8 +77,11 @@ public class Users {
|
|||||||
|
|
||||||
public static void removeUser(Player player){
|
public static void removeUser(Player player){
|
||||||
PlayerProfile PP = Users.getProfile(player);
|
PlayerProfile PP = Users.getProfile(player);
|
||||||
PP.save();
|
if(PP != null){
|
||||||
players.remove(player);
|
PP.save();
|
||||||
|
if(players.containsKey(player))
|
||||||
|
players.remove(player);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static PlayerProfile getProfile(Player player){
|
public static PlayerProfile getProfile(Player player){
|
||||||
|
@ -3,7 +3,7 @@ package com.gmail.nossr50.config;
|
|||||||
import com.gmail.nossr50.mcMMO;
|
import com.gmail.nossr50.mcMMO;
|
||||||
|
|
||||||
public class LoadProperties {
|
public class LoadProperties {
|
||||||
public static Boolean useMySQL, cocoabeans, archeryFireRateLimit, mushrooms, toolsLoseDurabilityFromAbilities, pvpxp, miningrequirespickaxe, woodcuttingrequiresaxe, pvp, eggs, apples, myspawnclearsinventory, cake, music, diamond, glowstone, slowsand, sulphur, netherrack, bones, coal, clay, anvilmessages;
|
public static Boolean enableCobbleToMossy, useMySQL, cocoabeans, archeryFireRateLimit, mushrooms, toolsLoseDurabilityFromAbilities, pvpxp, miningrequirespickaxe, woodcuttingrequiresaxe, pvp, eggs, apples, myspawnclearsinventory, cake, music, diamond, glowstone, slowsand, sulphur, netherrack, bones, coal, clay, anvilmessages;
|
||||||
public static String MySQLtablePrefix, MySQLuserName, MySQLserverName, MySQLdbName, MySQLdbPass, mctop, addxp, mcability, mcmmo, mcc, mcrefresh, mcitem, mcgod, stats, mmoedit, ptp, party, myspawn, setmyspawn, whois, invite, accept, clearmyspawn;
|
public static String MySQLtablePrefix, MySQLuserName, MySQLserverName, MySQLdbName, MySQLdbPass, mctop, addxp, mcability, mcmmo, mcc, mcrefresh, mcitem, mcgod, stats, mmoedit, ptp, party, myspawn, setmyspawn, whois, invite, accept, clearmyspawn;
|
||||||
public static int MySQLport, xpGainMultiplier, superBreakerCooldown, greenTerraCooldown, gigaDrillBreakerCooldown, treeFellerCooldown, berserkCooldown, serratedStrikeCooldown, skullSplitterCooldown, abilityDurabilityLoss, feathersConsumedByChimaeraWing, pvpxprewardmodifier, repairdiamondlevel, globalxpmodifier, tamingxpmodifier, miningxpmodifier, repairxpmodifier, woodcuttingxpmodifier, unarmedxpmodifier, herbalismxpmodifier, excavationxpmodifier, archeryxpmodifier, swordsxpmodifier, axesxpmodifier, acrobaticsxpmodifier;
|
public static int MySQLport, xpGainMultiplier, superBreakerCooldown, greenTerraCooldown, gigaDrillBreakerCooldown, treeFellerCooldown, berserkCooldown, serratedStrikeCooldown, skullSplitterCooldown, abilityDurabilityLoss, feathersConsumedByChimaeraWing, pvpxprewardmodifier, repairdiamondlevel, globalxpmodifier, tamingxpmodifier, miningxpmodifier, repairxpmodifier, woodcuttingxpmodifier, unarmedxpmodifier, herbalismxpmodifier, excavationxpmodifier, archeryxpmodifier, swordsxpmodifier, axesxpmodifier, acrobaticsxpmodifier;
|
||||||
|
|
||||||
@ -39,6 +39,7 @@ public class LoadProperties {
|
|||||||
* OTHER
|
* OTHER
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
enableCobbleToMossy = properties.getBoolean("enableGreenThumbCobbleToMossy", true);
|
||||||
archeryFireRateLimit = properties.getBoolean("archeryFireRateLimit", true);
|
archeryFireRateLimit = properties.getBoolean("archeryFireRateLimit", true);
|
||||||
xpGainMultiplier = properties.getInteger("xpGainMultiplier", 1);
|
xpGainMultiplier = properties.getInteger("xpGainMultiplier", 1);
|
||||||
toolsLoseDurabilityFromAbilities = properties.getBoolean("toolsLoseDurabilityFromAbilities", true);
|
toolsLoseDurabilityFromAbilities = properties.getBoolean("toolsLoseDurabilityFromAbilities", true);
|
||||||
|
@ -1655,19 +1655,31 @@ public class PlayerProfile
|
|||||||
save();
|
save();
|
||||||
}
|
}
|
||||||
public String getX(){
|
public String getX(){
|
||||||
|
if(myspawn != null)
|
||||||
|
{
|
||||||
String[] split = myspawn.split(",");
|
String[] split = myspawn.split(",");
|
||||||
String x = split[0];
|
return split[0];
|
||||||
return x;
|
}
|
||||||
|
else
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
public String getY(){
|
public String getY(){
|
||||||
|
if(myspawn != null)
|
||||||
|
{
|
||||||
String[] split = myspawn.split(",");
|
String[] split = myspawn.split(",");
|
||||||
String y = split[1];
|
return split[1];
|
||||||
return y;
|
}
|
||||||
|
else
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
public String getZ(){
|
public String getZ(){
|
||||||
|
if(myspawn != null)
|
||||||
|
{
|
||||||
String[] split = myspawn.split(",");
|
String[] split = myspawn.split(",");
|
||||||
String z = split[2];
|
return split[2];
|
||||||
return z;
|
}
|
||||||
|
else
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
public void setDead(boolean x){
|
public void setDead(boolean x){
|
||||||
dead = x;
|
dead = x;
|
||||||
@ -1678,10 +1690,13 @@ public class PlayerProfile
|
|||||||
}
|
}
|
||||||
public Location getMySpawn(Player player){
|
public Location getMySpawn(Player player){
|
||||||
Location loc = null;
|
Location loc = null;
|
||||||
if(isDouble(getX()) && isDouble(getY()) && isDouble(getZ()))
|
if(myspawn != null){
|
||||||
loc = new Location(player.getWorld(),(Double.parseDouble(getX())), Double.parseDouble(getY()), Double.parseDouble(getZ()));
|
if(isDouble(getX()) && isDouble(getY()) && isDouble(getZ()))
|
||||||
|
loc = new Location(player.getWorld(),(Double.parseDouble(getX())), Double.parseDouble(getY()), Double.parseDouble(getZ()));
|
||||||
else
|
else
|
||||||
return null;
|
return null;
|
||||||
|
} else
|
||||||
|
return null;
|
||||||
|
|
||||||
loc.setYaw(0);
|
loc.setYaw(0);
|
||||||
loc.setPitch(0);
|
loc.setPitch(0);
|
||||||
|
@ -797,10 +797,10 @@ public class m {
|
|||||||
if(PP.getUnarmedInt() < 250){
|
if(PP.getUnarmedInt() < 250){
|
||||||
player.sendMessage(ChatColor.GRAY+"LOCKED UNTIL 250+ SKILL (UNARMED APPRENTICE)");
|
player.sendMessage(ChatColor.GRAY+"LOCKED UNTIL 250+ SKILL (UNARMED APPRENTICE)");
|
||||||
} else if(PP.getUnarmedInt() >= 250 && PP.getUnarmedInt() < 500){
|
} else if(PP.getUnarmedInt() >= 250 && PP.getUnarmedInt() < 500){
|
||||||
player.sendMessage(ChatColor.RED+"Unarmed Apprentice: "+ChatColor.YELLOW+"Damage Upgrade");
|
player.sendMessage(ChatColor.RED+"Unarmed Apprentice: "+ChatColor.YELLOW+"+2 DMG Upgrade");
|
||||||
player.sendMessage(ChatColor.GRAY+"LOCKED UNTIL 500+ SKILL (UNARMED MASTERY)");
|
player.sendMessage(ChatColor.GRAY+"LOCKED UNTIL 500+ SKILL (UNARMED MASTERY)");
|
||||||
} else {
|
} else {
|
||||||
player.sendMessage(ChatColor.RED+"Unarmed Mastery: "+ChatColor.YELLOW+"Large Damage Upgrade");
|
player.sendMessage(ChatColor.RED+"Unarmed Mastery: "+ChatColor.YELLOW+"+4 DMG Upgrade");
|
||||||
}
|
}
|
||||||
player.sendMessage(ChatColor.RED+"Berserk Length: "+ChatColor.YELLOW+ticks+"s");
|
player.sendMessage(ChatColor.RED+"Berserk Length: "+ChatColor.YELLOW+ticks+"s");
|
||||||
}
|
}
|
||||||
|
@ -51,12 +51,10 @@ public class mcMMO extends JavaPlugin {
|
|||||||
public static Database database = null;
|
public static Database database = null;
|
||||||
|
|
||||||
public void onEnable() {
|
public void onEnable() {
|
||||||
mcMMO_Timer.schedule(new mcTimer(this), (long)0, (long)(1000));
|
|
||||||
new File(maindirectory).mkdir();
|
new File(maindirectory).mkdir();
|
||||||
mcProperties.makeProperties(Properties, log); //Make Props file
|
mcProperties.makeProperties(Properties, log); //Make Props file
|
||||||
LoadProperties.loadMain(); //Load Props file
|
LoadProperties.loadMain(); //Load Props file
|
||||||
Users.getInstance().loadUsers(); //Load Users file
|
Users.getInstance().loadUsers(); //Load Users file
|
||||||
for(Player player : getServer().getOnlinePlayers()){Users.addUser(player);} //In case of reload add all users back into PlayerProfile
|
|
||||||
/*
|
/*
|
||||||
* REGISTER EVENTS
|
* REGISTER EVENTS
|
||||||
*/
|
*/
|
||||||
@ -83,7 +81,9 @@ public class mcMMO extends JavaPlugin {
|
|||||||
database.createStructure(); //Make Structure
|
database.createStructure(); //Make Structure
|
||||||
if(!LoadProperties.useMySQL)
|
if(!LoadProperties.useMySQL)
|
||||||
Leaderboard.makeLeaderboards(); //Make the leaderboards
|
Leaderboard.makeLeaderboards(); //Make the leaderboards
|
||||||
|
for(Player player : getServer().getOnlinePlayers()){Users.addUser(player);} //In case of reload add all users back into PlayerProfile
|
||||||
System.out.println( pdfFile.getName() + " version " + pdfFile.getVersion() + " is enabled!" );
|
System.out.println( pdfFile.getName() + " version " + pdfFile.getVersion() + " is enabled!" );
|
||||||
|
mcMMO_Timer.schedule(new mcTimer(this), (long)0, (long)(1000));
|
||||||
}
|
}
|
||||||
|
|
||||||
private void mcLoadMySQL() {
|
private void mcLoadMySQL() {
|
||||||
|
@ -136,9 +136,9 @@ public class mcPlayerListener extends PlayerListener {
|
|||||||
//GREEN THUMB
|
//GREEN THUMB
|
||||||
if(block != null && (block.getType() == Material.COBBLESTONE || block.getType() == Material.DIRT) && player.getItemInHand().getType() == Material.SEEDS){
|
if(block != null && (block.getType() == Material.COBBLESTONE || block.getType() == Material.DIRT) && player.getItemInHand().getType() == Material.SEEDS){
|
||||||
boolean pass = false;
|
boolean pass = false;
|
||||||
if(Herbalism.hasSeeds(player)){
|
if(Herbalism.hasSeeds(player) && mcPermissions.getInstance().herbalism(player)){
|
||||||
Herbalism.removeSeeds(player);
|
Herbalism.removeSeeds(player);
|
||||||
if(block.getType() == Material.COBBLESTONE && Math.random() * 1500 <= PP.getHerbalismInt()){
|
if(LoadProperties.enableCobbleToMossy && block.getType() == Material.COBBLESTONE && Math.random() * 1500 <= PP.getHerbalismInt()){
|
||||||
player.sendMessage(ChatColor.GREEN+"**GREEN THUMB**");
|
player.sendMessage(ChatColor.GREEN+"**GREEN THUMB**");
|
||||||
block.setType(Material.MOSSY_COBBLESTONE);
|
block.setType(Material.MOSSY_COBBLESTONE);
|
||||||
pass = true;
|
pass = true;
|
||||||
@ -193,21 +193,17 @@ public class mcPlayerListener extends PlayerListener {
|
|||||||
PP.toggleAbilityUse();
|
PP.toggleAbilityUse();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(split[0].equalsIgnoreCase("/details")){
|
|
||||||
event.setCancelled(true);
|
|
||||||
player.getLocation().getWorld().spawnCreature(player.getLocation(), CreatureType.WOLF);
|
|
||||||
player.getLocation().getWorld().spawnCreature(player.getLocation(), CreatureType.WOLF);
|
|
||||||
player.sendMessage("Material : "+player.getItemInHand().getType());
|
|
||||||
player.sendMessage("Type ID : "+player.getItemInHand().getTypeId());
|
|
||||||
player.sendMessage("Byte Data : "+player.getItemInHand().getDurability());
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* FFS -> MySQL
|
* FFS -> MySQL
|
||||||
*/
|
*/
|
||||||
if(split[0].equalsIgnoreCase("/mmoupdate") && mcPermissions.getInstance().admin(player))
|
if(split[0].equalsIgnoreCase("/mmoupdate"))
|
||||||
{
|
{
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
|
if(!mcPermissions.getInstance().admin(player)){
|
||||||
|
player.sendMessage(ChatColor.YELLOW+"[MMO]"+ChatColor.DARK_RED +" Insufficient mcPermissions.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
player.sendMessage(ChatColor.GRAY+"Starting conversion...");
|
player.sendMessage(ChatColor.GRAY+"Starting conversion...");
|
||||||
Users.clearUsers();
|
Users.clearUsers();
|
||||||
m.convertToMySQL(plugin);
|
m.convertToMySQL(plugin);
|
||||||
@ -230,7 +226,7 @@ public class mcPlayerListener extends PlayerListener {
|
|||||||
if(split.length == 1){
|
if(split.length == 1){
|
||||||
int p = 1;
|
int p = 1;
|
||||||
String[] info = Leaderboard.retrieveInfo("powerlevel", p);
|
String[] info = Leaderboard.retrieveInfo("powerlevel", p);
|
||||||
player.sendMessage(ChatColor.YELLOW+"--MMO"+ChatColor.BLUE+" Power Level "+ChatColor.YELLOW+"Leaderboard--");
|
player.sendMessage(ChatColor.YELLOW+"--mcMMO"+ChatColor.BLUE+" Power Level "+ChatColor.YELLOW+"Leaderboard--");
|
||||||
int n = 1 * p; //Position
|
int n = 1 * p; //Position
|
||||||
for(String x : info){
|
for(String x : info){
|
||||||
if(x != null){
|
if(x != null){
|
||||||
@ -259,7 +255,7 @@ public class mcPlayerListener extends PlayerListener {
|
|||||||
pt = 10;
|
pt = 10;
|
||||||
}
|
}
|
||||||
String[] info = Leaderboard.retrieveInfo("powerlevel", p);
|
String[] info = Leaderboard.retrieveInfo("powerlevel", p);
|
||||||
player.sendMessage("--MMO Power Level Leaderboard--");
|
player.sendMessage("--mcMMO Power Level Leaderboard--");
|
||||||
int n = 1 * pt; //Position
|
int n = 1 * pt; //Position
|
||||||
for(String x : info){
|
for(String x : info){
|
||||||
if(x != null){
|
if(x != null){
|
||||||
@ -295,7 +291,7 @@ public class mcPlayerListener extends PlayerListener {
|
|||||||
String capitalized = firstLetter.toUpperCase() + remainder.toLowerCase();
|
String capitalized = firstLetter.toUpperCase() + remainder.toLowerCase();
|
||||||
|
|
||||||
String[] info = Leaderboard.retrieveInfo(split[1].toLowerCase(), p);
|
String[] info = Leaderboard.retrieveInfo(split[1].toLowerCase(), p);
|
||||||
player.sendMessage(ChatColor.YELLOW+"--MMO "+ChatColor.BLUE+capitalized+ChatColor.YELLOW+" Leaderboard--");
|
player.sendMessage(ChatColor.YELLOW+"--mcMMO "+ChatColor.BLUE+capitalized+ChatColor.YELLOW+" Leaderboard--");
|
||||||
int n = 1 * pt; //Position
|
int n = 1 * pt; //Position
|
||||||
for(String x : info){
|
for(String x : info){
|
||||||
if(x != null){
|
if(x != null){
|
||||||
@ -400,7 +396,7 @@ public class mcPlayerListener extends PlayerListener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(mcPermissions.getInstance().mcAbility(player) && split[0].equalsIgnoreCase("/"+LoadProperties.mcrefresh)){
|
if(split[0].equalsIgnoreCase("/"+LoadProperties.mcrefresh)){
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
if(!mcPermissions.getInstance().mcrefresh(player)){
|
if(!mcPermissions.getInstance().mcrefresh(player)){
|
||||||
player.sendMessage(ChatColor.YELLOW+"[MMO]"+ChatColor.DARK_RED +" Insufficient mcPermissions.");
|
player.sendMessage(ChatColor.YELLOW+"[MMO]"+ChatColor.DARK_RED +" Insufficient mcPermissions.");
|
||||||
|
@ -7,6 +7,7 @@ import org.bukkit.entity.Monster;
|
|||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
import org.bukkit.entity.Wolf;
|
import org.bukkit.entity.Wolf;
|
||||||
import org.bukkit.event.entity.EntityDamageByEntityEvent;
|
import org.bukkit.event.entity.EntityDamageByEntityEvent;
|
||||||
|
import org.bukkit.plugin.Plugin;
|
||||||
|
|
||||||
import com.gmail.nossr50.Users;
|
import com.gmail.nossr50.Users;
|
||||||
import com.gmail.nossr50.m;
|
import com.gmail.nossr50.m;
|
||||||
@ -48,7 +49,7 @@ public class Axes {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void applyAoeDamage(Player attacker, EntityDamageByEntityEvent event){
|
public static void applyAoeDamage(Player attacker, EntityDamageByEntityEvent event, Plugin pluginx){
|
||||||
int targets = 0;
|
int targets = 0;
|
||||||
Entity x = event.getEntity();
|
Entity x = event.getEntity();
|
||||||
targets = m.getTier(attacker);
|
targets = m.getTier(attacker);
|
||||||
@ -70,7 +71,11 @@ public class Axes {
|
|||||||
targets--;
|
targets--;
|
||||||
}
|
}
|
||||||
if(derp instanceof Wolf){
|
if(derp instanceof Wolf){
|
||||||
continue;
|
Wolf hurrDurr = (Wolf)derp;
|
||||||
|
if(Taming.getOwner(hurrDurr, pluginx) == attacker)
|
||||||
|
continue;
|
||||||
|
if(Party.getInstance().inSameParty(attacker, Taming.getOwner(hurrDurr, pluginx)))
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
if(derp instanceof Animals && targets >= 1){
|
if(derp instanceof Animals && targets >= 1){
|
||||||
Animals target = (Animals)derp;
|
Animals target = (Animals)derp;
|
||||||
|
@ -46,7 +46,7 @@ public class Herbalism {
|
|||||||
removeSeeds(player);
|
removeSeeds(player);
|
||||||
if(block.getType() == Material.DIRT)
|
if(block.getType() == Material.DIRT)
|
||||||
block.setType(Material.GRASS);
|
block.setType(Material.GRASS);
|
||||||
if(block.getType() == Material.COBBLESTONE)
|
if(LoadProperties.enableCobbleToMossy && block.getType() == Material.COBBLESTONE)
|
||||||
block.setType(Material.MOSSY_COBBLESTONE);
|
block.setType(Material.MOSSY_COBBLESTONE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -10,6 +10,7 @@ import org.bukkit.entity.Wolf;
|
|||||||
import org.bukkit.event.entity.EntityDamageByEntityEvent;
|
import org.bukkit.event.entity.EntityDamageByEntityEvent;
|
||||||
import org.bukkit.event.entity.EntityDamageByProjectileEvent;
|
import org.bukkit.event.entity.EntityDamageByProjectileEvent;
|
||||||
import org.bukkit.event.entity.EntityDamageEvent;
|
import org.bukkit.event.entity.EntityDamageEvent;
|
||||||
|
import org.bukkit.plugin.Plugin;
|
||||||
|
|
||||||
import com.gmail.nossr50.Combat;
|
import com.gmail.nossr50.Combat;
|
||||||
import com.gmail.nossr50.Users;
|
import com.gmail.nossr50.Users;
|
||||||
@ -45,7 +46,7 @@ public class Swords {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public static void applySerratedStrikes(Player attacker, EntityDamageByEntityEvent event){
|
public static void applySerratedStrikes(Player attacker, EntityDamageByEntityEvent event, Plugin pluginx){
|
||||||
int targets = 0;
|
int targets = 0;
|
||||||
Entity x = event.getEntity();
|
Entity x = event.getEntity();
|
||||||
targets = m.getTier(attacker);
|
targets = m.getTier(attacker);
|
||||||
@ -70,7 +71,11 @@ public class Swords {
|
|||||||
targets--;
|
targets--;
|
||||||
}
|
}
|
||||||
if(derp instanceof Wolf){
|
if(derp instanceof Wolf){
|
||||||
continue;
|
Wolf hurrDurr = (Wolf)derp;
|
||||||
|
if(Taming.getOwner(hurrDurr, pluginx) == attacker)
|
||||||
|
continue;
|
||||||
|
if(Party.getInstance().inSameParty(attacker, Taming.getOwner(hurrDurr, pluginx)))
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
if(derp instanceof Animals && targets >= 1){
|
if(derp instanceof Animals && targets >= 1){
|
||||||
if(!Config.getInstance().isBleedTracked(derp))
|
if(!Config.getInstance().isBleedTracked(derp))
|
||||||
|
@ -13,11 +13,11 @@ public class Unarmed {
|
|||||||
public static void unarmedBonus(Player attacker, EntityDamageByEntityEvent event)
|
public static void unarmedBonus(Player attacker, EntityDamageByEntityEvent event)
|
||||||
{
|
{
|
||||||
PlayerProfile PPa = Users.getProfile(attacker);
|
PlayerProfile PPa = Users.getProfile(attacker);
|
||||||
int bonus = 2;
|
int bonus = 0;
|
||||||
if (PPa.getUnarmedInt() >= 250)
|
if (PPa.getUnarmedInt() >= 250)
|
||||||
bonus++;
|
bonus+=2;
|
||||||
if (PPa.getUnarmedInt() >= 500)
|
if (PPa.getUnarmedInt() >= 500)
|
||||||
bonus++;
|
bonus+=2;
|
||||||
event.setDamage(event.getDamage()+bonus);
|
event.setDamage(event.getDamage()+bonus);
|
||||||
}
|
}
|
||||||
public static void disarmProcCheck(Player attacker, Player defender)
|
public static void disarmProcCheck(Player attacker, Player defender)
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
name: mcMMO
|
name: mcMMO
|
||||||
main: com.gmail.nossr50.mcMMO
|
main: com.gmail.nossr50.mcMMO
|
||||||
version: 1.0
|
version: 1.0.02
|
Loading…
Reference in New Issue
Block a user