Turrets

0 favourites
  • 10 posts
From the Asset Store
10 turrets rendered in 3D with top down and menu views. Three upgrade levels per tower.
  • Here is my Project:

    Project

    Working on Turret at the Moment.

    Works fine if only one.

    The problems come with many...

    <img src="http://img20.imageshack.us/img20/38/turrentproblem.png" border="0">

    It is obvious to me that the problem is that i don't use instance variables.

    But i can't figure out how to use them on this one.

    Edit:

    What would happen when there are more than one target for the Turret? Would it F*** up?

  • Replace "Every tick" with "For each 'turret'"

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hm.. Now it is only one turrent that fires arrows at a time. The others Don't

  • Instead of "every 1 seconds" use a instance variable for a cooldown time between shots.

    Here is an example of multiple turrets and multiple targets:

    http://dl.dropbox.com/u/5426011/examples%209/turret.capx

    In the example the turrets target the closest player within range. I didn't work it out but it could be modified so that only the first object in range will be targeted until it is out of range.

  • that is exactly what i needed ! Thanks ! <img src="smileys/smiley41.gif" border="0" align="middle" />

  • Instead of "every 1 seconds" use a instance variable for a cooldown time between shots.

    Here is an example of multiple turrets and multiple targets:

    http://dl.dropbox.com/u/5426011/examples%209/turret.capx

    In the example the turrets target the closest player within range. I didn't work it out but it could be modified so that only the first object in range will be targeted until it is out of range.

    But it is supposed to become a multiplayer game. By using Delta-time won't one players Turrets Shoot faster than the other depending on the Frame Rate? Or is the Game alone defining the framerate?

  • Nope, using Delta-Time makes it frame rate independent.

  • Can someone help me modify Rojo example so that the arc does not go over angle 270-90 (half a circle basically). I've been trying to do it by trial and error but its just not working out. I would like it so that the turret will only fire and detect within angles 270-90, if another player instance is in angles 91-269 it will ignore it. I've also tried the turret behavior but it doesn't seem to work when you enter in 180 into the arc field, so I need to do this manually using events.

    Thanks

  • RockmanZero here you go

  • Many thanks Podpathos, can't believe it was so simple, seems I was going about it the wrong way with groups and the between angles event.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)