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

Game_Browser - Autorun a specific game #3133

Merged

Conversation

jetrotal
Copy link
Contributor

@jetrotal jetrotal commented Oct 26, 2023

If a game filename contains gamedata.easyrpg and there's only one game in player's folder, the player will autorun it.
image image image image
image

It would be better if I could skip the game_browser scene or hide the screen with default system. But this is working fine.

If a game file ends with `.easyrpg` and there's only one game in the folder, the player will autorun it.
@Ghabry
Copy link
Member

Ghabry commented Oct 26, 2023

Honestly I do not see the usecase for this. You could just distribute your Windows game with a shortcut that passes --project-path mygame.zip to the Player similiar to how some other games do it (the ones by vgperson all have such a launcher).

This is Windows specific because on Linux you usually distribute a desktop file with the launch options and on macOS you would simply put it inside the application (which is actually a folder).

If you really want a standalone mode for Windows I would suggest an approach that embeds the game into the exe, e.g. create a new resource entry EASYRPG and under this entry a resource GAME that contains the game as e.g. as a ZIP. (Note: As this is windows specific it could use the Windows API instead of our hacky EXEReader)

@fdelapena
Copy link
Contributor

fdelapena commented Nov 20, 2023

A problem with Windows shortcuts is, they are harder than expected to create them containing relative paths. If absolute, a usual breaking case happens when the user moves the game folder somewhere else. "Portable" apps are quite common as well, and drive letters change often.

Exe embedding is nice but they trigger low quality antivirus heuristics due to the hacky PE stuff that makes it work.

Despite this is mostly a Windows specific solution, this patch looks simple enough and harmless behaviour on other platforms compared to implement Windows specific code.

@fdelapena fdelapena added UX For issues affecting the user experience, such annoyances, counter-intuitive or ugly design Enhancement labels Nov 20, 2023
@Ghabry Ghabry added this to the 0.8.1 milestone Nov 20, 2023
@Ghabry
Copy link
Member

Ghabry commented Nov 20, 2023

okay, fine. Lets add this. But I will do some small UX improvements before: :)

  • The autoboot should also work in the Logo scene
  • Maybe relax the name requirement a bit? E.g. "Must end on .easyrpg" and the part in front of it doesn't matter.

@Ghabry Ghabry force-pushed the Game_Browser-AutorunGame branch 2 times, most recently from 6533162 to dfbc19e Compare December 5, 2023 18:18
@Ghabry
Copy link
Member

Ghabry commented Dec 5, 2023

Relaxed it a bit and made it work from the logo scene: The player will now autorun a game if it is the only game in the directory and ends on .easyrpg. Does not matter if folder or (zip) archive.

@jetrotal
Copy link
Contributor Author

image
Testing this fake 3D game with the memory leak PR, looks like it went from unplayable to very laggy...
Link to it:
https://biloumaster.fr/download/[BConcept]-Vaisseau3D.zip

It has a version optimized for easyRPG too,
but it may be interesting to check the rm2k3 one.

@Ghabry
Copy link
Member

Ghabry commented Dec 22, 2023

With very very agressive caching (never delete it) I can even reach 166 FPS (refresh rate of my display) but it needs 10 GB of RAM xD. Though the blend effect will still frame drop because it causes a cache miss.

Guess the issue is similiar to Aedemphia: Lots of tone blit effects that are not efficient to do on 32 bit graphics without GPU support compared to the simple palette editing 8 bit can do.

@fdelapena fdelapena merged commit af03ab5 into EasyRPG:master Dec 23, 2023
12 checks passed
@jetrotal jetrotal deleted the Game_Browser-AutorunGame branch August 4, 2024 23:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement UX For issues affecting the user experience, such annoyances, counter-intuitive or ugly design
Development

Successfully merging this pull request may close these issues.

3 participants