Packages

class StarCoords extends AnyRef

A StarCoords object describes the location of a star on a two-dimensional star map. A location consists of two components, x and y, each of which has a value between -1.0 and +1.0. The x coordinate ranges from -1.0 at the very left of the map to +1.0 on the right; the y coordinate similarly ranges from -1.0 at the bottom to +1.0 at the top. For instance, a star with StarCoords of (0.0,0.0) appears at the exact center of the map.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. StarCoords
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new StarCoords(x: Double, y: Double)

    x

    the x coordinate of a location on the star map, between -1.0 and +1.0

    y

    the y coordinate of a location on the star map, between -1.0 and +1.0

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  6. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  7. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  8. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  9. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  10. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  11. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  13. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  14. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  15. def toImagePos(image: o1.Pic): world.Pos

    Converts this pair of star coords to the position (Pos) of a pixel within a given image (Pic).

    Converts this pair of star coords to the position (Pos) of a pixel within a given image (Pic). For instance, if this StarCoords represents the middle (0,0) of a star map, and a 400-by-400 pixel image is given, this method returns a Pos of (200,200). Another example: if this StarCoords is (-0.5,0.2) and the given image is a 1000-by-1000 pixel square, returns a Pos of (250,400).

  16. def toString: String

    Returns a string description of the star coords; e.g., "x=0.62, y=0.04".

    Returns a string description of the star coords; e.g., "x=0.62, y=0.04".

    Definition Classes
    StarCoords → AnyRef → Any
  17. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  18. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  19. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  20. val x: Double
  21. def xPercent: Double

    Returns a value between 0 and 1 that indicates how many percent from the left this location’s x coordinate is.

    Returns a value between 0 and 1 that indicates how many percent from the left this location’s x coordinate is. For example, 0.5 is halfway from the left.

  22. val y: Double
  23. def yPercent: Double

    Returns a value between 0 and 1 that indicates how many percent from the top this location’s y coordinate is.

    Returns a value between 0 and 1 that indicates how many percent from the top this location’s y coordinate is. For example, 0.25 is a quarter of the way down from the top.

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated @deprecated
    Deprecated

    (Since version ) see corresponding Javadoc for more information.

Inherited from AnyRef

Inherited from Any

Ungrouped