kernitus / BukkitOldCombatMechanics

Spigot plugin to configure combat mechanics for 1.9 onwards
https://www.spigotmc.org/resources/19510/
Mozilla Public License 2.0
179 stars 71 forks source link

Chorus fruits tp randomly inside blocks #748

Open Bafy78 opened 2 months ago

Bafy78 commented 2 months ago

Information

nothing interesting

chorus-fruit:
  # This makes the chorus fruit behaviour configurable
  enabled: true
  # The maximum distance the fruit can teleport the player. This a PER AXIS value, so this outlines a cube with
  # 2 * max-teleportation-distance as the side length
  # Vanilla default is 8.
  # Setting this to 0 disables chorus fruit teleport.
  # Setting this to a value greater than 8 MIGHT CAUSE CONFLICTS with bukkit's internal anti cheat
  # and *potentially* any other anti-cheat you use. Please make sure this is not an issue before increasing
  # this value.
  max-teleportation-distance: 5
  # Whether to prevent eating the fruit completely. This also prevents the teleportation.
  prevent-eating: false
  # The saturation value of the chorus fruit.
  # Vanilla default is 2.4
  saturation-value: 2.4
  # The hunger value of the chorus fruit.
  # Vanilla default is 4 (2 bars)
  hunger-value: 4

Problem Description

The chorus fruits, when the module is enabled, don't work properly at all and tp inside blocks.

To Reproduce

Steps to reproduce the behavior: 1. Enable the chorus fruits module 2. Change the teleportation distance value to anything other than the default (8) 3. Eat chorus fruits ### Expected Behaviour

You would be tped randomly above blocks in places where you can stand, in the radius

Actual Behaviour

You are tped anywhere, inside full blocks.

kernitus commented 1 month ago

Maybe some of the teleportation logic from NMS needs to be ported over. Can I ask what you use this module for? From the stats it seems most OCM servers have it disabled, and it would be helpful to figure out the best approach for this.

Bafy78 commented 1 month ago

I have a kitpvp server, and one of the kit (enderman) has chorus fruit as their main food source. I use the module to reduce the radius of possible teleportation, to make the chorus fruits less annoying for the user and less op to flee.