Created
July 11, 2015 20:46
-
-
Save JoshEngebretson/f90dbcc9a2f2dd18cc33 to your computer and use it in GitHub Desktop.
CommonJS compatible components
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// CommonJS compatible components | |
"use strict"; | |
"atomic component"; | |
exports.component = function(self) { | |
var game = Atomic.game; | |
var node = self.node; | |
self.start = function() { | |
var water = node.getComponent("StaticModel"); | |
water.material = game.cache.getResource("Material", "Materials/Water.xml"); | |
} | |
self.update = function(timeStep) { | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment