Underdog's Forum Posts

  • Thank you Blackhornet, I will try that as soon as I'm back home :)

  • Hi everyone,

    I really need your help or a link that may help me to find why it does not work.

    I have 3 Buttons (sprites)

    When I clic on the Sprite named Target, it creates a BlueButton close to it. When I clic on the BlueButton, it should create a BlueObject on the position of the "Target" that was selected.

    Sometimes it works and sometimes it does not work and I don't understand why?????

    It seems that I have an issue with UID. I posted my capx if someone can help me, I would really appreciate.

    Thank you everyone

    dropbox.com/s/qzb474t9usk6jmh/Buttons.capx

  • I resolved it :)

    I needed to pick instances by evaluating distance.

  • Hi everyone,

    I have 2 issues here and I don't find any solution. Even by using UID.

    I have 2 enemies that are the same sprite.

    They have Line of Sight, Path finding and solid behavior.

    When the Player is in Line of Sight Range of one of the sprites, the sprite who detects the Player moves. When the distance between Sprite and Player is <40, Enemy sprite stops and plays "Attack"animation.

    This behavior works for the original sprite but not for the instance

    Each sprite detects the Player normally and behaves correctly except for attacking <img src="smileys/smiley18.gif" border="0" align="middle" />

    As you can see the picture below.

    At the bottom, the original sprite works.

    At the top of the pic, you can see that the instance overlaps the Player and does not perform his attack.

    In the middle, if the original sprite reached the Player and then the instance reached the Player, both sprites play their "Attack" animation but they overlap the Player instead of stop at 40 from the Player.

    <img src="https://www.dropbox.com/s/t6hhknwq7yep8gy/MultipleEnemies.jpg" border="0" />

    Do you notice anything wrong on the capx?

    In addition, I would like to have both sprites surround the Player instead of overlapping each other. Is there a way to say, if Player left side is occupied by an enemy, search other side (right/top/bottom)

    If the four sides are occupied, stay at X from Player and check if one side becomes free?

    Thanks

  • Hi TELLES0808

    maybe you removed the file but your link does not work anymore :(

    Would it be possible for you to link it again?

    Thanks

  • Hi TELLES0808

    Not yet, it is my next plan indeed :)

    but I don't have Construct 2 license yet :( so, I can't work with families but I will get my license soon :)

  • Hi Windwalker,

    Thanks for the tip. I also tried it but it seems that I have an issue with the "For Each" event for this behavior. I'm pretty sure that once I will get my Construct 2 licence (soon), "Family" will fix my problem or there is probably something I did not get lol

    I also think to change my Detection behavior with the Turret/Line of sight behavior and checking distance. And, having an array to check if enemies are not overlapping. If they do, move to another closest free "array cell" from the Player. What do you think? Is this a good approach or do we have something easier?

    However, I post the capx in the HowTo Forum. Still can't post the any link on the forum yet but I "cheat" it to post it. Sorry, it's a bit odd.

  • Hi everyone,

    *** I'm new to the Forum and, as I already mentioned (in the wrong post), I wanted to thank the community who ask questions, answer and post capx for example. Sincerely, Thank you, I would have never achieved what I succeeded doing until now and I hope to get your knowledge in the near future to help others as well.***

    I still need your help

    Here is my problem:

    I would like to create multiple enemies (same sprite and behavior) who have their own position on the map. When the Player gets into their range, only the enemy who detects the Player needs to chase him. If the Player manages to run outside of the detection range, the enemy returns to his initial position.

    I can' post the link yet because I do not have enough rep :(

    But if you really need the capx, change the "*" by "/" and "@" by "."

    Sorry guys, it's a bit odd :(

    The capx here:

    https:"*""*"www"@"dropbox"@"com"*"s"*"obqkwbfzwrg2jvc"*"ForEachEnemy_DetectPlayer"@"capx

    • The capx allows you to see how the Player moves toward Mouse clic with Pathfinding
    • How an enemy detects the Player and chases him with Pathfinding
    • On Attack Range, how the enemy triggers his attack animation
    • If the Player manages to escape, enemies return to their position (I got lucky for this one.)

    In addition, I would like to prevent enemies from overlapping each other when they attack the Player. Do you have any idea, suggestion for the approach to take? I'm thinking about changing my capx with the Turret/Line of Sight behavior and checking distance for the detection part. In addition, I think to add an array to check if enemies are not overlapping and if they do, move to another the closest free "array cell" from the Player. What do you think about this approach? Is there an easier way to get this?

    Thanks

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thank you producermark11

    <img src="smileys/smiley1.gif" border="0" align="middle" />

  • Hi everyone,

    *** Before, let me thank everyone on the forum who post questions, answers and help others. Sincerely, Thank you, I would have never achieved what I succeeded doing until now and I hope to get your knowledge in the near future to help others as well.***

    • The capx allows you to see how the Player moves toward Mouse clic with Pathfinding
    • How an enemy detects the Player and chases him with Pathfinding
    • On Attack Range, how the enemy triggers his attack animation
    • If the Player manages to escape, the enemy returns to its position

    Here is my problem. I would like to create multiple enemies (same sprite and behavior) who have their own position on the map. When the Player gets into their range, only the enemy who detects the Player needs to chase him. If the Player manages to run outside of the detection range, the enemy returns to his initial position. So, it works for one but not for multiple enemies.

    How can I post the capx from dropbox?

    if I paste the link, it does not work, because of security spam

      1. null

      <img src="smileys/smiley1.gif" border="0" align="middle" /> <img src="smileys/smiley1.gif" border="0" align="middle" /> <img src="smileys/smiley1.gif" border="0" align="middle" /> <img src="smileys/smiley1.gif" border="0" align="middle" /> <img src="smileys/smiley1.gif" border="0" align="middle" />