|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfeud.testgame.Event
An event is everything that the server and the other client should be notified of but that's not really physical, like a new position of the player would be.
Field Summary | |
static int |
BULLET_HIT
|
static int |
ENTITY_REMOVE
|
static int |
FIRE
|
static int |
PLAYER_DAMAGE
|
static int |
PLAYER_DEAD
|
static int |
PLAYER_RESET_HEALTH
|
static int |
PLAYER_RESPAWNED
|
Constructor Summary | |
Event(int type,
int sourceID,
int targetID,
int targetClientID)
Creates a new event. |
|
Event(int type,
LocalObject source,
LocalObject target)
Creates a new event. |
Method Summary | |
com.threed.jpct.SimpleVector |
getOrigin()
Gets the origin of th event. |
int |
getSourceClientID()
Returns the id of the source client. |
int |
getSourceID()
Returns the id of the source object. |
int |
getTargetClientID()
Returns the id of the target client |
int |
getTargetID()
Returns the id of the target object. |
int |
getType()
Returns the type of the event. |
int |
getValue()
Returns the value for the event. |
void |
setOrigin(com.threed.jpct.SimpleVector org)
Sets the origin of the event. |
void |
setSourceClientID(int id)
Sets the id of the source client. |
void |
setValue(int val)
Sets a value for the event. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int BULLET_HIT
public static final int PLAYER_DAMAGE
public static final int PLAYER_DEAD
public static final int ENTITY_REMOVE
public static final int FIRE
public static final int PLAYER_RESPAWNED
public static final int PLAYER_RESET_HEALTH
Constructor Detail |
public Event(int type, int sourceID, int targetID, int targetClientID)
type
- int the type of the event. See the constants above of possible types.sourceID
- int the object id of the source object triggering this event (if any)targetID
- int the id of the target object of this event (if any).targetClientID
- int the id of the target clientpublic Event(int type, LocalObject source, LocalObject target)
type
- int the type of the event. See the constants above of possible types.source
- LocalObject the source object of the eventtarget
- LocalObject the target object of the eventMethod Detail |
public void setOrigin(com.threed.jpct.SimpleVector org)
org
- SimpleVector the originpublic com.threed.jpct.SimpleVector getOrigin()
public void setValue(int val)
val
- int the valuepublic int getValue()
public int getType()
public void setSourceClientID(int id)
id
- int the idpublic int getSourceClientID()
public int getSourceID()
public int getTargetID()
public int getTargetClientID()
public java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |