Permalink
Browse files

Add img and sound shortcut methods to the scene class.

  • Loading branch information...
1 parent 097e191 commit 9a01665118ebc65c1fa79a350f48b35db5e7f9ef @jverkoey committed Feb 27, 2010
Showing with 8 additions and 0 deletions.
  1. +8 −0 dev/engine/class.scene.js
@@ -110,6 +110,14 @@ Breeze.Engine.Scene.prototype.stopScene = function() {
this.timeout_ = null;
};
+Breeze.Engine.Scene.prototype.img = function(key) {
+ return this.textureCache_.getTexture(key).getImage();
+};
+
+Breeze.Engine.Scene.prototype.sound = function(key) {
+ return this.soundCache_.getSound(key);
+};
+
/**
* Draw a layered scene.
*/

0 comments on commit 9a01665

Please sign in to comment.