added an import to the yaml file to fix a console logging error, changed game to begin incorporating the ajax handling, added some test ajax to the template file
minor change to game handler
fixed the error 500 issue- the test json in the code wasn't actually valid json, so it was unable to be processed by json.dumps. I am now passing valid json in and out, looks ok. Next will add some real functionality
ok, added the current state as the data parameter in the ajax request (had to call stringify on it first). looks like it is working. will add the actual handlers for at least one state tomorrow
fixed issue with rendering (render call wasn't getting executed because it was in the test function
Added a small bit of testing to game.py to test ajax responses from javascript, adding in ajax requests
temp
merging proper JSON on the python side with ajax in javascript
Removed test code and fixed javascript ajax posting
Merge branch 'model' into gameRender
Interesting click stacking is going on. commiting so phelan can pull and debug it with me
fixed the game handler so that the initial discard card is actually a card, not empty. This card is selected such that it is not a power card
fixed a mis-named variable.
Added several pieces of server side functionality in game.py: the post method now correctly executes the procedure for handling ajax calls from the view. a new parseState function determines what the state is of the game that has been passed in by the posted ajax. a new waitingForDraw method handles the state of the same name. NOTE: i've added a new kv pair in the json, to record what clicks the user actually made (stateChanges.js has also been modified accordingly). I also think we'll need to have a new state to handle the end of a round occuring (IE when the deck runs out, etc)
added shell classes for other handlers in game.py
fixed an issue where the initial discard card was showing up only as 0,1, or 2
updated some commenting in game.py
still messing around trying to make javascript ajax responsesnot fire off multiple times
Fixed up ajax calls in stateChanges
Got a basic transition between states working. Note that the test code on line 51 of game.py should be taken our and replaced with a call to the server side state handling