RobertoFreemano's Recent Forum Activity

  • Thanks GeorgeZaharia

  • Ok, so researching a little bit more, I came across

    Tilemap.PositionToTileX(blast.X -1)

    Tilemap.PositionToTileY(blast.Y -1)

    and this kinda works but I need a little more.

  • Hello Community,

    I want to destroy some tiles from a tilemap using a bomb. I found 'Erase tile range', but unsure how to execute it. I have a grenade sprite and when thrown near to wall (tilemap), the grenade is destroyed... it creates an explosion sprite (Blast) - which is supposed to remove tiles (a.k.a. Wall).

    I've tried:

    Tile X | Blast.x

    Tile Y | Blast.y

    Width | 32

    Height | 32

    I think I'm completely off on this one!

    I did also try:

    I've tried:

    Tile X | Tilemap.x

    Tile Y | Tilemap.y

    Width | 32

    Height | 32

    ...and this removes a chink from the left.

    Thanks,

    Roberto

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hello Community,

    I have a player sprite and a target sprite. The Target sprite is set to mouse.x/y.

    The player's angle is set towards Target. If I click mouse, it spawns a bullet from Player and shoots towards the Target. WHAT'S HAPPENING IS... If the Target is too close to the player and shoots, then the bullet goes in another direction. I want to stop this from happening.

    How to do this?

    Thanks,

    Roberto

  • Thanks GeorgeZaharia

  • I think I sussed it out.

    Zombie has LineOfSight to Player | Set angle towards (player.x, Player.y)

    Zombie |Set Bullet speed to zombie.speed

    System | Trigger Once

    | Zombie Set speed to floor(random(10, 30))

  • Hi Community,

    I'm trying to create a zombie chase game. My Zombies spawn randomly on layout; however, I'm trying to get them to all have their own bullet speed.

    -----------------------------------------------------------------------------

    On start of layout>

    Repeat 10 times | System:Create Object:Zombie on layer1 at (floor(random(0, 100)), floor(random(0, 100))

    Zombie has LineOfSight to Player | Set angle towards (player.x, Player.y)

    Zombie Set Bullet speed to 40

    -----------------------------------------------------------------------------

    I think the issue might be, they have line-of-sight. When they spot the player, they increase speed.. but they all chase at the same speed. How do I get them to have have their own speed?

    So I tried an Instance var on the zombie

    speed=10

    Then altered the LoS

    Zombie has LineOfSight to Player | Set angle towards (player.x, Player.y)

    Zombie Set speed to floor(random(10, 30))

    Zombie |Set Bullet speed to zombie.speed

    but this seems to alternate, not what I want.

    Thanks again,

    Roberto

  • Hello Constructors,

    I've had a look online and found this:

    Global number: timer = 0

    Every tick-- Append Text: floor(gametime/3600)&"h" & floor(gametime/60%60)&"m"&floor(gametime%60)&"s"

    I'm looking for a slower, more natural timer... some that starts 40h60m60s and counts down on the minute/seconds.

    should I use Timer behaviour?

    Thanks,

    Roberto

    Tagged:

  • Hello,

    I'm trying to make a top-down shooter. The player sprite is moved by 8Direction keys. I want to set a target sprite:

    e,g, target | Set position to (Player,X, Player.Y - 100)

    and lock it to that distance from player, so if player moves between angle, the target will rotate or move to the players direction

    [

    [sorry, I'm a maths failure and I'm trying studying algebra again]]

    --example-----

    [t]

    target

    player

    -------------

    if player is facing north and presses key D, then

    [t]

    target rotates from North to East at set distance from payer.

    I HOPE THIS MAKES SENSE!

    The easiest way I can think of is, have a circle set against player and target follows cursor, but is restricted to circle (this is not the preferred method).

    Thanks again,

    Roberto

  • Thanks dop2000,

    I sorted it, as you suggested... I did originally do this, but must have made a mistake somewhere along the way.

    Thanks again Amigo.

  • Hello,

    I'm trying to make a beat-em-up in C2. so far I have 1 enemy who follows player. If my Player is left of the Enemy, Mirror... else on right, not mirrored, you get the idea. I want to spawn another Enemy at another position. How do i get each individual to face the player?

    I have on EveryTick>

    If Player.X < Enemy.X Enemy Set Mirrored

    If Player.X > Enemy.X Enemy Set Not mirrored

    Now i know this will influence all Enemy... but I want the behaviour to only affect each individual Enemy.

    I hope this make sense.

    Roberto

  • Awesome tarek2,

    I forgot about using a timer.

    Thanks again ;)

RobertoFreemano's avatar

RobertoFreemano

Member since 25 Apr, 2013

Twitter
RobertoFreemano has 1 followers

Trophy Case

  • 11-Year Club
  • Popular Game One of your games has over 1,000 players
  • RTFM Read the fabulous manual
  • Email Verified

Progress

14/44
How to earn trophies