1

Aimed Hit - Server Plugin

TheDarthFather's Avatar TheDarthFather2/6/17 5:34 am
1 emeralds 589 4
2/16/2017 11:20 am
Pepijn's Avatar Pepijn
Initially I created this plugin for my kids & friends on our white-listed server.
As I added more features, it become quite big and fun to use, so I decided to share it.
I am not counting on plugin development as an income source. I do not plan to make this a premium resource.
Enjoy!

Aimed Hit
Official Page here. If you like it, don't forget to leave a nice review!

Identifies the body-part where the attacker hits (melee or ranged) a target (Player or Mob) and applies different damage, potion effects, send messages, run commands, play sounds.

Head-shots can do double damage and dizzy the enemies, Leg-shots can slow-down the enemies!
You can even make head-shots to instantly kill, if the target does not have a helmet!
All customized in the config file!


Features

Aimed Hits:
· Head, Body, Arms & Legs
· Damage adjuster
· Target & Attacker Customized Effects
· Target & Attacker Messages (Chat or Action bar)
· Commands & Sounds​

PvP, PvE & EvP:
· Make PvP and/or PvE more fun?
· Or … make EvP more fun and allow mobs to use the AimedHit system when attacking players!
· Additional damage adjusters for each of them (PvP, PvE, EvP) for extra granularity.
· Any of them can be enabled/disabled from config·
· NoHelmetGetsYouKilled: Enabled/Disabled for PvP or PVE

Melee & Ranged:
· Can chose the type of damage that can benefit from AimedHits (Projectile, Entity_Attack .. or even falling damage)
· Can limit even more, by restricting the weapon used
· Any of them can be enabled/disabled from config

All types of mobs:
· Enable or disable mobs as you see fit
· Change the hit-box setup for each of them if my defaults don’t fit your needs.
· …. Including custom made mobs (eg Mythic Mobs)
· See Limitations*

Multiworld support.

WordGuard and GriefPrevention support

Permissions: You can limit the usage based on permissions

Debug: Check the reason why a AimedHit did not trigger for that target and adjust the config.


Installation

· Copy AimedHit.jar to your plugin folders
· Restart your server
· Enjoy!
· Optional: Open the config file and adjust the settings based on your needs.


Permissions

aimedhit.use
· Allows a player to use AimedHit.
· This is disabled in the config. Enable it there if you want to make use of the permission restriction.​

aimedhit.admin
· Allows a player to use the aimedhit commands​


Commands

/ffah reload
· Reloads the config file without restarting the server
· Sets Debug to Off.

/ffah debug
· Shows extra information to the Attackers including the reason why the shot did not trigger AimedHit in that case (eg: no PVP in WorldGuard, distance too short for projectile, mob disabled in config )
· This is a “global” setting. If you enable it, it will show the extra information to the ALL the Attackers with the aimedhit.admin permission.


