Code Monkey home page Code Monkey logo

hex2d-rs's Introduction

hex2d

Build Status crates.io Gitter Chat
Documentation

Introduction

Library for working with 2d hex map systems.

A lot of ideas taken from redbloggames hexagon page

Read Documentation for details.

See issues for TODO and BUGs.

You might be interested in additional functionality provided by hex2d-dpcext-rs library.

Coordinate system

Pointy-topped:

          /\
        /    \
       |      |
       |      |
        \    /
          \/

          -z
+y     YZ  |  XZ     +x
 ---       |       ---
    ---    |    ---
       --- | ---
  YX      -x-    XY
       --- | ---
    ---    |    ---
 ---   ZX  |  ZY   ---
-x         |          -y
          +z

Flat-topped:

         ____
        /    \
       /      \
       \      /
        \____/

     +y       -z
      \       /
       \ YZ  /
    YX  \   /  XZ
         \ /
-x--------x--------+x
         / \
    ZX  /   \ XY
       /  ZY \
      /       \
     +z       -y

Building

cargo build

Verification Recommendation

To help with the maintaince, the ownership of this crate is potentially shared between multiple developers. It is recommended to always use cargo-crev to verify the trustworthiness of each of your dependencies, including this one.

hex2d-rs's People

Contributors

dpc avatar serprex avatar rardiol avatar beatgammit avatar thezalli avatar afck avatar kvark avatar vadixidav avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.