Turrets Tutorial: Properties

In this page you will find all properties of turret configuration files. Remember that you can create as many turrets you want by just creating a new file and then reloading the plugin using /ct reload.

Alias

This will be the name of the turret, used mainly for messages.

alias: "Burst Turret"

Structure

The structure defines the blocks of the turret. The last line of the list is the first block below. You need to use valid Material names. You can add more lines to make the turret taller. 1.16 Materials: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html 1.8 Materials: https://github.com/Attano/Spigot-1.8/blob/master/org/bukkit/Material.java You can also use heads with textures from this website: https://minecraft-heads.com/custom-heads Just write the Value property of the head.

structure:
  - "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvZDc4YzFiZDliMzQwZmIzODdjMTNiOGI2ZDdhNzUxYzM4NDY2OTI2MmIyNWM2NGJkMjg1YzQ2MzBlZWY0ZmEifX19"
  - "CYAN_CONCRETE"
  - "COAL_BLOCK"

Shoot Type

Currently there are 2 shoot types: INSTANT and PARABOLIC. To check the differences, compare Burst and Siege, both default turrets. Burst has a INSTANT shoot and Siege has a PARABOLIC shoot.

shoot_type: INSTANT

Target

Currently there are 2 target types: ENEMIES and ALLIES. If target is set to ENEMIES, the turret anything. If target is set to ALLIES, the turret will shoot only allies of the player (Whitelisted players, tamed animals, allied players from other plugins). When Target is set to ALLIES remember to make the turret heals entities instead of damage them (by using min_heal and max_heal instead of min_damage and max_damage in turret upgrades)

target: ENEMIES

Require Ammunition

If this option is set to true, players will need to add ammo to their turrets to start shooting. If set to false, the whole Ammunition inventory will not be available for this turret.

require_ammunition: true

Health Recovery

If the turret has health, this is the amount of health the turret will recover at the period of time defined in the config.yml file.

health_recovery: 10

Activation Delay

This will add an activation delay/cooldown (in seconds) to the turret when placed, meaning the turret will not start shooting until the delay is over.

activation_delay: 30

Shoot Through Liquids

Should the turret be able to shoot through liquids?

shoot_through_liquids: true

Min Attack Distance

The minimum attack distance in blocks. If not set, the default value will be 2

min_attack_distance: 6

Hologram Vertical Offset

If information holograms above turrets are not being displayed correctly, you can use this option to increase or decrease its height by a certain value.

hologram_vertical_offset: 0.25

Default Options

Here you can define some default options for the turret. Players with the correct permissions are allowed to change these options in the turret inventory.

default_options:
    attack_players: false
    attack_monsters: true
    attack_animals: false
    
    # If set to true it will attack: VILLAGERS, IRON_GOLEMS, SNOWMANS
    attack_others: false
    
    # The attack priority of the turret. It could be CLOSEST or HEALTH.
    # CLOSEST will allow the turret to shoot always the closest entity in range.
    # HEALTH will allow the turret to shoot entities with lower health first.
    priority: CLOSEST
    
    # Whether the turret will enable immediately when created.
    enabled: true

Effects

There are 2 types of effects. Shoot effect and impact effect. Shoot effect will be displayed from the turret and impact effect on the target location. A turret could have just shoot effect or both.

effects:
    # Particle effect displayed from the turret
    shoot_effect:
      # The sound to play. If is shoot_effect, it will play in the turret 
      # location, if is impact_effect, it will play in the target location.
      # Use this format: <sound>;<volume>;<pitch>
      # 1.16 Sounds: 
      # https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Sound.html
      # 1.8 Sounds: 
      # https://github.com/Attano/Spigot-1.8/blob/master/org/bukkit/Sound.java
      sound: ENTITY_FIREWORK_ROCKET_BLAST;1;1.7
      
      # ONLY WORKS FOR INSTANT SHOOT TYPE.
      # This defines the separation (in blocks) between each particle effect.
      separation: 0.3
      
      # ONLY WORKS FOR INSTANT SHOOT TYPE.
      # This defines the amount of particle effects to
      # display. If separation is set to 1 and amount is set to 5
      # it means a particle will be displayed 1 block from the turret,
      # another particle will be displayed 2 blocks from the turret, and so on.
      amount: 5
      
      # ONLY WORKS FOR PARABOLIC SHOOT TYPE.
      # Increase this value if you want more particle
      # effects to be displayed, with less separation.
      parabolic_separation: 35
      
      # ONLY WORKS FOR PARABOLIC SHOOT TYPE
      # This is the speed in seconds between showing 
      # particles. Decrease if you want the projectile to
      # be faster. Minimum limit is 0.05.
      parabolic_speed: 0.05
      
      # Both shoot_effect and impact_effect have a list_of_effects 
      # where you can define multiple particles to be displayed.
      list_of_effects:
        effect1:
          # The particle to display.
          # 1.16 Particles: 
          # https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Particle.html
          # 1.8 Particles: 
          # https://github.com/Attano/Spigot-1.8/blob/master/net/minecraft/server/v1_8_R3/EnumParticle.java
          # If you want to use a colored redstone particle you need to 
          # follow this format:
          # particle: REDSTONE;<color>
          # You can found all minecraft color values here: 
          # https://minecraftcommand.science/armor-color
          particle: CRIT
          
          # Don't confuse it with speed of the shoot.
          # This is the particle speed, set it to 0.01 if you want 
          # the particle to be static.
          speed: 0.01
          
          # These options will add a translation to the particle.
          offset_horizontal: 0.25
          offset_vertical: 0.1
        effect2:
          particle: CRIT
          speed: 0.01
          offset_horizontal: -0.25
          offset_vertical: 0.1
    impact_effect:
      sound: ENTITY_GENERIC_EXPLODE;1;0.4
      list_of_effects:
        effect1:
          particle: EXPLOSION_LARGE
          speed: 1

Here is an example of what you can accomplish with the offset_horizontal option.

Last updated