PyYugi is an attempt to capture the Yu Gi Oh game in Python in such a way that is easy and extendable. The goal is to be able to design an automated system for auto play and optimization problems.
I do not provide any data that pertains to the trademarks of the game Yu Gi Oh and I am not affiliated with Konami.
Any and all Yu Gi Oh metadata is from the Yu Gi Oh database https://ygoprodeck.com/. If the website is down, then one will have to resupply the metadata for the program to work properly.
There are two main programs included.
Program to kickstart a file that plays the framework.
python main.py
A simple interactive terminal to search for a card in the database.
python yugi_terminal.py
PyYugi allows fast loading of cards from a deck by listing out cardnames in a count within csv files.
To create a deck, go to the deck folder and create a csv file. For example, "synchron.csv"
Now format the file like the following:
swift scarecrow: 3
tuningware: 1
EXT:
junk speeder: 2
stardust dragon: 1
Everything after the "EXT:" keyword will be treated as cards in the extra deck. Numbers after the card name represents the card count for that specific card.
Cards can be specifically loaded by the ld_deck.py module and can be called via:
load_deck("synchron")
Notice the lack of csv ext in the load function. Besure to load the DB before hand. Refer to main.py for example.
If the main database that is being used does not exist, the files must be provided locally.
They are folders to store DB data for caching and deck data for building decks.
Depending on the success of the project, more documentation will be written. Right now, main.py will be assumed to be a standalone program.