|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectvooga.examples.event.demo2.HumanKilledbyZombieEvent
public class HumanKilledbyZombieEvent
Class HumanKilledbyZombieEvent
implements the interface IEventHandler
to create
an event for the ZombieLand game.
There are two methods in HumanKilledbyZombieEvent
interface.
Please see actionPerformed()
, isTriggered()
.
Constructor Summary | |
---|---|
HumanKilledbyZombieEvent(Human human,
Zombie ghost)
Constructor. |
Method Summary | |
---|---|
void |
actionPerformed()
User defines what to do after event has been triggered. |
boolean |
isTriggered()
User defines the condition when the event will be triggered |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public HumanKilledbyZombieEvent(Human human, Zombie ghost)
human
- Human class objectghost
- Ghost class objectMethod Detail |
---|
public void actionPerformed()
actionPerformed
in interface IEventHandler
public boolean isTriggered()
isTriggered
in interface IEventHandler
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |