net.aerith.misao.util
Class SightScope

java.lang.Object
  |
  +--net.aerith.misao.util.SightScope

public class SightScope
extends java.lang.Object

The SightScope represents a sight scope which consists of the base position angle and the range of the scope.


Field Summary
protected  double base_angle
          The base position angle.
protected  double range
          The range of the scope.
 
Constructor Summary
SightScope()
          Constructs an empty SightScope.
SightScope(double base_angle, double range)
          Constructs a SightScope with specified sight scope.
 
Method Summary
 boolean inRange(double angle)
          Judges if the specified angle is within this sight scope.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

base_angle

protected double base_angle
The base position angle.

range

protected double range
The range of the scope.
Constructor Detail

SightScope

public SightScope()
Constructs an empty SightScope.

SightScope

public SightScope(double base_angle,
                  double range)
Constructs a SightScope with specified sight scope.
Parameters:
base_angle - the base position angle.
range - the range of angle.
Method Detail

inRange

public boolean inRange(double angle)
Judges if the specified angle is within this sight scope.
Parameters:
angle - the angle.
Returns:
true if the specified angle is within this sight scope.