com.robrohan.ruin.doom
Class Linedef

java.lang.Object
  |
  +--com.robrohan.ruin.doom.Linedef
All Implemented Interfaces:
java.io.Serializable

public class Linedef
extends java.lang.Object
implements java.io.Serializable

Each linedef represents a line from one of the VERTEXES to another. "right" and "left" are based on the direction of the linedef as indicated by the "from" and "to", or "start" and "end", VERTEXES. This sketch should make it clear: left side right side start -----------------> end <----------------- start right side left side IMPORTANT: All lines must have a right side. If it is a one-sided line, then it must go the proper direction, so its single side is facing the sector it is part of. DOOM will crash on a level that has a line with no right side.

See Also:
Serialized Form

Constructor Summary
Linedef(int fromVertex, int toVertex, int rightSidedefNo, int leftSidedefNo, int flags)
           
 
Method Summary
 boolean blocksMonsters()
           
 boolean blocksSound()
           
 void compile(DoomLevel level)
           
 int getFromVertex()
          get the id of the from vertex from to +===============+
 int getId()
          get this linedefs current id
 Sidedef getLeftSidedef()
           
 Sidedef getRightSidedef()
           
 int getToVertex()
          get the id of the to vertex from to +===============+
 boolean isAlreadyOnMap()
           
 boolean isImpassible()
           
 boolean isLowerUnpegged()
           
 boolean isNotOnMap()
           
 boolean isSecret()
           
 boolean isTwoSided()
           
 boolean isUpperUnpegged()
           
 void setId(int id)
          set the id for this linedef
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Linedef

public Linedef(int fromVertex,
               int toVertex,
               int rightSidedefNo,
               int leftSidedefNo,
               int flags)
Method Detail

getFromVertex

public int getFromVertex()
get the id of the from vertex from to +===============+


getToVertex

public int getToVertex()
get the id of the to vertex from to +===============+


getRightSidedef

public Sidedef getRightSidedef()

getLeftSidedef

public Sidedef getLeftSidedef()

compile

public void compile(DoomLevel level)

isImpassible

public boolean isImpassible()

blocksMonsters

public boolean blocksMonsters()

isTwoSided

public boolean isTwoSided()

isUpperUnpegged

public boolean isUpperUnpegged()

isLowerUnpegged

public boolean isLowerUnpegged()

isSecret

public boolean isSecret()

blocksSound

public boolean blocksSound()

isNotOnMap

public boolean isNotOnMap()

isAlreadyOnMap

public boolean isAlreadyOnMap()

setId

public void setId(int id)
set the id for this linedef


getId

public int getId()
get this linedefs current id