changeset 345:04bb1ffcd054

Activated ctpug level server.
author Simon Cross <hodgestar@gmail.com>
date Fri, 16 Sep 2011 23:00:25 +0200
parents 214b2bd173a8
children c2f7920563e4
files mamba/constants.py mamba/habitats/userlevelmenu.py
diffstat 2 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mamba/constants.py	Fri Sep 16 22:29:48 2011 +0200
+++ b/mamba/constants.py	Fri Sep 16 23:00:25 2011 +0200
@@ -8,6 +8,7 @@
 # Miscellaneous constants
 NAME = "Unamed Mamba game"
 FPS = 60
+LEVEL_SERVER = "http://ctpug.org.za/mamba/"
 
 # Sound constants
 FREQ = 44100   # same as audio CD
--- a/mamba/habitats/userlevelmenu.py	Fri Sep 16 22:29:48 2011 +0200
+++ b/mamba/habitats/userlevelmenu.py	Fri Sep 16 23:00:25 2011 +0200
@@ -2,19 +2,21 @@
 
 from mamba.habitats.levelmenu import LevelMenu
 from mamba.level import Level
+from mamba.constants import LEVEL_SERVER
 
 import urllib2
 
 
 class UserLevelMenu(LevelMenu):
 
-    LEVEL_SERVER_URL = "http://localhost:5000/curated/"
+    LEVEL_SERVER_URL = LEVEL_SERVER + "curated/"
     TIMEOUT = 5.0  # in seconds
     CACHE = {}
 
     @classmethod
     def _url_data(cls, route):
         url = "%s%s" % (cls.LEVEL_SERVER_URL, route)
+        print url
         return urllib2.urlopen(url, timeout=cls.TIMEOUT).read()
 
     @classmethod