Closed UlisesFreitas closed 3 years ago
Thank you, added in https://github.com/GDevelopApp/GDevelop-extensions/commit/d4cf5a759942051a52e550250af0959582cc04cb !
I've made a change to the JS Events, we prefer using the GDJS API.
Before:
eventsFunctionContext.returnValue= gdjs.projectData.properties.version;
After:
eventsFunctionContext.returnValue = runtimeScene.getGame().getGameData().properties.version;
Nit: Format is an option in the context menu in a JS event, we use it for cleaning and format the source code .
Tests: Ok Registry file: Updated
Hi I don't know how to update the username on the extension so here the extension with my username added as the author CurrentGameVersion.zip
Description
I made this simple extension since some users ask this in the forum https://forum.gdevelop-app.com/t/game-version-to-variable/26120 https://forum.gdevelop-app.com/t/is-there-a-way-to-check-the-game-version-in-a-variable/32317
A simple extension string expression that returns the current version number the user set in Game settings->Properties
How to use the extension
Checklist
Example
gd-project-CurrentGameVersion-1.0.0.zip
Extension file
ReturnGameVersion.zip