BGE: fix crash and return boolean on scene.replace()
Scene replacement with invalid scene name was crashing blender, now it's a no-op. KS_Scene.replace() to return a boolean to indicate if the scene is valid and is scheduled for replacement. This allows more robust game management.
This commit is contained in:
@@ -152,6 +152,8 @@ base class --- :class:`PyObjectPlus`
|
||||
|
||||
:arg scene: The name of the scene to replace this scene with.
|
||||
:type scene: string
|
||||
:return: True if the scene exists and was scheduled for addition, False otherwise.
|
||||
:rtype: boolean
|
||||
|
||||
.. method:: suspend()
|
||||
|
||||
|
Reference in New Issue
Block a user