All Questions
Tagged with game-engine python
89
questions
6
votes
4
answers
3k
views
How do I make a weapon shoot at the center of the screen?
I've been researching this for weeks and only found bad results. I think its time for a good answer. I have a rocket launcher, so I can't "fake" the bullet. There is no way to fake a rocket. I need it ...
6
votes
1
answer
499
views
Clamp velocity along local axis
In the attached Blend File, I have a representation of a airplane/jet fighter (cube scaled at one end to indicate direction of flight). I am using torque to steer, and adding Linear Velocity along a ...
3
votes
3
answers
39k
views
How can I do a one-time Initialization? [closed]
In the following script I want to perform the loading of a DLL only once when initializing
...
7
votes
1
answer
3k
views
Draw geometry on screen using BGL module
I am trying to use the bgl module to draw triangles on top of the Blender interface. My understanding is that glBegin/glEnd are deprecated, and vertex array or display list or VBO should be used ...
5
votes
1
answer
3k
views
What is the difference between module and script execution methods in the Game Engine?
There are two options when using a sensor to run a python script (which also makes me wonder why the python option is a Controller and not a Actuator, but I guess that's a separate question).
As far ...
2
votes
4
answers
2k
views
Blender Game Engine logics sensors and python script
I'm trying to build a simple user interface in Blender Game Engine. 2 buttons (launch and quit).
Each button got a "Mousse Over" and "Left Button" sensors connect to a one Python controller.
Here ...
1
vote
1
answer
606
views
Blender game controller using arduino not working properly
I have started learning blender game engine and arduino. Now I am trying to implement whatever I have learned in this simple game where I press a push button connected to arduino and Cube in blender ...
0
votes
1
answer
670
views
Make modifiers update in the game engine
I am trying to make a boat work in the game engine, and I have a Boolean modifier on the water cutting a spot in the water plane for the boat. The problem is, that when the boat moves, and the mesh ...
15
votes
1
answer
2k
views
How could I place objects (buildings) on a flat surface in the BGE?
I'm working on an RTS in BGE, and I am not sure how I could make it so you can place buildings on flat surfaces (or unless there is an easier way). I would love to know how to place buildings when you ...
7
votes
3
answers
9k
views
How to change material's color in blender game engine?
I am making a new racing game in BGE. I want my game to have a feature to change car color in-game (car consists of multiple materials, but currently I want to change body material). How do I make ...
6
votes
3
answers
10k
views
How to get the distance between two objects in the game engine?
So far I could only find the method to get the current position of the objects. I think there is a method that returns the distance between them.
5
votes
2
answers
3k
views
BGE mouse location in 3D space
I'm a (very new) beginner in python, and I was trying to follow this older technique for getting mouse location in 3D space in the Game Engine.
However, I can't get it to work and I don't know what ...
1
vote
1
answer
1k
views
How to use playAction() on libloaded objects in BGE?
I'm loading the file like this:
logic.LibLoad(logic.expandPath('//car.blend'), 'Scene', verbose=True, load_actions=True)
And I get my object (without using ...
9
votes
2
answers
729
views
No Rasterizer module
I am trying to go trough a simple Blender tutorial in which I need to use module Rasterizer. Unfortunately my Blender has no such module. As far as I know Blender has its own Python so there should be ...
5
votes
2
answers
4k
views
Manipulate BGE logic bricks through python
Is it (if at all) possible in Blender 2.6+?
If not, will future versions of Blender support it?
I see some old posts (this and this) saying that it is not possible. However, I found a recent post ...