Skip to content

dkargin/pyd20

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

93 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

What is this

This is D&D 3.5 battle ground, implemented in python 3.5

Installation

p20dnd requires pygame to render battlescape

web game requires:

  • eventlet
  • flask
  • wtforms
  • flask_socketio
pip install pygame

How to use

Look at main.py.

  1. Create battle instance
  2. Generate characters and add them to battle:
  3. Keep iterating turns until battle is resolved

What is implemented

  1. Basic actions:
    • Standard attack
    • Movement
    • Full attack
  2. Basic class progression internals: BAB, saving throw, HP
  3. Basic weapons, armors and shields and its stats
  4. Pathfinding works for single-tiled creatures (medium and smaller)
  5. Basic AI. AI looks for target, moves in weapon range and attacks it
  6. Resolving attack of opportunity for movement in threatened area
  7. Supported creatures with large and large sizes and appropriate reach
  8. Implemented event system to allow feats override different parts of game mechanics. Allows to implement feats in a less intrusive way. More stuff can be implemented without if character.has_feat('another_feat') all over the code
  9. Core classes
    • Monk. Implemented basic progression and some class feats
    • Fighter. Implemented basic progression
  10. Some actions and interactions are animated:
    • movement
    • attack start
    • attack finish

Plan

  1. Charge attack
    • draw a line OK
    • move a line OK
    • can be interrupted!
    • pathfinding problems: stumbled by its own occupancy. Character should remove itself from the map every turn start
  2. Fix pathfinder:
    • combatant has its own local pathfinder
    • battle contains 'generic' pathfinder for far routes
  3. Ranged attack
    • move to range OK?
    • bow them all OK?
    • draw an arrow
    • reload action
    • crossbow reload
  4. Some skill checks: tumble, spot, search
  5. Manual brain
    • generate available actions
    • implement UI to pick another action
  6. Draw weapon sprites
  7. Spring attack series. Because they are awesome!
  8. Brain should switch weapons according to situation and distance to enemy
  9. Vision stuff.
    • Hide, Spot, listen
  10. Some spells (most interesting for me):
    • True strike. Remove bonus after the first strike
    • Shield
    • Smite
    • Mage armor
    • Scorching ray
    • Greater invisibility
    • Darkness
    • Grease (skills need to be implemented)
    • Rhino's rush. Need charge to be implemented
    • Fireball

About

A d20 implementation for python

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 90.9%
  • JavaScript 6.1%
  • HTML 2.5%
  • CSS 0.5%