Pages: « 1 2
  Print  
Author Topic: FakeFullscreen.dll  (Read 6005 times)
Offline (Male) Goombert
Reply #15 Posted on: March 22, 2014, 01:07:19 pm

Developer
Location: Cappuccino, CA
Joined: Jan 2013
Posts: 2993

View Profile
It was a simple mistake I overlooked it, cut me a break. I have amended the pull request with the fix for XLIB and Win32.
https://github.com/enigma-dev/enigma-dev/pull/673

Quote from: TheExDeus
But that again break not only the naming convention but common sense. The OS is NOT paused when that function returns true, the game is not even paused. The game just lost focus. But at least if I make two versions they can be both used - this one will work just like GM:S and the window_get_focus() will work like it really should.
Yeah no, that is not what the function is at all. It has to do with mobile devices and whether the application is in the background, ie. you have an incoming call on your cell phone.
http://docs.yoyogames.com/source/dadiospice/002_reference/operating%20system/os_is_paused.html

Quote from: TheExDeus
I will implement this to make it work like a window function and then implement the os_ one to work like GM.
Or you could just, you know, amend my commit since I've outlined other functions as well.
« Last Edit: March 22, 2014, 01:13:27 pm by Robert B Colton » Logged
I think it was Leonardo da Vinci who once said something along the lines of "If you build the robots, they will make games." or something to that effect.

Offline (Unknown gender) TheExDeus
Reply #16 Posted on: March 22, 2014, 01:17:51 pm

Developer
Joined: Apr 2008
Posts: 1860

View Profile
Quote
Yeah no, that is not what the function is at all.
It also works in Windows (read the doc you linked). And that is exactly why I said I will implement window_get_focus(), because that is the function we actually wanted. Like check if window_get_focus()==true and only then center the mouse. Also, your current implementation still doesn't do what os_is_paused does in GM. It does what window_get_focus() is supposed to do. I just implemented it too and basically the same way. To make os_is_paused() work like GM it will have to be a lot less pretty (we need additional variable to check if window was in focus last frame).

Quote
Or you could just, you know, amend my commit since I've outlined other functions as well.
I am not really interested in those functions.
Logged
Offline (Male) Goombert
Reply #17 Posted on: March 23, 2014, 09:39:41 pm

Developer
Location: Cappuccino, CA
Joined: Jan 2013
Posts: 2993

View Profile
Quote from: TheExDeus
To make os_is_paused() work like GM it will have to be a lot less pretty (we need additional variable to check if window was in focus last frame).
You're assuming that the 1 step is guaranteed.

At any rate I have fixed it and tested it for Win32 to have the expected behavior and committed, the following works fine. I still need to test and make sure Studio does actually behave this way, and if so then it can be merged. However, I don't agree at all with the way they handled this, honestly it was so stupid, they should have just made FocusGain and FocusLost events.
Code: (EDL) [Select]
if (os_is_paused()) {
        show_message_async("OS Paused");
}

This was the commit amended that fixed the issue.
https://github.com/RobertBColton/enigma-dev/commit/28b0f89bba5f1c38daf3944781cfe495d92af51f
I also had to apply the following fix to that.
https://github.com/RobertBColton/enigma-dev/commit/a6706ff2d12141c561d4d2d172826955e224cbc7

Edit: I have tested Studio, and the current version appears to behave exactly the same, so the pull request is good to merge. However I have noticed a new inconsistency in the asynchronous dialog functions.
Logged
I think it was Leonardo da Vinci who once said something along the lines of "If you build the robots, they will make games." or something to that effect.

Offline (Unknown gender) Darkstar2
Reply #18 Posted on: March 23, 2014, 11:14:11 pm
Member
Joined: Jan 2014
Posts: 1238

View Profile Email
Quote from: TheExDeus
To make os_is_paused() work like GM it will have to be a lot less pretty (we need additional variable to check if window was in focus last frame).
You're assuming that the 1 step is guaranteed.

At any rate I have fixed it and tested it for Win32 to have the expected behavior and committed, the following works fine. I still need to test and make sure Studio does actually behave this way, and if so then it can be merged. However, I don't agree at all with the way they handled this, honestly it was so stupid, they should have just made FocusGain and FocusLost events.
Code: (EDL) [Select]
if (os_is_paused()) {
        show_message_async("OS Paused");
}


Thanks Robert.  I guess we both agree that YoYo has not done many things correctly.
One can write a book on that topic.  But their shit sells and seems to do quite well. Maybe people don't know better :D  Probably most mobile developers won't give a shit either. :P

BTW I agree with the focus events.  Maybe their reasoning is that it is not useful to them.  Much the same reasoning behind them removing some windows functions that are standard in other products, so they basically, not giving a two shit about their customers, will only implement things if THEY find it useful.

Logged
Offline (Male) Goombert
Reply #19 Posted on: March 24, 2014, 12:22:21 am

Developer
Location: Cappuccino, CA
Joined: Jan 2013
Posts: 2993

View Profile
Heh, I really despise the premise of the whole thing, ENIGMA too. I just think we have a better C-inspired cross-platform wrapper for DirectX on Linux, etc.
Logged
I think it was Leonardo da Vinci who once said something along the lines of "If you build the robots, they will make games." or something to that effect.

Pages: « 1 2
  Print