Skip to main content

Get Real, Living™ Pokémon in Python

Project description

pokemaster - Get Real, Living™ Pokémon in Python

Travis CI codecov Codacy Badge Code style: black

Introduction

pokemaster lets you create Pokémon that is native to the core series Pokémon games developed by Game Freak & Nintendo.

In pokemaster, everything you get is what you would expect in the games: a Pokémon has a bunch of attributes, knows up to four moves, can be evolved to another species, can learn, forget, and remember certain moves, can use moves to do stuff (such as attacking another Pokémon), can consume certain items, and much, much more.

Installation

pokemaster can be installed via pip, but you have to have pokedex installed first:

pip install git+https://github.com/kipyin/pokedex
pip install pokemaster

Or, if you have poetry, run:

poetry add pokemaster -E pokedex

Basic Usage

To summon a Real, Living™ Pokémon:

from pokemaster import Pokemon
bulbasaur = Pokemon(national_id=1, level=5)
eevee = Pokemon('eevee', level=10, gender='female')

Development

Installing

To make contribution, you need to clone the repo first, of course:

git clone https://github.com/kipyin/pokemaster.git
cd pokemaster

If you have poetry installed, you can install the dependencies directly:

poetry install -v -E pokedex

This will equip everything you need for the development.

Linting

We use black to format the code, and isort to sort the imports.

The best way to ensure all files are in the right format is using tox:

tox -e lint

Testing

After making commits, make sure all tests are passed. To run tests against all environments, simply do:

$ tox

If you want to run tests against specific Python version, use tox -e {env}.

For example, if you want to run tests against Python 3.7, run the following command:

$ tox -e py37

LICENSE

MIT License

Copyright (c) 2019 Kip Yin

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pokemaster, version 0.2.2
Filename, size & hash File type Python version Upload date
pokemaster-0.2.2-py3-none-any.whl (51.8 kB) View hashes Wheel py3
pokemaster-0.2.2.tar.gz (17.4 kB) View hashes Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page