Skip to main content

A python wrapper for the ENet library

Project description

# pyenet

pyenet is a python wrapper for the ENet library by Lee Salzman,
http://enet.bespin.org

It was originally written by Scott Robinson <scott@tranzoa.com> and is
currently maintained by Andrew Resch <andrewresch@gmail.com>

This fork is being maintained by the piqueserver team for purposes of including
patches for bugs found while developing piqueserver, and to provide a package
on pypi.

## License

pyenet is licensed under the BSD license, see LICENSE for details.
enet is licensed under the MIT license, see http://enet.bespin.org/License.html

## Dependencies

Building pyenet requires all the same dependencies as enet plus Cython and,
obviously, Python.

## Installation

### From pypi

```
pip install pyenet
```

### Manually from git

Note: the enet sources are automatically downloaded from http://enet.bespin.org/
by `setup.py`.

This version of pyenet requires enet 1.3.

Run the setup.py build:

```
$ python setup.py build
```

Once that is complete, install the new pyenet module:

```
# python setup.py install
```

## Usage

Once you have installed pyenet, you only need to import the enet module to
start using enet in your project.

Example server:
```
>>> import enet
>>> host = enet.Host(enet.Address("localhost", 33333), 1, 0, 0)
>>> event = host.service(0)
```
Example client:
```
>>> import enet
>>> host = enet.Host(None, 1, 0, 0)
>>> peer = host.connect(enet.Address("localhost", 33333), 1)
```
More information on usage can be obtained from:
http://enet.bespin.org/Tutorial.html

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

pyenet-1.3.13.post4.tar.gz (12.8 kB view details)

Uploaded Source

File details

Details for the file pyenet-1.3.13.post4.tar.gz.

File metadata

  • Download URL: pyenet-1.3.13.post4.tar.gz
  • Upload date:
  • Size: 12.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for pyenet-1.3.13.post4.tar.gz
Algorithm Hash digest
SHA256 2406b05ef95153d5c3732c3df1bfd3401bf112cd735de4da4c0f6a850c17dec2
MD5 58f672789a9e5e6200a782749687e401
BLAKE2b-256 4870ee1b5d74b74678c5a634abc5c368f86a867ab5aa1e8e45d0700cc7b5e0ba

See more details on using hashes here.

Supported by

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