Skip to content

LockAndBan: Vehicles #2958

@MeFisto94

Description

@MeFisto94

Is your feature request related to a problem?

Especially in AcidIslands, the handling of vehicles (boats) isn't perfect, as it will teleport players away but not cleaning up the boat, leaving orphaned boats in areas that can't be regained (as they are on locked territory)

Describe the solution you'd like.

I am not sure about a good solution, but I've noticed that LockAndBanListener#onVehicleMove appears to be a bit inconsistent: It first teleports the player to Event#getFrom but then also teleports them home. If we were to mirror the move event, we'd only do the latter if they were denied from From too.

Ideally, we'd have something analogous to cancelling the PlayerMoveEvent. Either by teleporting the vehicle back or by applying a physics force (more risky probably and probably also needs more code, e.g. depending on how far we penetrate, we still need a teleport back).

The problem is the handling if there are multiple players part of the vehicle, there, we'd only push back if all are denied, otherwise, we'd indeed need to send the player home or decide that the whole vehicle can't enter then.

What are your toughts?

Describe alternatives you've considered.

At least have the vehicle also be teleported to Event#getFrom so that it is semi-recoverable as it isn't on locked territory anymore.

Agreements

  • I have searched for and ensured there isn't already an open issue regarding this.
  • I have ensured the feature I'm requesting isn't already in the latest supported BentoBox build or Addons.

Other

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels
    No fields configured for Feature.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions