Suggestion: make startup gl check independent of game code
Posted: Mon Nov 22, 2010 12:37 am
Problem: at some point during development, renpy started flashing a seemingly random image from the game for a fraction of a second during startup.
Solution: my wife, the content person, had innocently named an image 'black'. It turns out 1) that renpy (6.11.1) tests whether it can use gl by trying to display an image called 'black', and 2) it uses the same image namespace as the game. So 'black' is effectively a reserved image name, though not documented as far as I ever noticed.
Suggestion: as long as 2) above is true, follow Python's internal name convention and use a name like __gl_test_black__, or, if it is used for other internal purposed, __internal_black_image__, for the test image that effectively will not conflict with user names.
Solution: my wife, the content person, had innocently named an image 'black'. It turns out 1) that renpy (6.11.1) tests whether it can use gl by trying to display an image called 'black', and 2) it uses the same image namespace as the game. So 'black' is effectively a reserved image name, though not documented as far as I ever noticed.
Suggestion: as long as 2) above is true, follow Python's internal name convention and use a name like __gl_test_black__, or, if it is used for other internal purposed, __internal_black_image__, for the test image that effectively will not conflict with user names.