What is a good data structure for storing and searching 2d spatial coordinates in Java

后端 未结 3 1728
清酒与你
清酒与你 2021-02-07 16:03

I am currently writing a plugin for a game where one feature includes the ability to set areas defined by 2 two dimensional coordinates ( The upper left and lower right areas of

3条回答
  •  天命终不由人
    2021-02-07 16:41

    To implement coordinates you can use Point2D in a class that implements the functionality you're looking for:

    http://download.oracle.com/javase/6/docs/api/java/awt/geom/Point2D.html

提交回复
热议问题