multitheftauto/mtasa-blue

`showCursor` and controls toggling

Closed this issue · 1 comments

Is your feature request related to a problem? Please describe.

Currently, showCursor function shows/hides the cursor with respect to the resource calling it - meaning the cursor can be toggled off only by the same resource that toggled it on before, assuming there is no other resource that still has the cursor toggled on. However, this is not the case for it's second argument bToggleControls, controls can be gained back regardless of the resource that's calling the function. If resource A calls showCursor(true, true) (cursor visible, controls disabled) and then resource B calls showCursor(false, false), the cursor would still be visible but controls are gained back.

Describe the solution you'd like

Make controls toggling argument function the same as cursor toggling argument, this would be helpful for the resources that deal with their GUIs only.

Describe alternatives you've considered

No response

Additional context

No response

Security Policy

  • I have read and understood the Security Policy and this issue is not about a cheat or security vulnerability.

Duplicate of #1034 (fixed)