diff options
| author | Simon Robertshaw <simon@hardwired.org.uk> | 2012-01-26 01:13:33 (GMT) |
|---|---|---|
| committer | Simon Robertshaw <simon@hardwired.org.uk> | 2012-01-26 01:13:33 (GMT) |
| commit | 9e1be78bc21d1fb76a19ce12ef36193aea6e2b93 (patch) | |
| tree | 081b67d551bb44fecbf6deb99b6c44ea9789614c /src/client/Client.cpp | |
| parent | b2d3257ae944a3ea3b57dc8ee4171b1b2f85483e (diff) | |
| download | powder-9e1be78bc21d1fb76a19ce12ef36193aea6e2b93.zip powder-9e1be78bc21d1fb76a19ce12ef36193aea6e2b93.tar.gz | |
I've got to a point where I can no longer be bothered to think of a proper commit comment
Diffstat (limited to 'src/client/Client.cpp')
| -rw-r--r-- | src/client/Client.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/client/Client.cpp b/src/client/Client.cpp index b6fe2a4..ad12da4 100644 --- a/src/client/Client.cpp +++ b/src/client/Client.cpp @@ -40,6 +40,12 @@ Client::~Client() http_done(); } +unsigned char * Client::GetSaveData(int saveID, int saveDate, int & dataLength) +{ + dataLength = 0; + return NULL; +} + LoginStatus Client::Login(string username, string password, User & user) { lastError = ""; @@ -140,16 +146,16 @@ Save * Client::GetSave(int saveID, int saveDate) json::String tempUsername = objDocument["Username"]; json::String tempName = objDocument["Name"]; json::String tempDescription = objDocument["Description"]; - json::String tempDate = objDocument["Date"]; + json::Number tempDate = objDocument["Date"]; json::Boolean tempPublished = objDocument["Published"]; return new Save( tempID.Value(), + tempDate.Value(), tempScoreUp.Value(), tempScoreDown.Value(), tempUsername.Value(), tempName.Value(), tempDescription.Value(), - tempDate.Value(), tempPublished.Value() ); } @@ -241,6 +247,7 @@ std::vector<Save*> * Client::SearchSaves(int start, int count, string query, str for(int j = 0; j < savesArray.Size(); j++) { json::Number tempID = savesArray[j]["ID"]; + json::Number tempDate = savesArray[j]["Date"]; json::Number tempScoreUp = savesArray[j]["ScoreUp"]; json::Number tempScoreDown = savesArray[j]["ScoreDown"]; json::String tempUsername = savesArray[j]["Username"]; @@ -248,6 +255,7 @@ std::vector<Save*> * Client::SearchSaves(int start, int count, string query, str saveArray->push_back( new Save( tempID.Value(), + tempDate.Value(), tempScoreUp.Value(), tempScoreDown.Value(), tempUsername.Value(), |
