lionz's Forum Posts

  • Compare the X so if enemy is moving and player X is greater then animation move right, player X is less than enemy then animation move left.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I'm not really sure what's going on with the above response but yeah you can either increase the rotation speed so it's no longer 'smooth' but snaps to face the target location, or you can disable the rotation altogether and set the angle of the object to the pathfinding moving angle which would have pretty much the same visual effect.

  • For 8 direction the movingangle is the direction of movement so moving left would be enemy.8direction.movingangle = 180. When moving to the right then movingangle is 0. Up is -90 and down is 90.

  • To group objects in this way you add them to a family, when Enemy is overlapping Family.

  • Here ya go https://tinyurl.com/yb8bpwfy

    Dropping ipa straight onto the device or reverting back your version of itunes seem like the better options.

  • You can use floor(random(52)) which generates a number from 0 to 51, where each number corresponds to a card. You could do this with events or store in an array. On the first drawn card you can set a variable to that number then on second drawn card you compare with that variable and if it matches, run the random command again.

  • > I was thinking of something :

    > - Put on your scene a few invisible obstacles that you can activate/desactivate.

    > - Every time an object has to find its path, chose randomly a random number of obstacles to activate. This will create for every object a different path to choose from. One path is calculated, disable active obstacle and apply the same process to the next object

    > - Of course, you'll have to place your invisible obstacles on stage so that they won't create dead end where an object can be stuck.

    >

    > I didn't give it a try but this may be worth trying

    >

    Having trouble doing this... After assigning a round(random) number to the pathfinding object on creation, I add obstacles to it depending on what number it was assigned and then find a path. After finding the path it just goes straight through everything toward the destination :/ Any ideas?

    Whenever the obstacles change you need to regenerate obstacle map.

  • Drag the ipa into the apps tab in iTunes and sync with the device.

  • I think that name might already be taken by another game series...

    You should call it Cute Knight though.

  • I was thinking of something :

    - Put on your scene a few invisible obstacles that you can activate/desactivate.

    - Every time an object has to find its path, chose randomly a random number of obstacles to activate. This will create for every object a different path to choose from. One path is calculated, disable active obstacle and apply the same process to the next object

    - Of course, you'll have to place your invisible obstacles on stage so that they won't create dead end where an object can be stuck.

    I didn't give it a try but this may be worth trying

    Yes that's what I was saying above. I've put it into practice and it works.

  • The pathfinding calculates the shortest route each time. If I was to do this I would create obstacles before calculating the path to alter which way they go. You could create a number of set routes by blocking certain directions.

  • You've posted this in the wrong place.

  • Yep, on initial hit , you do X damage and set a variable to true and start a 10 second timer. Then you have a separate event where if this variable is true, do Y damage every 2. Then when the timer has finished, set the variable back to false.

  • Your link is broken because you don't have enough rep yet, you'll have to 'edit' it a little. : DD

  • You add the compare as a condition, press C, you can add the compare vars after the initial on button clicked, so it becomes on button clicked, if var=var, do this. In C2, the ifs are just conditions. It will only execute actions on the right if the conditions on the left are true. So if you click the button and those vars do not meet the condition you want, then clicking the button will not execute the action on the right and do nothing at all.