lnkit

Crates.iolnkit
lib.rslnkit
version0.2.1
sourcesrc
created_at2021-04-24 15:58:04.07907
updated_at2021-04-26 19:14:37.361098
descriptionMultiplayer game library
homepage
repositoryhttps://gitlab.com/rasmusmerzin/lnkit
max_upload_size
id389007
size73,852
Emil Rasmus Merzin (rasmusmerzin)

documentation

README

Lnkit

Lnkit is a small "glue" library for making multiplayer 3D games. It ties together rapier & three.js with WebSockets using tungstenite.

The idea is that rapier3d physics engine runs on the server and data is sent to clients using WebSockets. On the client side WebSocket messages are manifested into three.js objects.

Lnkit currently consists of two packages: server written in Rust & client written in Typescript.

The API of this library is currently a little inconvenient but will improve in v0.3 or v0.4.

Installation

To include the server package add the following to Cargo.toml dependencies section.

[dependencies]
...
lnkit = "0.2.1"

Or just add with cargo add lnkit (cargo-edit)

To include the client package add the following to package.json dependencies section.

"dependencies": {
  ...
  "three": "0.x",
  "lnkit": "0.2"
}

Or just add with yarn add three lnkit or npm install three lnkit

Examples

Available examples are in the examples directory.

To run examples clone this repository and run the server with cargo run --example <example_name & client with yarn parcel examples/<example_name>/index.html

Commit count: 42

cargo fmt