Skip to content

EnumFacing & EnumDirection8 #718

Closed
Closed

Description

@kashike

net.minecraft/util/EnumFacing -> net.minecraft/util/Direction
net.minecraft/util/EnumDirection8 -> net.minecraft/util/Direction8

Activity

  1. ChloeDawn commented on Sep 2, 2018

    @ChloeDawn

    I'd suggest CompassDirection over Direction8, as it is more explicit about the contents of the enum class. Direction8 provides no context to the fact that the enum class only holds horizontal directions.

  2. williewillus commented on Sep 2, 2018

    @williewillus
    Contributor

    but Compass doesn't imply 8 either, for all I know it could just be the 4 cardinal directions

  3. tterrag1098 commented on Sep 2, 2018

    @tterrag1098
    Collaborator

    There is no good word to imply all 8 cardinal and ordinal directions, I think "compass" is as close as you can get. It's not hard to just look at the class and see what constants are defined, nor is it a stretch to think that a compass direction enum would include ordinal directions.

  4. pau101 commented on Sep 2, 2018

    @pau101

    These two classes shouldn't share much in common with their names. The EnumFacing type includes vertical directions while EnumDirection8 does not, but more generally, the behavior they offer is completely different, therefore warranting differentiation between them beyond the abstract concept of "direction". The referral to EnumFacing as Direction is reasonable given those are general directions with vector functionality, while for EnumDirection8, I propose CompassPoint.

  5. williewillus commented on Sep 3, 2018

    @williewillus
    Contributor

    hmm, I'd almost say I prefer CompassDirection over CompassPoint, Direction is more accurate than Point imo (I'd have to see usages though)

  6. Pokechu22 commented on Sep 3, 2018

    @Pokechu22

    Wiktionary has an article for compass point, but not for compass direction. But, I feel direction is a bit more obvious... so, no strong opinion between the two.

    EDIT: all pages starting with compass, for reference.

  7. pau101 commented on Sep 3, 2018

    @pau101

    @williewillus "Point" is used explicitly for the avoidance of "Direction", as comment argued.

  8. added this to the 1.14.0 milestone on Sep 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions