Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add screen orientation checker and improve title screen centering for 3D Car Coin Hunt #724

Merged
merged 3 commits into from
Nov 5, 2024

Conversation

4ian
Copy link
Contributor

@4ian 4ian commented Nov 5, 2024

No description provided.

Copy link
Contributor

github-actions bot commented Nov 5, 2024

Preview the game(s) changed or added in this Pull Request


This is an automatic message displaying links to the games in this PR - double check the JSON in case of doubt.

Copy link
Contributor

github-actions bot commented Nov 5, 2024

Images automagically compressed by Calibre's image-actions

Compression reduced images by 26.3%, saving 7.44 KB.

Filename Before After Improvement Visual comparison
examples/3d-car-coin-hunt/assets/Orange Bubble Button_Hovered.png 8.98 KB 6.79 KB -24.3% View diff
examples/3d-car-coin-hunt/assets/Orange Bubble Button_Idle.png 8.95 KB 6.52 KB -27.1% View diff
examples/3d-car-coin-hunt/assets/Orange Bubble Button_Pressed.png 8.90 KB 6.40 KB -28.1% View diff
examples/3d-car-coin-hunt/assets/rotate-screen-icon.png 1.47 KB 1.14 KB -22.5% View diff

6020 images did not require optimisation.

Comment on lines +4437 to +4439
"const orientation = runtimeScene.getGame().getGameData().properties.orientation;",
"",
"eventsFunctionContext.globalVariablesForExtension.get(\"TargetOrientation\").setString(orientation);"
Copy link
Contributor

@D8H D8H Nov 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not define a private expression for it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm thinking that in the future we could have an action to force a specific orientation - to override what is in the game (because some games might want to change orientation according to the scene... even if unlikely).

examples/3d-car-coin-hunt/3d-car-coin-hunt.json Outdated Show resolved Hide resolved
@4ian 4ian force-pushed the feat/screen-orientation-checker branch from cd07402 to bf55f19 Compare November 5, 2024 15:52
Copy link
Contributor

github-actions bot commented Nov 5, 2024

Images automagically compressed by Calibre's image-actions

Compression reduced images by 26.3%, saving 7.44 KB.

Filename Before After Improvement Visual comparison
examples/3d-car-coin-hunt/assets/Orange Bubble Button_Hovered.png 8.98 KB 6.79 KB -24.3% View diff
examples/3d-car-coin-hunt/assets/Orange Bubble Button_Idle.png 8.95 KB 6.52 KB -27.1% View diff
examples/3d-car-coin-hunt/assets/Orange Bubble Button_Pressed.png 8.90 KB 6.40 KB -28.1% View diff
examples/3d-car-coin-hunt/assets/rotate-screen-icon.png 1.47 KB 1.14 KB -22.5% View diff

6020 images did not require optimisation.

@4ian 4ian merged commit 16c2315 into main Nov 5, 2024
3 checks passed
@4ian 4ian deleted the feat/screen-orientation-checker branch November 5, 2024 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants