How create Bot using Python
I want to use OpenRA to create a bot with Python scripting (Researching Artificial Intelligence in Games). What I have accomplished: - I can run the engine on my Ubuntu using ./OpenRA-Red-Alert-x86_64.AppImage Create a game, play, etc... What I haven't been able to do: - Find in the documentation how to integrate with the API using Python - Import this Python script into the engine.
How create Bot using Python
I want to use OpenRA to create a bot with Python scripting (Researching Artificial Intelligence in Games).
What I have accomplished:
- I can run the engine on my Ubuntu using ./OpenRA-Red-Alert-x86_64.AppImage
Create a game, play, etc...
What I haven't been able to do:
- Find in the documentation how to integrate with the API using Python
- Import this Python script into the engine.
What I have accomplished:
- I can run the engine on my Ubuntu using ./OpenRA-Red-Alert-x86_64.AppImage
Create a game, play, etc...
What I haven't been able to do:
- Find in the documentation how to integrate with the API using Python
- Import this Python script into the engine.
Re: How create Bot using Python
OpenRA does not expose an API for Python. We only have a Lua API for scripting missions: https://docs.openra.net/en/release/lua/
Re: How create Bot using Python
Incredible. Thanks for the feedback.
I read the documentation on, but still don't understand, how to use my custom script in a single player party.
My objective:
Create a SinglePlayer game, where I play against my Lua script
I ventured into several links, but I still need help.
Some of what I read. I read others too
https://github.com/OpenRA/OpenRA/wiki/Map-scripting
https://github.com/search?q=repo%3AOpen ... &type=Code
https://docs.openra.net/en/release/lua/
I read the documentation on, but still don't understand, how to use my custom script in a single player party.
My objective:
Create a SinglePlayer game, where I play against my Lua script
I ventured into several links, but I still need help.
Some of what I read. I read others too
https://github.com/OpenRA/OpenRA/wiki/Map-scripting
https://github.com/search?q=repo%3AOpen ... &type=Code
https://docs.openra.net/en/release/lua/
Re: How create Bot using Python
The AI is currently written in C# and works in modules. In yaml, the modules are defined and tweaked, see ai.yaml.
Our lua integration is currently insufficient to fully support bots; too few variables and functions are exposed. The lua integration was made for mission scripting and even then it's functionality is a bit lacking. F.e. some missions for d2k are still yet to be made as the lua controlled bots need to be able to build a base. To see the source code behind the integration see C# files that end with *Properties.cs