I hope that someone might be able to explain me a workaround on how to use the bpy module in the game engine as a standalone. I've read of methods like modifying Blender and import it as a module into the standalone or something like this.

Does someone have a clue or maybe a modified file?

  • 3
    $\begingroup$ There is a bpy module that gives access to the modelling/texturing/etc side of blender, then there is the bge module that is used in the game engine, bpy is not available and shouldn't be needed in the game engine. A simple distinction is bpy is used to create the 3d models while bge is used to access the models in the game engine. $\endgroup$
    – sambler
    Sep 6, 2016 at 6:35
  • $\begingroup$ To be more specific - bpy is the API for Blender while bge is the API for the Blender Game Engine. They are both different applications. It makes not much sense to use Blender's API without Blender. The Workaround is ... provide Blender and you can use the Blender API. $\endgroup$
    – Monster
    Sep 6, 2016 at 8:51
  • $\begingroup$ Wellt thanks for the info, but I knew that already. Though I definitely want to use the bpy in the game engine and somewhere I read that there might be possibilities with modified versions of Blender. $\endgroup$ Sep 6, 2016 at 9:20
  • $\begingroup$ It is still the same. You need Blender and the BGE. While running the game write access has no effect on the game. E.g. you can create new objects via bpy. But they will be created inside Blender not inside your game session. May I ask why you think you need bpy? $\endgroup$
    – Monster
    Sep 7, 2016 at 4:29

1 Answer 1


If you use the BPY module, you can still run it as non-runtime code.

This is perhaps what is wanted in your case (you are not forced to create a game with the BGE.

However, in most cases, the authors want to create a game. Non-runtime code will prevent him from creating one.

Using BPY in a game is a typical mistake as you yourself can find in research regarding Blender scripts. It is usually plain copied from there as it is not clear to them that Blender and BGE are two separate rendering engines. This image exists. as this topic comes up from time to time. I hope it is a funny way to help remind to stay clear and avoid BPY for games.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .