basic abstract classes for battle instances.
This commit is contained in:
parent
dc0842fb0a
commit
a3c627f624
@ -4,6 +4,7 @@
|
|||||||
todo: finding battles. factory for missions, skirmishes?
|
todo: finding battles. factory for missions, skirmishes?
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
# basic battle: responsible for managing, recognizing and parsing a single battle instance.
|
||||||
class Battle(object):
|
class Battle(object):
|
||||||
def __init__(self, parent=None):
|
def __init__(self, parent=None):
|
||||||
# parent is a log-session usually
|
# parent is a log-session usually
|
||||||
@ -12,8 +13,55 @@ class Battle(object):
|
|||||||
self.time_start = None
|
self.time_start = None
|
||||||
self.time_end = None
|
self.time_end = None
|
||||||
self.owner = None
|
self.owner = None
|
||||||
|
self.live = False # whether this is a streamed object.
|
||||||
|
self.map = None
|
||||||
|
|
||||||
|
def parse_details(self):
|
||||||
|
# fast parse strategy: fill in all details about this battle.
|
||||||
|
pass
|
||||||
|
|
||||||
|
def parse_statistics(self):
|
||||||
|
# parse battle statistics.
|
||||||
|
pass
|
||||||
|
|
||||||
|
class PvPBattle(Battle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
class PvPTDM(PvPBattle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
class PvPDomination(PvPBattle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
class PvPCombatRecon(PvPBattle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
class PvPCtB(PvPBattle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
class PvPDetonation(PvPBattle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
class PvPBeaconHunt(PvPBattle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
# Dreads
|
||||||
|
class DreadnoughtBattle(Battle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
### PvE Stuff: low prio.
|
||||||
|
class PvEBattle(Battle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
class PvERaidBattle(PvEBattle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
# Openspace time.
|
||||||
|
class Openspace(Battle):
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
###
|
||||||
def battle_factory(logs):
|
def battle_factory(logs):
|
||||||
''' takes a log session and returns the battles in it
|
''' takes a log session and returns the battles in it
|
||||||
makes a preliminary scan for information
|
makes a preliminary scan for information
|
||||||
|
Loading…
Reference in New Issue
Block a user