Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

If you want a function that’s only used in an event, you can define it as var example_2 = function() {}.

If you want a function that’s not only used in an event, you should probably put it in Create as a function will only be assigned to an instance variable once that event runs, and will be re-assigned each time it runs.

If you are trying to split up a big Create event, consider #region or @interface + @implements JSDocs.