class MiniGameException(Exception):
	pass

class MiniGame:
	"""
	A minigame is a class which encapsulates the rules and tokens of a particlar game such as tic-tac-toe, or checkers.
	"""
	notifiers = []

	def Reset(self):
		pass
	
	def AddNotifier(self, func):
		"""
		Add a callback notification function for when a minigame is completed.
		"""
		self.notifiers.append(func)
	
	def Notify(self, value):
		"""
		Call all registered notification callbacks when the minigame is finished.
		"""
		if value:
			[n(value) for n in self.notifiers]
		return value

