Skip to content
Snippets Groups Projects
Commit 3f62f300 authored by Eric Rosenbaum's avatar Eric Rosenbaum Committed by GitHub
Browse files

Merge pull request #33 from ericrosenbaum/master

add audio engine
parents 175b4d77 2dd8c55b
No related branches found
No related tags found
No related merge requests found
......@@ -54,6 +54,7 @@
"react-redux": "4.4.6",
"react-style-proptype": "1.2.0",
"redux": "3.6.0",
"scratch-audio": "latest",
"scratch-blocks": "latest",
"scratch-render": "latest",
"scratch-vm": "latest",
......
const bindAll = require('lodash.bindall');
const React = require('react');
const Renderer = require('scratch-render');
const AudioEngine = require('scratch-audio');
const VM = require('scratch-vm');
const StageComponent = require('../components/stage/stage.jsx');
......@@ -20,6 +21,8 @@ class Stage extends React.Component {
componentDidMount () {
this.renderer = new Renderer(this.canvas);
this.props.vm.attachRenderer(this.renderer);
this.audioEngine = new AudioEngine();
this.props.vm.attachAudioEngine(this.audioEngine);
this.attachMouseEvents(this.canvas);
}
componentWillUnmount () {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment