Well, the title says it all :eyebrowlift:. I am making an alien-type game in which you have a laser rifle:cool: Does anybody know how to shoot laser beams from a gun? Thanks- Drew
Are you meaning a beam, or a “pulse” style laser?
I have similar question too.
how to draw laser to be(show) projectile path.(with or without python)
sorry to hijack this thread but question is seem similar.
I mean a “Pulse” laser. Like something from Star wars. More of a " PEWPEWEPEW" than a " BZZZZZZZZZZ"
Use AddObject either via Actuator or via Python code.
For pulsed laser that fires 3 pulses (what i have done):
Empty has two states:
- State 1: upon mouse-click, set state 2
- State 2: Always Sensor and Delay Sensor (Delay has true pulse triggering on, with frequency of 10; also has a duration of 7 and is repeated) are connected to an Add Object actuator that adds the laser object - which in my case is a short plane with a laser texture mapped onto it, and the plane rotates at a high speed - along the beam axis. The laser object has it own speed, and is static with actor and ghost properties selected in physics panel.
- In State 2: A Delay sensor (with a delay value of 21 - for 3 pulses - and nothing else) connected to a Set State actuator that returns to State 1.
Python would be a better idea, but this works.
Raven, would you be able to PM me the .blend so i can see whats going on?