Commits

Jérémie Ducastel committed f706c30 Draft

project layout in separate apps :

- "players" for pure player-related views, register, login, settings
- "game" for game models etc (may be used later to implement a full game server)
- "web" for web interface, challenge issuing, game management etc

+ docs/index.rst with a short roadmap

  • Participants
  • Parent commits a889c4d

Comments (0)

Files changed (11)

+=====================================
+LSN REVIVAL - COMMUNITY WEB INTERFACE
+=====================================
+
+This project intends as a community web interface for Laser Squad Nemesis,
+as a iterative replacement for official facilities now offline.
+
+It is build on the "hacky server" at http://gitorious.org/lsnd used for
+turn results computing. It is further named as LSND.
+
+ROADMAP
+=======
+
+1 - Players address book
+------------------------
+
+The first step is to allow players to register themselves in the players list,
+then provide them a challenge creation form.
+
+2 - Game management
+-------------------
+
+The second step is to serve as game interface between players and LSND_,
+by forwarding emails from players to LSND_ and reciprocally. It would allow :
+
+- to move from a LSND_ instance to another, or to have more than 1 instance
+- to keep track of games played and offer an interface for game management to players.
+
+3 - Games Archive
+--------------------
+
+- allow to upload / download game replays, links to screenshots and videos etc
+
+4 - Tournaments etc
+-------------------
+
+
+.. _LSND:
+
+"hacky server" at http://gitorious.org/lsnd
+# -*- coding: utf-8 -*-
+"""
+
+"""
+##
+# @author J.Ducastel <nospam0@ducastel.name>
+
+# imports
+from google.appengine.ext import ndb
+from google.appengine.api import users as gusers
+
+# exceptions
+
+# class et fonctions
+class Challenge(ndb.Model):
+    """ challenges issued, may be refused """
+
+
+class Map(ndb.Model):
+    """ for map selection in challenges """
+
+#end

players/__init__.py

Empty file added.
+# -*- coding: utf-8 -*-
+"""
+
+"""
+##
+# @author J.Ducastel <nospam0@ducastel.name>
+
+# imports
+from django import forms
+
+# exceptions
+
+# class et fonctions
+class RegisterForm(forms.Form):
+    """ player creation / registering form """
+
+
+class LoginForm(forms.Form):
+    """ player login form """
+
+
+class PlayerSettingsForm(forms.Form):
+    """ allows a player to change her settings """
+
+#end

players/models.py

+# -*- coding: utf-8 -*-
+"""
+
+"""
+##
+# @author J.Ducastel <nospam0@ducastel.name>
+
+# imports
+from google.appengine.ext import ndb
+from google.appengine.api import users as gusers
+
+# exceptions
+
+# class et fonctions
+# extend users.User ?
+class Player(ndb.Model):
+    """ an LSN player """
+
+    email = ndb.StringProperty(required=True)
+    lsn_nickname = ndb.StringProperty(required=True)
+    password = ndb.StringProperty(required=True, indexed=False)
+    # avatars etc
+    # challenges related fields
+    # how many challenges accepted at a time ?
+    accept_challenges = ndb.IntegerProperty(default=1)
+    accept_random_challenges = ndb.BooleanProperty(default=False)
+
+#end

players/tests/__init__.py

Empty file added.

players/tests/login.py

+# -*- coding: utf-8 -*-
+"""
+
+"""
+##
+# @author J.Ducastel <nospam0@ducastel.name>
+
+# imports
+
+# exceptions
+
+# class et fonctions
+
+#end

players/tests/registering.py

+# -*- coding: utf-8 -*-
+"""
+
+"""
+##
+# @author J.Ducastel <nospam0@ducastel.name>
+
+# imports
+
+# exceptions
+
+# class et fonctions
+
+#end
+# -*- coding: utf-8 -*-
+"""
+
+"""
+##
+# @author J.Ducastel <nospam0@ducastel.name>
+
+# imports
+
+# exceptions
+
+# class et fonctions
+
+#end
+# -*- coding: utf-8 -*-
+"""
+pure player-related views
+"""
+##
+# @author J.Ducastel <nospam0@ducastel.name>
+
+# imports
+
+# exceptions
+
+# class et fonctions
+
+def register(request):
+    """ player creation / registering """
+
+def login(request):
+    """ player log in """
+
+def logout(request):
+    """ player log out """
+
+def settings(request):
+    """ player editing his settings """
+
+#end
     return render_to_response('index.html',
         RequestContext(request, locals()))
 
+def player_home(request):
+    """ player home when logged """
+    # challenge form ?
+
+def players(request):
+    """ players list """
+
 def lsn_file_upload(request):
     if request.POST:
         form = LSNFileUploadForm(request.POST)