BlueGit

blue-star tribegen

Files

tribegen / web / src / Events / Event.php

Event.php

Event.php 899 B Download Raw
1<?php
2
3require_once __DIR__ . '/../../src/Classes/Tribe.php';
4
5abstract class Event
6{
7 protected $tribe;
8 protected $story = '';
9 protected $participants = []; // array of kobold ids
10
11 public function isEndOfMonth()
12 {
13 return false;
14 }
15
16 public function __construct(Tribe $tribe)
17 {
18 $this->tribe = $tribe;
19 }
20
21 abstract public function execute();
22
23 abstract public function getCost();
24
25 public function isAvailable()
26 {
27 return true;
28 }
29
30 public function setParticipants(array $koboldIds)
31 {
32 $this->participants = $koboldIds;
33 }
34
35 public function getParticipants()
36 {
37 return $this->participants;
38 }
39
40 abstract function getMinParticipants();
41
42 abstract function getMaxParticipants();
43
44 abstract function getMinAge();
45
46 public function getStory()
47 {
48 return $this->story;
49 }
50}