Black screen when using a specific screenshot-basic function

  1. Client (production/canary) and FXServer version
    Canary, Server build: 4162

  2. What you expected to happen
    A screenshot to be taken of the players in game screen

  3. What actually happens
    Instead of a screenshot, it uploads a black image

  4. Category of bug (eg. client, server, weapons, peds, native)
    Render? Maybe?

  5. Reproducible steps, preferably with example script(s)
    Fresh copy of the resource screenshot-basic

  • Step #1 Join the server
  • Step #2 Call the function “requestScreenshotUpload”
  • Step #3 Change the “Screen Type” (Fullscreen, Fullscreen Exclusive, Windowed)
  • Step #4 Call the function “requestScreenshotUpload” again
    Both steps 2 and 4 return valid url’s. However, you may notice that step #4 screenshot is just a black screen.
    I found out that ensuring the resource “screenshot-basic” fixes the problem temporarily, until the player changes their “Screen Type” again.

NOTE: The server function “requestClientScreenshot” and client function “requestScreenshot” does NOT have the same issue. After changing the “Screen Type” the image it returns isn’t a black screen

1 Like

That seems highly unlikely. Both of them use the exact same logic except one uploads to a form and the other to a NUI callback.

I was mistaken when I said it doesn’t happen to the other functions.

Updated steps to repo:
#1 Make sure the resource is started before connecting.
#2 Once connected, call one of the functions.
#3 Change the “Screen Type”
#4 Call the function again. It will return a black screen

Restarting the resource while ingame fixes the issue temporarily, and you are free to change between Screen types for that specific session. Upon reconnecting the issue presents itself