{"id":16579718,"url":"https://github.com/oguzeroglu/rhubarb","last_synced_at":"2025-03-17T10:08:03.312Z","repository":{"id":36841560,"uuid":"230680076","full_name":"oguzeroglu/Rhubarb","owner":"oguzeroglu","description":"A WebSocket library optimized for multiplayer JS games, works on WebWorkers with binary data.","archived":false,"fork":false,"pushed_at":"2022-12-11T18:41:37.000Z","size":897,"stargazers_count":201,"open_issues_count":21,"forks_count":8,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-03-04T07:37:49.351Z","etag":null,"topics":["game-development","game-server","html5","javascript","multiplayer","webgl","websocket","websocket-library","webworker"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/oguzeroglu.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-12-28T23:33:59.000Z","updated_at":"2025-01-12T20:27:58.000Z","dependencies_parsed_at":"2022-08-24T21:50:52.643Z","dependency_job_id":null,"html_url":"https://github.com/oguzeroglu/Rhubarb","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzeroglu%2FRhubarb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzeroglu%2FRhubarb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzeroglu%2FRhubarb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzeroglu%2FRhubarb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/oguzeroglu","download_url":"https://codeload.github.com/oguzeroglu/Rhubarb/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244014136,"owners_count":20383715,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["game-development","game-server","html5","javascript","multiplayer","webgl","websocket","websocket-library","webworker"],"created_at":"2024-10-11T22:19:04.857Z","updated_at":"2025-03-17T10:08:03.284Z","avatar_url":"https://github.com/oguzeroglu.png","language":"JavaScript","readme":"# Rhubarb\n\n[See Wiki page](https://github.com/oguzeroglu/Rhubarb/wiki)\n\nRhubarb is a lightweight WebSocket library for multiplayer HTML5 games. It is originally designed to be used by the [ROYGBIV Engine](https://github.com/oguzeroglu/ROYGBIV). However it can be used outside of ROYGBIV as well.\n\nRhubarb is named after this [Aphex Twin track](https://www.youtube.com/watch?v=_AWIqXzvX-U).\n\nRhubarb works both on browsers and NodeJS.\n\n\n![](/rhubarb.gif?raw=true)    \n\n## Philosophy\n\nJavascript is slow, therefore we want to have as much main-process-power as we can\nin order to do game related calculations, graphics rendering and achieving 60 FPS.\n\nFor multiplayer games achieving 60 FPS gets even more complicated given that transferring data\nover WebSockets is a slow operation. It also triggers GC activity by copying the transferred\ndata (if JSON is the preferred way), which eventually slows down the main thread as well.\n\nRhubarb is designed to overcome these problems by:\n\n1. Using WebWorkers to handle networking out of main thread -\u003e More time left for rendering in main thread\n2. Using transferables between the main thread and the worker to prevent GC activity (zero copy)\n3. Redefining/compressing and sending protocols using Float32Arrays -\u003e Much less bandwidth consumption than *JSON.stringify*.\n4. Allowing users to define their protocols in a high-level way and taking care of all the dirty bitwise operations internally.\n5. Allowing sharing same protocol definitions between server/client.\n6. Allocating objects only when being initialized. Reusing everything to prevent GC activity (That means *mutating* things, yeah get over it.)\n\n## Installation\n\nFor clients: `\u003cscript src=\"PATH_TO_Rhubarb.min.js\"\u003e \u003c/script\u003e`\n\nFor servers: `npm install rhubarb-js`\n\n## Usage\n\nSee [this tutorial](https://github.com/oguzeroglu/Rhubarb/wiki/Getting-started) to see how to use Rhubarb.\n\nSee [here](https://github.com/oguzeroglu/Rhubarb/wiki/API-reference) for the API reference.\n\n## Demo\n\nSee [here](https://github.com/oguzeroglu/Rhubarb/wiki/Demos-and-how-to-start-them)\n\n## Licence\n\nRhubarb uses MIT license.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foguzeroglu%2Frhubarb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foguzeroglu%2Frhubarb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foguzeroglu%2Frhubarb/lists"}