I have made a server for a game I am making, and it generates a map for me, but on this test client I am making, it’s not working correctly.
I add the site as a script, and it’s working fine as a script, but when the javascript on jsfiddle is read, it says that the function callback() is not define, but it clearly is, and it should be sending the map object to the console, but it’s just erroring out… :/
Here’s the link to the JS Fiddle:
http://jsfiddle.net/Tgwizman/9QrUF/
I hope you guys can figure it out, because I’m totally lost as to why it isn’t working…
In your jsfiddle the javascript callback function is defined after you loaded the map with your javascript include, and at that point your callback is not yet defined.
Here is a fixed fiddle.
Example source: