OGS Java API Spec

ogs.magic
Class LevelRange

java.lang.Object
  |
  +--ogs.magic.Range
        |
        +--ogs.magic.AbsoluteRange
              |
              +--ogs.magic.LevelRange

public class LevelRange
extends AbsoluteRange

An absolute range that is based on caster level. Level-based spell ranges have formulas for automatically determining the absolute distance.


Field Summary
 
Fields inherited from class ogs.magic.Range
ABSOLUTE, CLOSE, LONG, MEDIUM, PERSONAL, TOUCH, UNLIMITED
 
Method Summary
static LevelRange Close(int casterLevel)
          Create a new Close spell range.
 int getCasterLevel()
          Determine the caster level for this range.
static LevelRange Long(int casterLevel)
          Create a new Long spell range.
static LevelRange Medium(int casterLevel)
          Create a new Medium spell range.
 
Methods inherited from class ogs.magic.AbsoluteRange
Absolute, getDistance
 
Methods inherited from class ogs.magic.Range
getType, Personal, Touch, Unlimited
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

Close

public static LevelRange Close(int casterLevel)
Create a new Close spell range. At Close spell range, the distance is 25 feet + 5 feet for every 2 caster levels.

Parameters:
casterLevel - Experience level of spell caster.
Returns:
Close spell range.

Medium

public static LevelRange Medium(int casterLevel)
Create a new Medium spell range. At Medium spell range, the distance is 100 feet + 10 feet per caster level.

Parameters:
casterLevel - Experience level of spell caster.
Returns:
Medium spell range.

Long

public static LevelRange Long(int casterLevel)
Create a new Long spell range. At Long spell ranges, the distance is 400 feet + 40 feet per caster level.

Parameters:
casterLevel - Experience level of spell caster.
Returns:
Long spell range.

getCasterLevel

public int getCasterLevel()
Determine the caster level for this range.

Returns:
Caster level.

OGS Java API Spec