Hi, all. New to Blender & the forum, appreciate any help you guys can give.
I’m messing around trying to get the hang of the Blender interface and GameEngine, and I’ve hit on a small snag - I figured, now having got basic movement down in the GE, I’d try to expand my knowledge by making a little bomberman clone.
Now, I’ve got my bomb in the second layer, named “bomb” and the following script in a file linked from a keyboard sensor named “Space” and to an Edit Object actuator called “createBomb” from the player object:
cont = GameLogic.getCurrentController() own = cont.getOwner() bombLaid = cont.getSensor("Space") bombInstance = cont.getActuator("createBomb") if bombLaid.isPositive: bombInstance.setObject("bomb") bombInstance.setTime(0) bombInstance.instantAddObject()
Now, I’ve used similar scripts for projectiles in the past, linking them to an empty at the point where I want them to appear. However, as I’m sure anyone who has played bomberman knows, the bomb should appear within the ‘block’ where the player is standing, so I am trying to bring the bomb object in as a ghost. As you might have guessed, this isn’t working - the player immediately flies backward from the newly created bomb.
Any suggestions as to why this might be happening?
Any help appreciated!