Blockland Forums > Help

Need help eventing turret

Pages: << < (2/3) > >>

phflack:


--- Quote from: Skip on March 04, 2010, 06:02:25 PM ---Why the hell is there no edit in Help?
I know it's possible, but I usually screw this things up, so I can't help. :c

--- End quote ---
to stop people from clearing the OP

to have it in the line of sight, place bricks around, then name the turret, then on the bricks that you placed on the ground, have
onplayertouch>turret>spawnhomingprojectile[projectile here]

this requires the homing projectile events

Deathwishez:

Wouldn't that cause a crap load of missles?

If so, here's a way to fix it:

Option A:

Make a floor of invisible plates, when a player touches  it, turn off collision, then turn it back on 1-2 seconds later.

Option B:

Instead of firing with an onPlayerTouch, send a relay t the turret brick and use these events on the turret:


--- Code: ---[X] 0 [0] onRelay > Self > toggleEventEnabled > [ALL]
[X] 1 [2000] onRelay > Self > toggleEventEnabled > [ALL]
[X] 2 [0] onRelay > Self > fireHomingProjectile > (Projectile)

--- End code ---

Option A Details:

Fires projectiles more often when the player is moving
Could cause floor problems
Fires at multiple players

Option B Details:

Fires projectiles at a consistant rate
Uses less output events
Fires one projectile at a time

phflack:

forgot about that, but option A won't work, as if they stand still it will stop firing

Deathwishez:


--- Quote from: phflack on March 04, 2010, 09:01:21 PM ---forgot about that, but option A won't work, as if they stand still it will stop firing

--- End quote ---

True. Option A is a more "nooby" way of doing it. I guess just scrap option A.

Dasmaster:

to be honest option "a" has caght my attention (mainly because it fires at multiple players) :) but it would be nice with "homing bullet" instead of "homing missiles >.<...

Pages: << < (2/3) > >>

Go to full version