I mean without controller being connected to Edit Object > Add Object Brick. Furthermore, I need to add that object at a specific location, instead of putting it on top of the owner, since I will be adding more than one object so they can't be all at one location. I tried moving the owner but it cannot move and create objects more than once in a single frame for some reason, probably because it takes a frame to pass for a controller to reach a signal towards an actuator Brick. So I figured doing it from a controller might be a solution but I don't know how to do that.
Asked
Active
Viewed 62 times
0
Alex Azazel
- 157
- 8
1 Answers
0
How to add an object at a specific posistion in Blender Game Engine
import bge
scene = bge.logic.getCurrentScene()
object = scene.addObject("Sphere","Sphere")
object.worldPosition = [1,1,1]
Alex Azazel
- 157
- 8