aboutsummaryrefslogtreecommitdiff
path: root/src/event.rs
diff options
context:
space:
mode:
authorDaniel Schadt <kingdread@gmx.de>2018-06-13 13:17:28 +0200
committerDaniel Schadt <kingdread@gmx.de>2018-06-13 13:17:28 +0200
commit2fe671951369b8f049e8acf02e9e9750c96b4dcd (patch)
tree49e9c0cc4bcbf6d76183555ac95bc3d9504c7a05 /src/event.rs
parentfe16699205b6b40aed8cafbe95820835a7052908 (diff)
downloadevtclib-2fe671951369b8f049e8acf02e9e9750c96b4dcd.tar.gz
evtclib-2fe671951369b8f049e8acf02e9e9750c96b4dcd.tar.bz2
evtclib-2fe671951369b8f049e8acf02e9e9750c96b4dcd.zip
clean up a bit
Diffstat (limited to 'src/event.rs')
-rw-r--r--src/event.rs67
1 files changed, 0 insertions, 67 deletions
diff --git a/src/event.rs b/src/event.rs
index f87688e..02f4686 100644
--- a/src/event.rs
+++ b/src/event.rs
@@ -104,73 +104,6 @@ pub enum EventKind {
},
}
-impl EventKind {
- /// Returns the source agent address for this event, if one exists.
- pub fn source_agent_addr(&self) -> Option<u64> {
- use EventKind::*;
- match *self {
- EnterCombat { agent_addr, .. } => return Some(agent_addr),
- ExitCombat { agent_addr } => return Some(agent_addr),
- ChangeUp { agent_addr } => return Some(agent_addr),
- ChangeDown { agent_addr } => return Some(agent_addr),
- ChangeDead { agent_addr } => return Some(agent_addr),
- Spawn { agent_addr } => return Some(agent_addr),
- Despawn { agent_addr } => return Some(agent_addr),
- HealthUpdate { agent_addr, .. } => return Some(agent_addr),
- WeaponSwap { agent_addr, .. } => return Some(agent_addr),
- MaxHealthUpdate { agent_addr, .. } => return Some(agent_addr),
- PointOfView { agent_addr } => return Some(agent_addr),
- SkillUse {
- source_agent_addr, ..
- } => return Some(source_agent_addr),
- ConditionTick {
- source_agent_addr, ..
- } => return Some(source_agent_addr),
- InvulnTick {
- source_agent_addr, ..
- } => return Some(source_agent_addr),
- Physical {
- source_agent_addr, ..
- } => return Some(source_agent_addr),
- BuffApplication {
- source_agent_addr, ..
- } => return Some(source_agent_addr),
- BuffRemove {
- source_agent_addr, ..
- } => return Some(source_agent_addr),
- _ => return None,
- }
- }
-
- /// Returns the destination agent address for this event, if one exists.
- pub fn destination_agent_addr(&self) -> Option<u64> {
- use EventKind::*;
- match *self {
- ConditionTick {
- destination_agent_addr,
- ..
- } => return Some(destination_agent_addr),
- InvulnTick {
- destination_agent_addr,
- ..
- } => return Some(destination_agent_addr),
- Physical {
- destination_agent_addr,
- ..
- } => return Some(destination_agent_addr),
- BuffApplication {
- destination_agent_addr,
- ..
- } => return Some(destination_agent_addr),
- BuffRemove {
- destination_agent_addr,
- ..
- } => return Some(destination_agent_addr),
- _ => return None,
- }
- }
-}
-
/// A higher-level representation of a combat event.
#[derive(Clone, Debug, PartialEq, Eq)]
pub struct Event {