Browse Source

Merge remote-tracking branch 'origin/master'

master
Unknown 6 years ago
parent
commit
ed9714bab5
3 changed files with 6 additions and 3 deletions
  1. +1
    -0
      README.md
  2. +3
    -3
      googletrendsgame/server/server.js
  3. +2
    -0
      googletrendsgame/server/trendsAPI.js

+ 1
- 0
README.md View File

@ -15,6 +15,7 @@ npm install mysql
npm install sanitizer
npm install google-trends-api
npm install promise
npm install async
````
##Database Construction

+ 3
- 3
googletrendsgame/server/server.js View File

@ -122,7 +122,7 @@ var room = function(capacityP, pass, owner)
var message = this.generateRoomUpdate();
this.users.forEach(function(u)
{
console.log("room update called");
//console.log("room update called");
u.socket.emit('roomUpdate', message);
//console.log(message);
});
@ -135,7 +135,7 @@ var room = function(capacityP, pass, owner)
*/
this.addUser = function(player)
{
console.log("user added");
//console.log("user added");
//check if room is not full
this.users.push(player);
player.room = this;
@ -489,7 +489,7 @@ io.on('connection', function(socket)
*/
socket.on('joinRoom', function(data)
{
console.log(p.name + " joined room " + data.name);
console.log(p.name + " joined room " + data.roomName);
if(rooms[data.roomName] != null && rooms[data.roomName].canJoin(data.password))

+ 2
- 0
googletrendsgame/server/trendsAPI.js View File

@ -72,6 +72,7 @@ module.exports=
desc: returns a list of tuples (date, value) representing word's
popularity for the past year
*/
/*
getYearStats: async function(word){
var ret = [];
@ -84,5 +85,6 @@ module.exports=
return ret;
}
*/
};

Loading…
Cancel
Save