|
Breakout Problem Set Javadocs | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbreakout.DefaultBreakoutComponent
breakout.Wall
A Wall is an unkillable component used to edge in the World and prevent balls from escaping.
World
Constructor Summary | |
Wall(java.awt.Point location,
java.awt.Dimension size,
World w)
|
Method Summary | |
void |
hitBy(BreakoutComponent striker)
Walls do nothing when struck. |
void |
kill()
overridden to prevent Walls from getting killed. |
void |
paint(java.awt.Graphics g)
Walls render as white rectangles of the appropriate size |
Methods inherited from class breakout.DefaultBreakoutComponent |
getCenter, getLocation, getShape, getSize, isDead, isTransient, setLocation, setWorld |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Wall(java.awt.Point location, java.awt.Dimension size, World w)
Method Detail |
public void kill()
kill
in interface BreakoutComponent
kill
in class DefaultBreakoutComponent
public void paint(java.awt.Graphics g)
paint
in interface BreakoutComponent
paint
in class DefaultBreakoutComponent
g
- Graphics used to render Wall.public void hitBy(BreakoutComponent striker)
hitBy
in interface BreakoutComponent
hitBy
in class DefaultBreakoutComponent
striker
- BreakoutComponent rebounding off wall
|
Breakout Problem Set Javadocs | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |