Broodwar API binding
Project description
Pybrood
=======
|docs|
Binding made as from-scratch code generator, outputting msvc project.
Precompiled installation
------------------------
Requirements:
- Windows 7 32 bit (just exactly SSCAIT requirement)
NOTE: I couldn't successfully run BWAPI injector under Wine,
although recently I've been told
`it's
possible <https://github.com/TorchCraft/TorchCraft/blob/master/docs/user/bwapi_on_linux.md>`__.
- `Python
3.5 <https://www.python.org/ftp/python/3.5.2/python-3.5.2.exe>`__
- Installed BWAPI and SC
::
pip install pybrood
Documentation
-------------
`Read the docs <http://pybrood.readthedocs.io/en/latest/>`__
Compiling from source
---------------------
Additional requirements:
- `Visual C++ build
tools <http://landinghub.visualstudio.com/visual-cpp-build-tools>`__
or complete Visual Studio.
NOTE: pick the version of compiler/studio considering `build tools
used by python <https://wiki.python.org/moin/WindowsCompilers>`__
- `BWAPI 4.1.2
sources <https://github.com/bwapi/bwapi/releases/tag/v4.1.2>`__
you need ``BWAPI.lib`` and ``BWAPIClient.lib`` built against chosen
compiler to link pybrood module
- Most fresh (dec 2016) `Pybind11
headers <https://github.com/pybind/pybind11>`__
Building BWAPI.lib and BWAPIClient.lib
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| You may experience "access denied" errors while working directly in
"program files/BWAPI".
| Better use separately cloned git repo of BWAPI where you have full
access.
| For ``msbuild`` invocation use special VC++ related cmd shell from
Launch menu.
| Otherwise you can use usual cmd shell.
#. Make some changes in bwapi source files first:
- | little fix in ``bwapi/include/BWAPI/SetContainer.h:53``:
| at very end of class add
``SetContainer& operator=(const SetContainer&) = default;``
to get rid of "attempting to reference a deleted function" error.
- disable mass file copying in ``bwapi/BWAPILIB/BWAPILIB.vcxproj``:
- line 64: ``<PreLinkEvent>`` → ``<!-- PreLinkEvent>``
- line 94: ``</PreLinkEvent>`` → ``</PreLinkEvent -->``
- create file ``bwapi/svnrev.h``:
``static const int SVN_REV = 4708; #include "starcraftver.h"``
This prevents "Client and Server are not compatible" error.
#. Build BWAPI.lib:
``cd bwapi\BWAPILIB\ msbuild /p:PlatformToolset=v140 /p:Configuration=Release /p:Platform=Win32``
Output file is ``bwapi/lib/BWAPI.lib``.
#. Build BWAPIClient.lib:
``cd bwapi\BWAPIClient\ msbuild /p:PlatformToolset=v140 /p:Configuration=Release /p:Platform=Win32``
Output file is ``bwapi/lib/BWAPIClient.lib``.
Building Pybrood
~~~~~~~~~~~~~~~~
#. ``pip install -r generator/requirements.txt``
#. Setup paths in `generator/config.py <generator/config.py>`__.
#. Run the generator ``python3.5 -m generator``.
#. ``cd`` to freshly generated ``output`` folder and run ``build.bat``
(it's just the same msbuild command).
#. Copy/symlink ``output/Release/inner.pyd`` into ``pybrood`` directory.
``inner.pyd`` is a required submodule of ``pybrood``.
#. Now you should be able to ``import pybrood``.
#. Optionally you can build your local copy of documentation:
``cd output/docs/ sphinx-build . -b html _build/html``
.. |docs| image:: https://readthedocs.org/projects/pybrood/badge/?version=latest
:target: http://pybrood.readthedocs.io/en/latest/
=======
|docs|
Binding made as from-scratch code generator, outputting msvc project.
Precompiled installation
------------------------
Requirements:
- Windows 7 32 bit (just exactly SSCAIT requirement)
NOTE: I couldn't successfully run BWAPI injector under Wine,
although recently I've been told
`it's
possible <https://github.com/TorchCraft/TorchCraft/blob/master/docs/user/bwapi_on_linux.md>`__.
- `Python
3.5 <https://www.python.org/ftp/python/3.5.2/python-3.5.2.exe>`__
- Installed BWAPI and SC
::
pip install pybrood
Documentation
-------------
`Read the docs <http://pybrood.readthedocs.io/en/latest/>`__
Compiling from source
---------------------
Additional requirements:
- `Visual C++ build
tools <http://landinghub.visualstudio.com/visual-cpp-build-tools>`__
or complete Visual Studio.
NOTE: pick the version of compiler/studio considering `build tools
used by python <https://wiki.python.org/moin/WindowsCompilers>`__
- `BWAPI 4.1.2
sources <https://github.com/bwapi/bwapi/releases/tag/v4.1.2>`__
you need ``BWAPI.lib`` and ``BWAPIClient.lib`` built against chosen
compiler to link pybrood module
- Most fresh (dec 2016) `Pybind11
headers <https://github.com/pybind/pybind11>`__
Building BWAPI.lib and BWAPIClient.lib
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| You may experience "access denied" errors while working directly in
"program files/BWAPI".
| Better use separately cloned git repo of BWAPI where you have full
access.
| For ``msbuild`` invocation use special VC++ related cmd shell from
Launch menu.
| Otherwise you can use usual cmd shell.
#. Make some changes in bwapi source files first:
- | little fix in ``bwapi/include/BWAPI/SetContainer.h:53``:
| at very end of class add
``SetContainer& operator=(const SetContainer&) = default;``
to get rid of "attempting to reference a deleted function" error.
- disable mass file copying in ``bwapi/BWAPILIB/BWAPILIB.vcxproj``:
- line 64: ``<PreLinkEvent>`` → ``<!-- PreLinkEvent>``
- line 94: ``</PreLinkEvent>`` → ``</PreLinkEvent -->``
- create file ``bwapi/svnrev.h``:
``static const int SVN_REV = 4708; #include "starcraftver.h"``
This prevents "Client and Server are not compatible" error.
#. Build BWAPI.lib:
``cd bwapi\BWAPILIB\ msbuild /p:PlatformToolset=v140 /p:Configuration=Release /p:Platform=Win32``
Output file is ``bwapi/lib/BWAPI.lib``.
#. Build BWAPIClient.lib:
``cd bwapi\BWAPIClient\ msbuild /p:PlatformToolset=v140 /p:Configuration=Release /p:Platform=Win32``
Output file is ``bwapi/lib/BWAPIClient.lib``.
Building Pybrood
~~~~~~~~~~~~~~~~
#. ``pip install -r generator/requirements.txt``
#. Setup paths in `generator/config.py <generator/config.py>`__.
#. Run the generator ``python3.5 -m generator``.
#. ``cd`` to freshly generated ``output`` folder and run ``build.bat``
(it's just the same msbuild command).
#. Copy/symlink ``output/Release/inner.pyd`` into ``pybrood`` directory.
``inner.pyd`` is a required submodule of ``pybrood``.
#. Now you should be able to ``import pybrood``.
#. Optionally you can build your local copy of documentation:
``cd output/docs/ sphinx-build . -b html _build/html``
.. |docs| image:: https://readthedocs.org/projects/pybrood/badge/?version=latest
:target: http://pybrood.readthedocs.io/en/latest/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distributions
pybrood-0.9.2-cp36-none-win32.whl
(393.6 kB
view details)
pybrood-0.9.2-cp35-none-win32.whl
(393.6 kB
view details)
File details
Details for the file pybrood-0.9.2-cp36-none-win32.whl
.
File metadata
- Download URL: pybrood-0.9.2-cp36-none-win32.whl
- Upload date:
- Size: 393.6 kB
- Tags: CPython 3.6, Windows x86
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8599d2ac851d999f7b902f69944318f884957bdcf39cfc6316711b4ca337de9f |
|
MD5 | 440c4a154e8f5c57fd4381c8b6a07f95 |
|
BLAKE2b-256 | d4358fad856edf7a811017db1aed6e9fa01799667620159f56691ad57eeafcbc |
File details
Details for the file pybrood-0.9.2-cp35-none-win32.whl
.
File metadata
- Download URL: pybrood-0.9.2-cp35-none-win32.whl
- Upload date:
- Size: 393.6 kB
- Tags: CPython 3.5, Windows x86
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6e557d988efd535d9494059ea6545d72d15c159fbda8303f3398ca86cb2d8b18 |
|
MD5 | 1f2fd100fa09de95f1d70b503cbcb330 |
|
BLAKE2b-256 | e100a9d2b4205716ae833e5f94420eb3fac902a7e7fe46de84694dd347d54305 |