summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--public/css/drawdrawdraw.css17
-rw-r--r--server.js4
2 files changed, 18 insertions, 3 deletions
diff --git a/public/css/drawdrawdraw.css b/public/css/drawdrawdraw.css
index 6d2ed12..0a33b61 100644
--- a/public/css/drawdrawdraw.css
+++ b/public/css/drawdrawdraw.css
@@ -55,4 +55,19 @@ body {
}
#image {
display: none;
-} \ No newline at end of file
+}
+
+#voting {
+ position: absolute;
+ left: 400px;
+ top: 50px;
+}
+#voting li {
+ list-style-type: none;
+}
+
+#winning {
+ position: absolute;
+ left: 400px;
+ top: 50px;
+}
diff --git a/server.js b/server.js
index 87a3da4..f5170c1 100644
--- a/server.js
+++ b/server.js
@@ -129,9 +129,9 @@ Channel.prototype.setTimeout = function( callback, delay ){
// Someone joined/left, so either start a game or stop it.
Channel.prototype.checkState = function(){
if ( this.hasEnoughPlayers() ) {
- if (this.state <= State.WAITING) this.startDrawing();
+ if (this.state <= State.WAITING) this.setTimeout( this.startDrawing, 2000);
}
- else if (this.state > State.WAITING) this.startWaiting();
+ else if (this.state > State.WAITING) this.setTimeout( this.startWaiting, 2000);
}
Channel.prototype.hasEnoughPlayers = function(){
var count = 0;