Skip to main content

Client for iv4XR Space Engineers plugin.

Project description

Python Client

Client for iv4XR plugin. It can be used to control the Space Engineers game. The plugin is developed by GoodAI.

As an alternative there is more advanced client in Kotlin.

Installation

The client itself doesn't have any dependencies, but some examples do:

If you want to install those dependencies, simply install them through pip:

pip install -r requirements.txt

Basic usage

To use the client, you have to have Space Engineers game with a running iv4XR plugin.

To connect to a local game with a running plugin:

from spaceengineers.proxy import SpaceEngineersProxy
se = SpaceEngineersProxy.localhost()
# Example - go to "Load game" screen (game has to be in the main menu):
se.Screens.MainMenu.LoadGame()

For more API, take a look at api.py. Class SpaceEngineers being the root of the API tree.

See examples directory for more.

Limitations

  • All API calls have to be made either with all arguments named or all arguments positional (named arguments are recommended). Mixture is not allowed and will cause an error.
  • All default values have to be provided.

Background

The client is simple wrapper around JSON-RPC protocol. Files models.py and api.py are generated by kotlin client .

Cucumber implementation

The project includes a single feature file C284491.feature . This file has been copied from kotlin client. By implementing steps it showcases re-usability of gherkin

Type behave from the root of the project to run the test (behave needs to be installed, see Installation). Or you can right-click the feature file in PyCharm and select Run.

Useful links

Project details


Download files

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

Source Distribution

space_engineers_iv4xr-0.0.1b0.tar.gz (16.1 kB view hashes)

Uploaded Source

Built Distribution

space_engineers_iv4xr-0.0.1b0-py3-none-any.whl (10.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page