Godot version:
3.0.2 (steam)
OS/device including version:
Windows 10
Issue description:
Steam can't log correctly the time spent on Godot. It stops logging the time after you start a project, i guess because it spawns a new process. This also happened in godot 2.
I would like to see this fixed, since i like to know how much time i spend on things.
I found the same issue discussed on steam forums, I even read that this was going to get fixed in godot 3.0 but ofc it's not.
Related discussions:
For anyone who wants to investigate, it seems to work fine on Linux, Steam manages to follow the process forking when opening a project from the project manager. But Windows doesn't seem to handle it (at least Windows 10 - there are reports of it working fine on Windows 7), and some OSX users seem to experience the issue too.
yeah I'd really love if this was fixed somehow ...
here's a link to a comment on steam summing it up:
https://steamcommunity.com/app/404790/discussions/0/412448158161884844/?ctp=2#c3211505894119922106
I am currently launching second project editor just to log the time, which does not feel very right and also I sometimes forget to do so. I really hope this is going to be fixed some time soon.
It does not work fine on Windows 7. It only tracks time at the project management window. When opening a project it does not track, and Steam does not show as in "Godot Engine".
Would like to see this fixed. Time tracking is a big part of why I used Steam for the distribution.
Couldn't a simple fix be that Steam logs time in the console that is constantly open when engine is running?
Yeah, that should be done as @wingedadventurer said.
I experience this issue on Linux when starting Godot with a .desktop
file that shows the terminal. My goal was to be able to keep the terminal open to read error messages if the engine crashes, so I launched Godot with the following .desktop
file:
[Desktop Entry]
Version=1.0
Type=Application
Name=Godot 3.0 Bad
Icon=/home/aaronfranke/Documents/Godot/icon.png
Exec=sh -c "/home/aaronfranke/Documents/Godot/3.0/Godot; sleep 5"
Categories=Game;Development;Godot;
Terminal=true
This causes the editor to instantly close 5 seconds after I open a project.
I have made a duplicate of this issue, probably because I have searched for the keywords "Steam" and "hour", not "time". Sorry, for that.
What I will probably do myself to solve this problem is to make a small wrapper that starts Godot, replace the Godot Steam binary with this wrapper, which waits until there is no Godot binary running for 10 seconds, then exits.
Also, I thought this bug was fixed already. I remember it working correctly before 3.1, but that's just probably my brain being messed up.
@reduz @akien-mga
Still not counting in v3.1 stable on Windows 10.
I have created the wrapper for my personal needs, but in case someone else needs it too, I have uploaded it here:
https://github.com/UnleavenedEagle/SimpleWrapperLauncher/
I would really love to see this fixed. Coming up on a year now with no action.
Thanks for the work around, @UnleavenedEagle !
Given that people finding this on steam will only see people with 3-4 hours at max (even though those people may have spend thousands of hours in the engine), this may actual affect potential users. When I first read through the reviews I was confused why exactly nobody on steam used Godot for more than a few hours.
That's a good point, @tumGER. I have managed to actually log time with @UnleavenedEagle's fix, so hopefully that will encourage the devs to make this change.
It seems to work for me on Ubuntu 19.10. I have 113 hours clocked.
However, I agree that it would be nice to get this fixed across the board, since it could have an influence on new users reading reviews (as your play time is shown when you write a review).
Also, I notice that there are several games on Steam that use launchers (like GTA5, Tomb Raider, etc.) so there must be a way they are doing it, since those games do track time correctly.
Found a workaround for Windows:
https://steamcommunity.com/sharedfiles/filedetails/?id=1970276543
To add to this, now that 3.2 has launched, you now have an option to hide the console window in the editor settings (console still starts but gets hidden a couple seconds after Godot launches). Not sure whether this breaks some of the workarounds that make Steam track the console window instead of the project manager window.
But yeah, this is getting ridiculous now. A big portion of the overall engine downloads probably comes from Steam because of how nice and convenient it is. This HAS to be fixed, it's trailing along almost two years now. I've probably spent hundreds of hours working in this given that I seemingly spent 14 hours in the project manager alone, which usually stays open for about a second. Tracking time is a big part of the Steam experience which is marred because of something seemingly easy to fix.
@Rriik We're still looking for someone to propose a workaround we can integrate without any downsides or quirks :slightly_smiling_face:
If it can't be submitted via a pull request, please write a comment describing all the required steps here and Akien will take a look.
@Rriik My method is still working. I'm not sure about @viteo's method, but I've tried it out before, and there was a little flaw with it, that is it didn't exit the wrapper console after Godot has been closed, you had to close it manually and if you didn't close it, it would keep running even after Godot exited.
@Calinou When you start Godot via Steam, it launches Godot with the arguments "C:\Program Files (x86)\Steam\steamapps\common\Godot Engine\godot.windows.opt.tools.64.exe" --path %USERPROFILE% -p
. When selecting the project, Godot will start a new Godot process with the arguments "C:\Program Files (x86)\Steam\steamapps\common\Godot Engine\godot.windows.opt.tools.64.exe" "--path" "C:/MyGodotProject" "--editor0"
, and exits the first process. As the original process exits, Steam assumes that the application has exited. This is the cause of the problem.
You can solve this by letting the first process only exit when the second process exits, and only exiting the project list window and not the process after selecting a project.
@UnleavenedEagle This would require a significant rework to keep the project manager process running after a project was opened. Also, remember that you can go back to the project manager while a project is open by using Project > Quit to Project List. In this case, what would happen to the running project manager process with the hidden window? In theory, it could be shown again, but we need some way to signal this to the hidden window from the editor.
@Calinou As I understand it, the typical method of signaling a separate application is to use networking. For example, the recommended approach when someone wants to create an MDI application with Godot is to network multiple applications together. To be honest, that sounds like an awful lot of work to squash one teeny-tiny bug - there should be multiple benefits to such a massive undertaking.
Using a wrapper executable (such as UnleavenedEagle's C# script) as the parent of all the applications seems to be a functional workaround (both in Windows and in Linux; unsure about MacOS - and yes, this is also an issue on Linux-based Steam); perhaps wrapping the Godot executable in a small "launcher" executable could be a viable solution? I'm unsure as to what functionality (error messages, etc.) might be lost if the engine itself were not the top-level application, but I see no difference in application behavior except that Steam is able to properly track my time "in game" when the wrapper is in use.
As for the severity of this (arguably trivial) issue, having such an obvious problem with Steam integration in an application designed for creating games (which might then be published on Steam) says potentially unpretty (and arguably untrue) things about that application and its competency at achieving the stated goal. I love Godot, and I'm not trying to offend anyone when I say this is likely not doing wonderful things for Godot's image in the Steam community.
I'm not confident enough to contribute myself, but an eager and knowledgeable contributor might see this as low-hanging fruit. I'll keep my fingers crossed that these "teething issues" with Steam integration are fixed quickly :-)
I have created the wrapper for my personal needs, but in case someone else needs it too, I have uploaded it here:
https://github.com/UnleavenedEagle/SimpleWrapperLauncher/
Worked easily and perfectly @UnleavenedEagle, thank you :)
The problem's still here. I don't know much about how it works, but can't it be set to the CMD console where Godot is also runnin instead of the project manager?
The problem's still here. I don't know much about how it works, but can't it be set to the CMD console where Godot is also runnin instead of the project manager?
Yeah, it stopped working randomly. I found another workaround:
After launching your project you'll notice that's when Steam stops reading that Godot is open, so if you launch Godot again and keep it on the launch screen, it'll keep logging your time.
The problem's still here. I don't know much about how it works, but can't it be set to the CMD console where Godot is also runnin instead of the project manager?
Yeah, it stopped working randomly. I found another workaround:
After launching your project you'll notice that's when Steam stops reading that Godot is open, so if you launch Godot again and keep it on the launch screen, it'll keep logging your time.
I'm doing this the whole time, it's just annoying. I hope it's fixed in 4.0
The problem's still here. I don't know much about how it works, but can't it be set to the CMD console where Godot is also runnin instead of the project manager?
Yeah, it stopped working randomly. I found another workaround:
After launching your project you'll notice that's when Steam stops reading that Godot is open, so if you launch Godot again and keep it on the launch screen, it'll keep logging your time.I'm doing this the whole time, it's just annoying. I hope it's fixed in 4.0
check this out: https://steamcommunity.com/sharedfiles/filedetails/?id=1970276543
Most helpful comment
I have created the wrapper for my personal needs, but in case someone else needs it too, I have uploaded it here:
https://github.com/UnleavenedEagle/SimpleWrapperLauncher/