Page 1 of 1

Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 12:46 pm
by olliekb
I should be able to copy and paste the code and it work right. I understand most of the stuff in the code. I copied and pasted the code into php tags and it wouldnt work.

Re: Minecraft Player Face Rendering

Posted: Sat Jun 29, 2013 1:04 pm
by Helx
olliekb wrote:I should be able to copy and paste the code and it work right. I understand most of the stuff in the code. I copied and pasted the code into php tags and it wouldnt work.


It could be your host or server software.

Some hosts don't like people connecting outside of their network through PHP.
Some software doesn't support/won't allow outside connections (maybe it's a free version?).

If you can't determine the problem, please create a new thread in this subforum: viewforum.php?f=4

Re: Minecraft Player Face Rendering

Posted: Sat Jun 29, 2013 1:22 pm
by olliekb
Thanks for the advice all the other PHP works just not these rendering ones.

Re: Minecraft Player Face Rendering

Posted: Sat Jun 29, 2013 1:30 pm
by Helx
Sorry - just had to split this topic.

I think I know what your problem is.
You don't have GD or ImageMagick installed.

If you use a professional host, you're going to need to ask them to install 'GD' for you.
If you're on a VPS, you'll have to do it yourself, just Google 'how to install GD on <insert OS name here>'.
Or, if you're using locally hosted software, you're going to need to find some kind of plugin for GD.

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 1:34 pm
by olliekb
I can do that now I have full access to the whole server XD

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 1:43 pm
by olliekb
Thanks that sorta worked now it doesn't display the skin. Not actually downloading. ive checked in the directory and there is nothing in there.!!!
http://oliverbell.co.uk/mcrendering.php

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 1:55 pm
by Helx
What have you set the username to?
Remember that case matters.

Eg:
http://skins.minecraft.net/MinecraftSkins/abcedea.png
Is not the same as
http://skins.minecraft.net/MinecraftSkins/Abcedea.png

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 1:56 pm
by olliekb
Tested the the variable by putting Blacksmith95 and I also type the address in a browser to test it worked.

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 2:12 pm
by Helx
Alright.

Take a look at line 7 of the code. You need to create folders like that in the same directory as the script.
Have you done that?

Script.php
cache
-player_skins
--faces

Also be sure to CHMOD the folder to 777 (it's not normally an issue with this script, but I guess it's still possible).

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 2:19 pm
by olliekb
chmod the cache file right?

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 2:21 pm
by Helx
Yes, CHMOD the folder 'cache' recursively to 777.

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 2:22 pm
by olliekb
right did that now ive got a black square XD

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 2:26 pm
by Helx
Alright, that's odd.

Remove the header thing on line one, and put the following code just below the PHP opening tags:

[syntax=php]error_reporting(E_ALL);
ini_set('display_errors', '1');[/syntax]
Paste any errors :)

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 2:32 pm
by olliekb
‰PNG  IHDRÈÈ":9ÉŠIDATxœíÁ‚ ÿ¯nH@ð`Õ—½¬¡IEND®B`‚

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 3:42 pm
by olliekb
any idea ?

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 5:09 pm
by FrederickGeek8
Thats PNG code :lol:

Try removing the cache file. If you got a bad copy due to some error or something, it would remain in your cache and output the same each time.

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 5:20 pm
by olliekb
Right I got it working somehow : http://oliverbell.co.uk/mcrendering.php ... acksmith95
added an include statment to pull the code onto another php page and it stops working again!!!
chmod is done gd is installed cache files are there. But no picture just a little icon.
see : http://eternitypvp.co.uk/profile.php?ign=Blacksmith95

Re: Minecraft Player Face Rendering problem

Posted: Sat Jun 29, 2013 9:51 pm
by FrederickGeek8
olliekb wrote:Right I got it working somehow : http://oliverbell.co.uk/mcrendering.php ... acksmith95
added an include statment to pull the code onto another php page and it stops working again!!!
chmod is done gd is installed cache files are there. But no picture just a little icon.
see : http://eternitypvp.co.uk/profile.php?ign=Blacksmith95

You could just use a img tag to like to the mcrendering page or use file_get_contents. There is really no need for including imo.