blessed-life
Advanced tools
Comparing version 1.1.1 to 1.1.2
@@ -123,10 +123,15 @@ #!/usr/bin/env node | ||
value = value.split(','); | ||
var x = parseInt(value[0]); | ||
var y = parseInt(value[1]); | ||
if (app.game.board.isInBounds(x, y)) { | ||
app.game.board.toggleCell(x, y); | ||
if (value !== null) { | ||
value = value.split(/,|;/); | ||
for (var i = 0; i < value.length / 2; i++) { | ||
var x = parseInt(value[i * 2]); | ||
var y = parseInt(value[(i * 2) + 1]); | ||
if (app.game.board.isInBounds(x, y)) { | ||
app.game.board.toggleCell(x, y); | ||
} | ||
} | ||
box.setContent(app.renderBoard()); | ||
} | ||
screen.render(); | ||
@@ -133,0 +138,0 @@ }); |
{ | ||
"name": "blessed-life", | ||
"version": "1.1.1", | ||
"version": "1.1.2", | ||
"description": "A simple game of life simulation using the blessed node module.", | ||
@@ -5,0 +5,0 @@ "keywords": ["game", "life", "conway", "simulation", "blessed"], |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
10640
366