+ // @returns Element(Boolean) + // @description + // Returns true if the player is a vampire. + // @Plugin DepenizenBukkit, Vampire + // --> + if (attribute.startsWith("is_vampire")) { + return new Element(uPlayer.isVampire()).getAttribute(attribute.fulfill(1)); + } + + // <--[tag] + // @attribute
+ // @returns Element(Boolean) + // @description + // Returns true if the player is infected. + // @Plugin DepenizenBukkit, Vampire + // --> + if (attribute.startsWith("is_ínfected")) { + return new Element(uPlayer.isInfected()).getAttribute(attribute.fulfill(1)); + } + + // <--[tag] + // @attribute
+ // @returns Element(Double) + // @description + // Returns the value of the combat infection risk. + // @Plugin DepenizenBukkit, Vampire + // --> + if (attribute.startsWith("combat_infect")) { + return new Element(uPlayer.combatInfectRisk()).getAttribute(attribute.fulfill(1)); + } + + // <--[tag] + // @attribute
+ // @returns Element(Double) + // @description + // Returns the value of the combat damage factor. + // @Plugin DepenizenBukkit, Vampire + // --> + if (attribute.startsWith("combat_damage")) { + return new Element(uPlayer.combatDamageFactor()).getAttribute(attribute.fulfill(1)); + } + + return null; + } +} diff --git a/bukkit/src/main/java/com/denizenscript/depenizen/bukkit/support/plugins/VampireSupport.java b/bukkit/src/main/java/com/denizenscript/depenizen/bukkit/support/plugins/VampireSupport.java new file mode 100644 index 000000000..2a445660e --- /dev/null +++ b/bukkit/src/main/java/com/denizenscript/depenizen/bukkit/support/plugins/VampireSupport.java @@ -0,0 +1,11 @@ +package com.denizenscript.depenizen.bukkit.support.plugins; + +import com.denizenscript.depenizen.bukkit.extensions.vampire.VampirePlayerExtension; +import com.denizenscript.depenizen.bukkit.support.Support; +import net.aufdemrand.denizen.objects.dPlayer; + +public class VampireSupport extends Support { + public VampireSupport() { + registerProperty(VampirePlayerExtension.class, dPlayer.class); + } +} diff --git a/bukkit/src/main/resources/lib/Vampire.jar b/bukkit/src/main/resources/lib/Vampire.jar new file mode 100644 index 000000000..b4459814e Binary files /dev/null and b/bukkit/src/main/resources/lib/Vampire.jar differ diff --git a/bukkit/src/main/resources/plugin.yml b/bukkit/src/main/resources/plugin.yml index 453abf71f..28c9395f2 100644 --- a/bukkit/src/main/resources/plugin.yml +++ b/bukkit/src/main/resources/plugin.yml @@ -3,7 +3,7 @@ authors: ['Morphan1', 'DenizenScript team'] version: ${project.version} (build ${BUILD_NUMBER}) main: com.denizenscript.depenizen.bukkit.DepenizenPlugin depend: [Denizen] -softdepend: [mcMMO, BattleNight, Towny, Factions, Votifier, Jobs, Heroes, pvparena, WorldEdit, WorldGuard, Essentials, pvpstats, HyperConomy, SkillAPI, Prism, TerrainControl, PlotMe, PlotSquared, SimpleClans, MobArena, ASkyBlock, NoCheatPlus, MythicMobs, Sentinel, Shopkeepers, GriefPrevention, Quests, PlaceholderAPI, Residence, dtlTraders, AreaShop, LibsDisguises, OpenTerrainGenerator, PlayerPoints, LuckPerms, EffectLib, BossShop] +softdepend: [mcMMO, BattleNight, Towny, Factions, Votifier, Jobs, Heroes, pvparena, WorldEdit, WorldGuard, Essentials, pvpstats, HyperConomy, SkillAPI, Prism, TerrainControl, PlotMe, PlotSquared, SimpleClans, MobArena, ASkyBlock, NoCheatPlus, MythicMobs, Sentinel, Shopkeepers, GriefPrevention, Quests, PlaceholderAPI, Residence, dtlTraders, AreaShop, LibsDisguises, OpenTerrainGenerator, PlayerPoints, LuckPerms, EffectLib, BossShop, Vampire] commands: depenizen: