File tree Expand file tree Collapse file tree 1 file changed +31
-3
lines changed
Expand file tree Collapse file tree 1 file changed +31
-3
lines changed Original file line number Diff line number Diff line change @@ -206,10 +206,38 @@ _input_count_previous = _len;
206206#### ** Example**
207207
208208``` gml
209- // Hide aim pointer and pause if focus is lost
210- if (!input_window_has_focus() && !game_paused)
209+ // Pause if focus is lost
210+ if (!input_window_has_focus())
211+ {
212+ game_pause ();
213+ }
214+ ```
215+
216+ <!-- tabs:end -->
217+
218+
219+   ;
220+
221+ ## …game_has_focus
222+
223+ ` input_game_has_focus() `
224+
225+ <!-- tabs:start -->
226+
227+ #### ** Description**
228+
229+ ** Returns:** Boolean, whether the game is in focus
230+
231+ | Name| Datatype| Purpose|
232+ | ----| --------| -------|
233+ | None| | |
234+
235+ #### ** Example**
236+
237+ ``` gml
238+ // Hide aim pointer if game focus is lost
239+ if (!input_game_has_focus())
211240{
212- game_paused = true;
213241 obj_reticle.visible = false;
214242}
215243```
You can’t perform that action at this time.
0 commit comments