Conversation
entities.py
Outdated
|
|
||
|
|
||
| class Entity(object): | ||
| def __init__(self, grid, direction="U", health=30, maxhealth=30, speed=1, accuracy=2, flatDamage = 2, damageRange=2, damageMod=2, vision=3, armor=10, phasing = False, name = None, effect = dict()): |
There was a problem hiding this comment.
Take out all the defaults on here (except for phasing). There's no reason to have them, since it will probably vary almost completely from monster to monster. Just have each of the monster types pass it the specific you want.
|
Could it be possible that the game runs really slowly because of the number of things you're printing to the pygame screen? I'm not sure if calculations in your code might also be affecting the speed, but that's also possible. However, printing things is often more time-intensive than calculating things... I think? |
| self.directionCoordinates = {"U":(0,-1),"D":(0,1),"L":(-1,0),"R":(1,0)} # a table of which directions means which coordinates | ||
| print self.directionCoordinates | ||
| def attackRoll(self): #1d20+accuracy, if it exceeds armor class it's a hit | ||
| return randint(1,20)+self.accuracy #roll a 20-sided dice and add accuracy to the roll - average is 10.5 + accuracy |
There was a problem hiding this comment.
Personally, I like having an attack roll. Maybe display damage done so that even if the player 'misses', they can see that they were trying to do the right thing.
|
|
Do you know what you're going to do with the health bar? If you're going to keep using pygame, maybe you could outline it with a white rectangle (so that the player knows how much health they have lost/still have left), or make the bar a green rectangle with a red rectangle over it that gets bigger as the player's health decreases. |
Conflicts: coreMechanics.pyc dungeonGenerationAlgorithms.pyc dungeonGraphics.pyc entities.pyc interfaceClasses.pyc terrainUtils.pyc
getting new commits
…n't really know about it...
Conflicts: coreMechanics.pyc dialogue/conversation.txt dialogue/conversation.txt~ dungeonGenerationAlgorithms.pyc dungeonGraphics.pyc entities.pyc interfaceClasses.pyc terrainUtils.pyc
…ng. adjusted sizes of stuff. made it so zombies turn towards you when they attack you. edited some of the dialogue to make it easier to understand. Made the floors/walls more interesting, take a look.
Conflicts: dialogue/conversation.txt
Conflicts: coreMechanics.pyc dialogue/__init__.pyc dialogue/textutil.pyc dungeonGenerationAlgorithms.pyc dungeonGraphics.pyc entities.pyc eventList.pyc interfaceClasses.pyc saves/last_save.dun terrainUtils.pyc
Conflicts: saves/last_save.dun terrainUtils.pyc
dungeonGraphics.DungeonModelView;
dungeonGenerationAlgorithms.generateWhole;
entities.Entity