Card Stories - Developer Documentation
From Farsides Wiki
Contents |
[edit] Introduction
The code base uses Twisted/Python and JQuery. The user interface part is JavaScript only, using a JSON based REST webservice.
The following documentation is based on the work and the blog posts of Loic Dachary.
[edit] Documents
- Introduction
- Webservice documentation
- Plugin system - Webservice
- Client documentation
- Authentication and Users
- General developer reference
[edit] Download
git clone git://gitorious.org/cardstories/cardstories.git
[edit] Development tips
If you want to simulate a game with several fake users from the same browser, use the "auth" plugin instead of "djangoplugin", which removes the authentification check and allow you to do the following:
- On your server, for example localhost:8080/static/index.html, create a new game as an author, and play until step 3 where you invite friends
- Invite some imaginary friends, let’s say 1, 2 and 3
- Then in the browser, create 3 new tabs with the following url : http://localhost:8080/static/index.html?player_id=1, http://localhost:8080/static/index.html?player_id=2, http://localhost:8080/static/index.html?player_id=3
- Then you can play at the same time as the author and a the three players and finish the game
See also the ?skin views to load a specific view of the game interface, without having to navigate to the page through the normal game workflow.
[edit] Licensing
The license chosen for the code is the GNU AFFERO GENERAL PUBLIC LICENSE and the license for the artwork is the Attribution-ShareAlike 3.0