checking if game is paused from zscript?

Moderator: GZDoom Developers

Post Reply
User avatar
Marisa the Magician
Posts: 3886
Joined: Fri Feb 08, 2008 9:15 am
Preferred Pronouns: She/Her
Operating System Version (Optional): (btw I use) Arch
Graphics Processor: nVidia with Vulkan support
Location: Vigo, Galicia
Contact:

checking if game is paused from zscript?

Post by Marisa the Magician »

Would it be possible to have (at least readonly) access to the paused variable? I don't think it should be much of an issue to do this.

I can easily do this myself but first I need to ask if it'd be right to expose it.
User avatar
Rachael
Posts: 13562
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: checking if game is paused from zscript?

Post by Rachael »

This variable is game sync'd, so it should be possible to have readonly access from all contexts.
User avatar
Nash
 
 
Posts: 17439
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: checking if game is paused from zscript?

Post by Nash »

Should only "paused" be exposed, or also "pauseext" (what does the latter even do anyway? I don't really understand its purpose)?
User avatar
Player701
 
 
Posts: 1640
Joined: Wed May 13, 2009 3:15 am
Graphics Processor: nVidia with Vulkan support
Contact:

Re: checking if game is paused from zscript?

Post by Player701 »

Got a PR here. Better late then never, I guess?
Nash wrote:Should only "paused" be exposed, or also "pauseext" (what does the latter even do anyway? I don't really understand its purpose)?
As far as I understand, pauseext is a flag that is used to suspend the game when it loses focus. Since the entire game is suspended, I don't think it would make sense exposing it to user code. However, please correct me if I'm wrong.
User avatar
Nash
 
 
Posts: 17439
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: checking if game is paused from zscript?

Post by Nash »

Player701: No, you're right, that doesn't seem like it has any business with mods. Good work. :)
Post Reply

Return to “Closed Feature Suggestions [GZDoom]”