maxogden/voxel-hello-world — pull request #20 by theoxylo (2013-03-19 23:30:38+00:00)
Title: now passing highlightOpts from game opts to voxel-highlight

now hello-world clients like test.js can pass highlight options along with other game options, like this:

var opts = {
highlightOpts: {
color: 0xffff00,
distance: 100,
animate: true
},
generate: function (x, y, z) {
return y % 16 ? 0 : Math.ceil(Math.random() * 2)
}
}

var game = require('voxel-hello-world')(opts)