{"id":15043728,"url":"https://github.com/juniorxsound/three.multiplayer","last_synced_at":"2025-03-17T14:17:24.479Z","repository":{"id":40295004,"uuid":"122130283","full_name":"juniorxsound/THREE.Multiplayer","owner":"juniorxsound","description":"🤼‍♂️ A boilerplate server and client setup for Three.js multiplayer using Socket.io","archived":false,"fork":false,"pushed_at":"2023-02-03T10:05:34.000Z","size":88803,"stargazers_count":225,"open_issues_count":10,"forks_count":39,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-03-17T14:17:15.828Z","etag":null,"topics":["3d","gaming","graphics","multiplayer","multiuser","nodejs","socket-io","threejs","webgl","websockets"],"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/juniorxsound.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,"governance":null,"roadmap":null,"authors":null}},"created_at":"2018-02-19T22:47:29.000Z","updated_at":"2025-03-13T22:17:19.000Z","dependencies_parsed_at":"2023-02-14T07:16:38.181Z","dependency_job_id":null,"html_url":"https://github.com/juniorxsound/THREE.Multiplayer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/juniorxsound%2FTHREE.Multiplayer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/juniorxsound%2FTHREE.Multiplayer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/juniorxsound%2FTHREE.Multiplayer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/juniorxsound%2FTHREE.Multiplayer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/juniorxsound","download_url":"https://codeload.github.com/juniorxsound/THREE.Multiplayer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244047646,"owners_count":20389206,"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":["3d","gaming","graphics","multiplayer","multiuser","nodejs","socket-io","threejs","webgl","websockets"],"created_at":"2024-09-24T20:49:30.729Z","updated_at":"2025-03-17T14:17:24.443Z","avatar_url":"https://github.com/juniorxsound.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# THREE Multiplayer\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com)\n\n\u003e Looking for a React three fiber multiplayer template? check out [R3F.Multiplayer](https://github.com/juniorxsound/R3F.Multiplayer)\n\nMy boilerplate Node.js server and client setup for Three.js multiplayer projects using Socket.io\n- [Installation](#installation)\n- [Usage](#usage)\n- [Pushing to Heroku](#pushing-to-heroku)\n\n![Multiplayer](https://github.com/juniorxsound/THREE-Multiplayer/blob/master/resources/multiplayer.gif)\n\n## Installation\n1. Clone the repo, e.g ```git clone https://github.com/juniorxsound/THREE-Multiplayer.git```\n1. Run ```npm install``` to install all the dependencies\n\n\u003e Tested on macOS 10.13.3 using Node.js v8.9.3 and npm v5.6.0\n\n## Usage\nUse ```npm run start``` to start the server and bundler\n\n![NPM](https://github.com/juniorxsound/THREE-Multiplayer/blob/master/resources/run_start.gif)\n\nThe start script launches:\n- ```nodemon``` Which restarts the server on every change (port: 1989)\n- ```watchify``` Which bundles the client code from ```src/``` on every change to ```./public/js/bundle.js```\n\n![Server Log](https://github.com/juniorxsound/THREE-Multiplayer/blob/master/resources/Logs.png)\n\nOn connection each client recives it's uniqe ID and on every movement broadcasts to all the other clients all the locations of everyone connected\n```js\n{\n  'some-user-id': {\n    position: [0.4, 1.4, -0.5],\n    rotation: [0, 0, 0]\n  }\n}\n```\n\nYou can also run ```npm run build``` to bundle and minify the client code to ```./public/js/bundle.min.js```\n\nBrowserify is setup to transform both ES6 Javascript and ```glslify``` for GLSL shader bundling ([example](https://github.com/juniorxsound/DepthKit.js) of a project that uses ```glslify```)\n\n## Pushing to Heroku\n[This is a detailed tutorial](https://devcenter.heroku.com/articles/getting-started-with-nodejs#introduction) of how to push your code to Heroku through Github to serve your experience publicly\n\n\u003e Special thanks to [Dror Ayalon](https://github.com/dodiku)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjuniorxsound%2Fthree.multiplayer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjuniorxsound%2Fthree.multiplayer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjuniorxsound%2Fthree.multiplayer/lists"}