c89c0320 by Branden

#Babbies first kobold

1 parent 63f7c008
1 '''
2 Created on Dec 20, 2016
3
4 @author: Xorfos
5 '''
6
7 from mobs import npc
8 from random import randint
9
10 class WeakKobold(npc):
11
12 def at_object_creation(self):
13 self.db.strength = randint(1,2)
14 self.db.agility = randint(1,3)
15 self.db.magic = 0
16
17 def get_abilities(self):
18 return self.db.strength, self.db.agility, self.db.magic
19
20
21 class KoboldShaman(npc):
22
23 def at_object_creation(self):
24 self.db.strength = 1
25 self.db.agility = randint(1,3)
26 self.db.magic = randint(2,4)
27
28 def get_abilities(self):
29 return self.db.strength, self.db.agility, self.db.magic
...\ No newline at end of file ...\ No newline at end of file
1 '''
2 Created on Dec 20, 2016
3
4 @author: Xorfos
5 '''
6 from chartacters import Character
7
8 class Npc(Character):
9
10 """
11 A NPC typeclass which extends the character class
12 For all mobs to extend
13 """
14
15
16
...\ No newline at end of file ...\ No newline at end of file
...@@ -18,7 +18,7 @@ class WiseObject(Object): ...@@ -18,7 +18,7 @@ class WiseObject(Object):
18 "Called when object is first created" 18 "Called when object is first created"
19 self.db.wise_texts = \ 19 self.db.wise_texts = \
20 ["Stones have feelings too.", 20 ["Stones have feelings too.",
21 "To live like a stone is to not have lived at all." 21 "To live like a stone is to not have lived at all.",
22 "The world is like a rock of chocolate."] 22 "The world is like a rock of chocolate."]
23 23
24 def return_appearance(self, looker): 24 def return_appearance(self, looker):
......