Add _emscripten_set_main_loop to EMCC_EXPORT

This commit is contained in:
Milan Nikolic 2017-12-09 18:18:56 +01:00
parent da8f828e2d
commit f0ea8218a7
3 changed files with 7 additions and 12 deletions

View file

@ -20,8 +20,7 @@ func SetCallbackFunc(func(unsafe.Pointer)) {
// SetMainLoop - Sets main loop function
func SetMainLoop(fn func(), fps int, infinite bool) {
js.Global.Set("_go_update_function", fn)
js.Global.Get("Module").Call("_emscripten_set_main_loop_go", fps, infinite)
js.Global.Get("Module").Call("_emscripten_set_main_loop", fn, fps, infinite)
}
// ShowCursor - Shows cursor