About application exiting

  • I tried to make a menu with "Exit" entry and seeked for how to quit the game safely until finally I found openfl.Lib.close().
    However I didn't find the definition of close() in openfl.Lib and VSCode couldn't recognize this method and marked it as an error,though it's successfully compiled and worked properly.

    Then how did it work?

  • Was this compiling to flash, or compiling to windows? As far as I've seen, OpenFL is incredibly glitchy when compiling to .exe. (...and seems somewhat buggy in general, but that may just be my experience.)

    ...either way, it works I guess... juuuust don't poke it.

  • administrators

    Flixel's VSCode setup defaults to the Flash completion configuration, and this method doesn't exist on Flash. Try switching it to Windows, Linux or Mac depending on what you're on (there's a dropdown in the status bar).

Log in to reply

Looks like your connection to HaxeFlixel was lost, please wait while we try to reconnect.