fogleman / Craft

A simple Minecraft clone written in C using modern OpenGL (shaders).
http://www.michaelfogleman.com/craft/
MIT License
10.44k stars 1.39k forks source link

Server Doesn't Work #162

Closed ghost closed 9 years ago

ghost commented 9 years ago

Traceback (most recent call last): File "server.py", line 2, in from world import World File "/Users/Pixel/Desktop/Craft-1.0/world.py", line 7, in dll = CDLL('./world') File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ctypes/init.py", line 365, in init self._handle = _dlopen(self._name, mode) OSError: dlopen(./world, 6): image not found

I am on OS X with Python 2.7.7.

ghost commented 9 years ago

It does work with Python 3 either;

File "server.py", line 59 print line ^ SyntaxError: Missing parentheses in call to 'print'

wenLiangcan commented 9 years ago

You should build the world file first and then run server.py with Python 2, this is described in README

gcc -std=c99 -O3 -fPIC -shared -o world -I src -I deps/noise deps/noise/noise.c src/world.c
ghost commented 9 years ago

Ahh, thanks. That worked.

However, a different error is now displayed.

Traceback (most recent call last): File "server.py", line 8, in import requests ImportError: No module named requests

This is executed from the root directory of the project.

wenLiangcan commented 9 years ago

The script requires the Python module requests. You can do a search for how to install Python module on your system.

ghost commented 9 years ago

Oh, I see! Well, this is working perfectly now. I love the project. Thanks very much!