Skip to content

/npc lookclose: Option to set a total range for the NPC's head and body rotation #2782

@Andre601

Description

@Andre601

I confirm that I have ...

  • ...tried the latest Development Build to make sure my feature doesn't exist already.
  • ...checked the Wiki for any possible information about my feature.
  • ...checked other existing issues for my feature request.

Description

NPCs with lookclose enabled are currently rotating their heads and bodies in a 360° range, which may look weird when f.e. a wall is between you and the NPC, yet the NPC looks straight at you through that wall.

My proposal is to add an optional set of arguments to the /npc lookclose command to apply a "range" to the NPCs lookclose attribute.
With this applied, would the NPC only rotate the head up to a certain point at which it would stop.

Quick Example:
Assuming that the command would use Minecraft's YAW values for the range and that -180° is cardinal north in MC, using a
command such as /npc lookclose -135 -225 would now make the NPC rotate its head between -135° and -225°

Here's a visual representation of the area the NPC's head would be rotating in:
2022-04-05_21 29 59

The most difficult thing I can assume is to know in what directions the NPC should rotate its head.
So perhaps three arguments would be required for a left, middle and right yaw to guarantee it doesn't assume a completely wrong direction (i.e. a direction of 0 to -180 wouldn't assume a direction through -270 when a rotation through -90 is wanted).

Code Example

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Feature RequestA suggestion for a feature to develop.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions