Metadata-Version: 2.1
Name: pyftg
Version: 2.1.1
Summary: An interface for implementing python AI in DareFightingICE
Author: TeamFightingICE
Project-URL: Homepage, https://github.com/TeamFightingICE/pyftg
Project-URL: Issues, https://github.com/TeamFightingICE/pyftg/issues
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: grpcio ~=1.62.1
Requires-Dist: grpcio-tools ~=1.62.1
Requires-Dist: protobuf ~=4.25.3

# pyftg

An interface for implementing python AI in DareFightingICE

First, install `pyftg` with pip.
```
pip install pyftg
```

Initiate `Gateway` for connecting to DareFightingICE platform.
```
from pyftg.utils.gateway import get_async_gateway
gateway = get_async_gateway(port=50051)
```

Construct an agent and register it to gateway and then run the game by using following code.
```
agent1 = KickAI()
agent2 = DisplayInfo()
gateway.register_ai("KickAI", agent1)
gateway.register_ai("DisplayInfo", agent2)
await gateway.run_game(["ZEN", "ZEN"], ["KickAI", "DisplayInfo"], game_num)
```

After all the process are done, please also close the gateway.
```
await gateway.close()
```

Please refer to the examples provided in the `examples` directory for more information.
