Skip to content

Commit af48c73

Browse files
committed
developers guide
1 parent 491b035 commit af48c73

File tree

2 files changed

+37
-11
lines changed

2 files changed

+37
-11
lines changed

README.md

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,19 @@
1-
# WebMc
1+
# webmc
22

33
[![Discord](https://img.shields.io/badge/chat-on%20discord-brightgreen.svg)](https://discord.gg/h6DQzDx2G7)
44
[![Try it on gitpod](https://img.shields.io/badge/try-on%20gitpod-brightgreen.svg)](https://gitpod.io/#https://github.com/michaljaz/web-minecraft)
55
[![Build and Deploy](https://github.com/michaljaz/web-minecraft/actions/workflows/github-pages.yaml/badge.svg)](https://github.com/michaljaz/web-minecraft/actions/workflows/github-pages.yaml)
66
## About
77

8-
**WebMc is minecraft client written in Javascript.** From web browser this client connects to websocket proxy and then to real minecraft server, so you can play minecraft in the browser.
8+
**Webmc is minecraft client written in Javascript.** From web browser this client connects to websocket proxy and then to real minecraft server, so you can play minecraft in the browser.
99

1010
## Demo
1111
Live demo with no installation: https://minecraft.js.org.
1212

13-
## Development setup
1413

15-
```bash
16-
17-
npm install
18-
npm start
19-
```
20-
This will start express and webpack in development mode: whenever you save a file, the build will be redone (it takes 3s), and you can refresh the page to get the new result.
21-
22-
Connect to http://localhost:8080 in your browser. Also specify correct server ip in url param.
14+
## Developing on webmc
2315

16+
[webmc developer's guide](https://github.com/michaljaz/webmc/docs/DEVELOPMENT.md)
2417

2518
## Screenshots
2619
![hypixel](https://i.ibb.co/bPh99MV/hypixel.png "hypixel")

docs/DEVELOPMENT.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# Developer's guide to webmc
2+
3+
## Development
4+
5+
```bash
6+
7+
npm start
8+
```
9+
This will start express and webpack in development mode: whenever you save a file, the build will be redone (it takes 3s), and you can refresh the page to get the new result. It also starts local websocket proxy server.
10+
11+
Connect to http://localhost:8080 in your browser. Also specify correct server ip in url param.
12+
13+
14+
## Production
15+
16+
```bash
17+
18+
npm run build
19+
```
20+
21+
After calling this, it will build app bundle with minified code (in ```/src/dist/``` directory). It may take longer than development setup. By default webmc connects to https://webmcproxy.glitch.me.
22+
23+
Then you have to host built files on some simple http server like [http-server](https://www.npmjs.com/package/http-server).
24+
25+
You can also setup your own proxy server. All you have to do is to run ```npm run proxy``` on server and change some configs in ```/src/assets/config.json```.
26+
27+
## Download production files
28+
29+
If you want to just download webmc production files [click here](https://github.com/michaljaz/webmc/tree/gh-pages).
30+
31+
## If you can't build project with default configuration
32+
33+
Here are the instructions on how to do it correctly [click here](https://github.com/michaljaz/webmc/blob/master/.github/workflows/github-pages.yaml).

0 commit comments

Comments
 (0)