hsahovic / poke-env

A python interface for training Reinforcement Learning bots to battle on pokemon showdown
https://poke-env.readthedocs.io/
MIT License
293 stars 98 forks source link

Raw Stats not accessible until a Request #576

Closed caymansimpson closed 3 weeks ago

caymansimpson commented 2 months ago

A mon's stats are not accessible until a Request occurs, which makes it hard to make damage calcs without parsing and storing the team.

Would you be open to a PR that:

  1. Tracks stats w/ an internal Pokemon._stats variable?
  2. Updates the getter for Pokemon.stats, changing it from Pokemon._last_request to _stats variable?
  3. Adds a setter for Pokemon.stats in Pokemon?
  4. Updates internal _stats variable in Pokemon.update_from_request
  5. In player._create_battle, calculates and sets the stats, with help from stats.py?