I've never looked into decompiling the minecraft code and all that due to never really working with Java.
Can someone tell me how minecraft requests a skin file (POST, GET, ETC) from a skinserver and what the expected return is (just the PNG or some JSON or something)?
If I can get the details I'm going to write a python flask app that can handle skins that can be easily ran locally or hosted on something like heroku.
If this is too hard of a thing to tell me let me know and I'll learn how to decompile minecraft to find it. thanks
How does minecraft request a skin file?
Re: How does minecraft request a skin file?
Scratch this I figured it all out.
I'll post my little app once I get some directions written up.
I'll post my little app once I get some directions written up.
Re: How does minecraft request a skin file?
I have issues getting nodejs installed on my machine, so I just decided to write my own very small skin server.
To get a local skin server up and running.
-Download Python Skinner app: https://www.dropbox.com/s/uyl5lw6j298zl ... r.zip?dl=0
-Extract to wherever you want.
-Install Python3: https://www.python.org/downloads/
-Go into the Extracted directory from above
-From cmd line Run: pip install -r requirements.txt (this will just install flask which is a python web server)
-Start app.py by running: python app.py
-Set your url in the BTWconfig file to: http://localhost:8877/player
-Put whatever skin you want your character to use inside the folder with the app.py named the same as your ign ex: mc_isaac.png
Things to know:
-default.png will attach to any player who connects to this who doesn't have a <ign>.png file in the folder. Change it as you like.
-you can change the port this listens on by opening app.py and changing the number "8877" on line 25 to whatever you want
-You can port forward this from your router to the public internet.
-get your the local ip of the PC this runs on, get your public IP.
-Go into your router's port forwarding settings and set port 8877 (or whatever you are using) to the local PC's ip
-Go into your BTWConfig file and set the URL to http://<your_public_ip>:<port>/player
-Be a good friend and download their skins and host them and tell your friends the URL above to connect to.
Questions? PM me.
To get a local skin server up and running.
-Download Python Skinner app: https://www.dropbox.com/s/uyl5lw6j298zl ... r.zip?dl=0
-Extract to wherever you want.
-Install Python3: https://www.python.org/downloads/
-Go into the Extracted directory from above
-From cmd line Run: pip install -r requirements.txt (this will just install flask which is a python web server)
-Start app.py by running: python app.py
-Set your url in the BTWconfig file to: http://localhost:8877/player
-Put whatever skin you want your character to use inside the folder with the app.py named the same as your ign ex: mc_isaac.png
Things to know:
-default.png will attach to any player who connects to this who doesn't have a <ign>.png file in the folder. Change it as you like.
-you can change the port this listens on by opening app.py and changing the number "8877" on line 25 to whatever you want
-You can port forward this from your router to the public internet.
-get your the local ip of the PC this runs on, get your public IP.
-Go into your router's port forwarding settings and set port 8877 (or whatever you are using) to the local PC's ip
-Go into your BTWConfig file and set the URL to http://<your_public_ip>:<port>/player
-Be a good friend and download their skins and host them and tell your friends the URL above to connect to.
Questions? PM me.
- Gilberreke
- Posts: 4486
- Joined: Thu Jul 14, 2011 3:12 pm
- Location: Belgium
Re: How does minecraft request a skin file?
Thanks for this! With both your confirmation that local servers work and a new way to do it, I can update the sticky with correct info. I'll also link to this thread.
Come join us at Vioki's Discord! discord.gg/fhMK5kx
-
- Posts: 262
- Joined: Sun Mar 04, 2012 7:58 pm
Re: How does minecraft request a skin file?
I'm going over this, as I'm considering setting it up myself, and reading the Flask docs it recommends disabling debug mode otherwise users can execute arbitrary code. To do this edit the app.py and in the bottom line change to .
Code: Select all
debug=True
Code: Select all
debug=False