mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 21:26:46 +01:00
mcMMO 1.0.05
This commit is contained in:
parent
dfd7f8839c
commit
139f50c5d1
@ -1,5 +1,12 @@
|
||||
Changelog:
|
||||
#Versions without changelogs probably had very small misc fixes, like tweaks to the source code
|
||||
|
||||
Version 1.0.05
|
||||
PVP interactions now check for permissions before handing out any experience
|
||||
Many skill abilities now check for permissions correctly
|
||||
All interactions with Taming now check for permissions
|
||||
mcMMO now checks for its pvp flag being true before handling pvp interactions
|
||||
|
||||
Version 1.0.04
|
||||
Fixed bug where players would be informed incorrectly when their cooldowns refreshed
|
||||
Fixed exploit where players could reconnect to reset their cooldowns
|
||||
|
@ -60,10 +60,11 @@ public class Combat {
|
||||
combatAbilityChecks(attacker, PPa, pluginx);
|
||||
|
||||
//Check for offensive procs
|
||||
if(mcPermissions.getInstance().axes(attacker))
|
||||
Axes.axeCriticalCheck(attacker, eventb, pluginx); //Axe Criticals
|
||||
if(!Config.getInstance().isBleedTracked(event.getEntity())) //Swords Bleed
|
||||
Swords.bleedCheck(attacker, event.getEntity(), pluginx);
|
||||
if(event.getEntity() instanceof Player){
|
||||
if(event.getEntity() instanceof Player && mcPermissions.getInstance().unarmed(attacker)){
|
||||
Player defender = (Player)event.getEntity();
|
||||
Unarmed.disarmProcCheck(attacker, defender);
|
||||
}
|
||||
@ -88,11 +89,11 @@ public class Combat {
|
||||
{
|
||||
if(System.currentTimeMillis() >= PPd.getRespawnATS() + 5000 && defender.getHealth() >= 1)
|
||||
{
|
||||
if(m.isAxes(attacker.getItemInHand()))
|
||||
if(m.isAxes(attacker.getItemInHand()) && mcPermissions.getInstance().axes(attacker))
|
||||
PPa.addAxesXP((event.getDamage() * 3) * LoadProperties.pvpxprewardmodifier);
|
||||
if(m.isSwords(attacker.getItemInHand()))
|
||||
if(m.isSwords(attacker.getItemInHand()) && mcPermissions.getInstance().swords(attacker))
|
||||
PPa.addSwordsXP((event.getDamage() * 3) * LoadProperties.pvpxprewardmodifier);
|
||||
if(attacker.getItemInHand().getTypeId() == 0)
|
||||
if(attacker.getItemInHand().getTypeId() == 0 && mcPermissions.getInstance().unarmed(attacker))
|
||||
PPa.addUnarmedXP((event.getDamage() * 3) * LoadProperties.pvpxprewardmodifier);
|
||||
}
|
||||
}
|
||||
@ -148,7 +149,7 @@ public class Combat {
|
||||
{
|
||||
Player master = Taming.getOwner(eventb.getDamager(), pluginx);
|
||||
PlayerProfile PPo = Users.getProfile(master);
|
||||
|
||||
if(mcPermissions.getInstance().taming(master)){
|
||||
//Sharpened Claws
|
||||
if(PPo.getTamingInt() >= 750)
|
||||
{
|
||||
@ -173,6 +174,7 @@ public class Combat {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
//Another offensive check for Archery
|
||||
if(event instanceof EntityDamageByProjectileEvent)
|
||||
archeryCheck((EntityDamageByProjectileEvent) event);
|
||||
@ -195,7 +197,8 @@ public class Combat {
|
||||
{
|
||||
Player master = Taming.getOwner(event.getEntity(), pluginx);
|
||||
PlayerProfile PPo = Users.getProfile(master);
|
||||
|
||||
if(mcPermissions.getInstance().taming(master))
|
||||
{
|
||||
/*
|
||||
* TEMPORARY FIX AS WOLVES AREN'T TRIGGERING DAMAGE EVENTS WHEN ATTACKING NON PLAYERS AT THE TIME OF WRITING
|
||||
*/
|
||||
@ -216,6 +219,7 @@ public class Combat {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static void combatAbilityChecks(Player attacker, PlayerProfile PPa, Plugin pluginx)
|
||||
{
|
||||
|
@ -50,6 +50,15 @@ public class mcEntityListener extends EntityListener {
|
||||
public void onEntityDamage(EntityDamageEvent event) {
|
||||
if(event.isCancelled())
|
||||
return;
|
||||
/*
|
||||
* CHECK FOR mcMMO PVP FLAG
|
||||
*/
|
||||
if(event instanceof EntityDamageByEntityEvent)
|
||||
{
|
||||
EntityDamageByEntityEvent eventb = (EntityDamageByEntityEvent)event;
|
||||
if(eventb.getEntity() instanceof Player && eventb.getDamager() instanceof Player && !LoadProperties.pvp)
|
||||
return;
|
||||
}
|
||||
/*
|
||||
* CHECK FOR INVULNERABILITY
|
||||
*/
|
||||
|
@ -1,3 +1,3 @@
|
||||
name: mcMMO
|
||||
main: com.gmail.nossr50.mcMMO
|
||||
version: 1.0.04
|
||||
version: 1.0.05
|
Loading…
Reference in New Issue
Block a user