[color=#0000FF][b]Setup/Configuration[/color]
[/b]
See the config file below. Everything should be self-explanatory.
[code]
# AimedHit by TheDarthFather

# Need help ? Link below:
# github.com/TheDarthFather/AimedHit/issues

# ---------------------------------------------------------------------------------------------------------------------------------------------------
# VARIBLES
# %Target
# %Attacker
# %BonusDamage
# %TotalDamage
# ---------------------------------------------------------------------------------------------------------------------------------------------------

# ---------------------------------------------------------------------------------------------------------------------------------------------------
# RESOURCES
# SOUNDS
# - hub.spigotmc.org/javadocs/spigot/org/bukkit/Sound.html
# DAMAGE CAUSE
# - hub.spigotmc.org/javadocs/spigot/org/bukkit/event/entity/EntityDamageEvent.DamageCause.html
# ITEM NAMES
# - www.minecraft-servers-list.org/id-list/
# POTION EFFECT
# - hub.spigotmc.org/javadocs/spigot/org/bukkit/potion/PotionEffectType.html
# ---------------------------------------------------------------------------------------------------------------------------------------------------


# < CONFIG ------------------------------------------------------------------------------------------------------------------------------------------

# PerWorld activation -------------------------------------------------------------------------------------------------------------------------------
# - False -> active for all the worlds
# - True -> active for listed worlds

MultiWorld:
UsePerWorlds: false
Worlds:
- world
- AnotherWorld

# General setup -------------------------------------------------------------------------------------------------------------------------------------

General:

# EnablePlayerVsPlayer: true
# AimedHit applies when a Player hits another Player (PvP). Default: true
EnablePlayerVsPlayer: true

# EnablePlayerVsMob: true
# AimedHit applies when a Player hits a Mob (PvE). Default: true
EnablePlayerVsMob: true

# EnableMobsVsPlayer: true
# AimedHit applies when a Mob hits a Player (EvP). Default: true
EnableMobsVsPlayer: true

# EnabledDamageCause: PROJECTILE, ENTITY_ATTACK
# AimedHit applies when the cause of the attack is listed as specified. Default PROJECTILE (eg arrows, snow_balls), ENTITY_ATTACK (Melee)
# hub.spigotmc.org/javadocs/spigot/org/bukkit/event/entity/EntityDamageEvent.DamageCause.html
EnabledDamageCause: PROJECTILE, ENTITY_ATTACK

# ProjectileMinDistance: 5
# Limits the distance AimedHit works for projectiles. Default 5.
ProjectileMinDistance: 5

# EnableAllowedWeaponList: false
# If true: The effects will apply only if the Attacker is using one of the Weapons/Items below (Allowed Weapons). Default: false
EnableAllowedWeaponList: false

# AllowedWeapons: BOW,SNOW_BALL,IRON_SWORD,DIAMOND_SWORD
# Add/Delete Minecraft Item names in the list to limit the weapons that can be used
# www.minecraft-servers-list.org/id-list/
AllowedWeapons: BOW,SNOW_BALL,IRON_SWORD,DIAMOND_SWORD

# NoHelmetGetsYouKilled: false
# If True: If the target doesn't have a helmet one head-shot will kill it. Default: false
NoHelmetGetsYouKilled: false

# NoHelmetRuleAppliesForMobs: false
# If True: Applies the above "NoHelmet rule" when a player hits a Mobs .... !!! True will make Headshots OP in PvE. Default: false
NoHelmetRuleAppliesForMobs: false

# UsePermissions: false
# If True: AimedHit will work only for the players with aimedhit.use permission. Default: false
UsePermissions: false

# ActionBarMessage: true
# If false, the players will receive the messages in chat.
ActionBarMessage: true

# Effect Setup --------------------------------------------------------------------------------------------------------------------------------------
# - Damage is given as % to the base damage (eg 1.2 means 120%)
# - TargetEffect / AttackerEffect: %Probability, Effect, Duration, Level
# EFFECTS: hub.spigotmc.org/javadocs/spigot/org/bukkit/potion/PotionEffectType.html
# - TargetMessage / AttackerMessage: Message received by Target/Attacker
# - Command: Any server command (eg: give %Attacker log 1)
# - Sound: hub.spigotmc.org/javadocs/spigot/org/bukkit/Sound.html

Effects:
Head:
Damage: 1.5
TargetEffect: 75,CONFUSION,200,1;
AttackerEffect: 100,Glowing,300,1;20,Speed,300,1;
AttackerMessage: '&6[AimedShot] You have hit &4%Target &6in the Head for extra damage %TotalDamage (+%BonusDamage) and also he might become confused!.'
TargetMessage: '&4[AimedShot] You have been hit by %Attacker in the Head for extra damage %TotalDamage (+%BonusDamage)! You may also feel dizzy!'
Command:
Sound: ENTITY_PLAYER_LEVELUP
Body:
Damage: 0.8
TargetEffect: 50,WEAKNESS,100,1;50,SLOW,200,1;
AttackerEffect:
AttackerMessage: '&6[AimedShot] You have hit &4%Target &6in the Body for less damage %TotalDamage (%BonusDamage), but he might become weaker and slower!'
TargetMessage: '&4[AimedShot] You have been hit by %Attacker in the Body for less damage %TotalDamage (%BonusDamage), and you also may hit weaker and become slower!'
Command:
Sound: ITEM_ARMOR_EQUIP_GOLD
Arms:
Damage: 0.5
TargetEffect: 75,WEAKNESS,200,1;10,SLOW,200,1;
AttackerEffect: 10,Speed,300,1;
AttackerMessage: '&6[AimedShot] You have hit &4%Target &6in the Arm for less damage %TotalDamage (%BonusDamage), but he might become weaker and slower!'
TargetMessage: '&4[AimedShot] You have been hit by %Attacker in the Arm for less damage %TotalDamage (%BonusDamage), but you also may hit weaker and become slower!'
Command:
Sound: BLOCK_WOOD_BREAK
Legs:
Damage: 0.5
TargetEffect: 75,SLOW,200,1;
AttackerEffect: 30,Speed,300,1;
AttackerMessage: '&6[AimedShot] You have hit &4%Target &6in the leg for less: %TotalDamage (%BonusDamage), but he walks slower!'
TargetMessage: '&4[AimedShot] You have been hit by %Attacker in the leg for less damage %TotalDamage (%BonusDamage), but you also may walk slower!'
Command:
Sound: BLOCK_GRAVEL_STEP

# DamageAdjusters -----------------------------------------------------------------------------------------------------------------------------------
# - The damage adjusters apply on top of the damage defined above, for the respective combination of Attacker and Target.
# - You can use this for a more granular damage setup/balancing, by raising or lowering a specific value. Defaults are 1.
# - EG: Setting the MobVSPlayer (EvP) values higher will make the PVE experience more difficult.

DamageAdjusters:
PvP:
Head: 1
Body: 1
Arms: 1
Legs: 1
PvE:
Head: 1
Body: 1
Arms: 1
Legs: 1
EvP:
Head: 1
Body: 1
Arms: 1
Legs: 1

# Entity data ---------------------------------------------------------------------------------------------------------------------------------------
# - Do not modify unless you know what you are doing !!!!
# - You can adjust the size of the Head, Body, Arms by changing the values: HeadY, TorsoY, 1/2 Torso With (ArmsXZ).
# - Disable a specific entity by adding # in front
# - hub.spigotmc.org/javadocs/spigot/org/bukkit/entity/EntityType.html

Entities:

# Player, NPCs / Villagers

PLAYER: 1.38,0.80,0.26
EVOKER: 1.38,0.80,0.26
VILLAGER: 1.38,0.80,0.26

# Zombie Mobs

ZOMBIE: 1.49,0.80,0.26
ZOMBIE_CHILD: 0.75, 0.40,0.13
HUSK: 1.49,0.80,0.26
ZOMBIE_VILLAGER: 1.49,0.80,0.26
PIG_ZOMBIE: 1.49,0.80,0.26

# SKELETON Mobs

SKELETON: 1.44,0.85,0.29
WITHER_SKELETON: 1.44,0.85,0.29
STRAY: 1.44,0.85,0.29

# Other Mobs

GIANT: 10.00,7.40,5.80
IRON_GOLEM: 2.17.0.90,0.67
ENDERMAN: 2.35,1.62,0.28
WITCH: 1.37,0.75,0.30
VEX: 0.60,0.40,0.12
WITHER: 2.46,0.00,0.64

# NoArms Mobs (Y, Y, 99.00)
SHEEP: 0.72,0.46,99.00
LLAMA: 1.33,0.62,99.00
DONKEY: 1.00,0.45,99.00
COW: 0.75,0.60,99.0
PIG: 0.22,0.22,99.00
MUSHROOM_COW: 0.79,0.79,99.00
ZOMBIE_HORSE: 1.20,0.5,99.00
SKELETON_HORSE: 1.20,0.5,99.00
HORSE: 1.20,0.5,99.00
MULE: 1.05,0.50,99.00
SNOWMAN: 1.24,0.65,99.00
CREEPER: 1.20,0.40,99.00
BLAZE: 1.22,0.00,99.00

# HEAD & BOX Mobs (X, 00.00, 99.00) - DISABLE them if this does not fit your play-style!
# - Head: 0.05 - most of the hits will return as a Head shot, the rest will count as body
# - Head: 1-4 - most of the hits will return as a Body shot, the rest will count as Head
# - Body: 0.00 - no Leg Shots
# - Arms: 99.00 - no Arm Shots

CAVE_SPIDER: 0.05,0.00,99.00
SPIDER: 0.05,0.00,99.00
RABBIT: 0.05,0.00,99.00

GUARDIAN: 0.05,0.00,99.00
ELDER_GUARDIAN: 0.05,0.00,99.00

POLAR_BEAR: 0.01,0.01,99.00
WOLF: 0.01,0.01,99.00
OCELOT: 0.01,0.01,99.00

GHAST: 4.00,0.00,99.00
MAGMA_CUBE: 1.00,0.00,99.00
SLIME: 1.00,0.00,99.00
SQUID: 0.00,0.00,99.00
SHULKER: 0.57,0.00,99.00

# Disabled Mobs (Usually very small or atypical mobs)
# - remove leading # to make them available

# SILVERFISH: 00.01,0.00,99.00
# BAT: 0.01,0.00,0.06
# ENDERMITE: 0.01,0.00,99.00
# CHICKEN: 0.46,0.32,99.00

# ENDER_DRAGON - horizontal flying mob - not clear what body size to use.
# ENDER_DRAGON: 0.00,0.00,0.00

# CONFIG > ------------------------------------------------------------------------------------------------------------------------------------------
[/code]
Posted by TheDarthFather's Avatar
TheDarthFather
Level 1 : New Crafter
0

Create an account or sign in to comment.

4

info Note: You're viewing a single reply. View all replies
1
02/16/2017 11:20 am
Level 57 : Grandmaster Cyborg
Pepijn
Pepijn's Avatar
Looks pretty cool. Why not upload it to PMC as well ?
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome