The tool we are creating operates outside of the game we have been working on for several chapters now. Because of this, we are working on a new HTML shell file, and we will be writing a lot of JavaScript to integrate our user interface with the WebAssembly classes we will drop into our game later. Let's take the time to walk through all of the JavaScript functions we will need to add to our new HTML shell file.
Modifying the JavaScript
The JavaScript UpdateClick function
After we have modified the HTML, the next thing we need to do is modify the UpdateClick() JavaScript function to allow it to grab the new values out of the HTML elements and pass those values into the Module.ccall function call to update_emitter.
Here...