Animation help

From the Asset Store
Ninja char for your game! Make your own Shinobi game with this art.
  • So take out jumped and landed as I don't need them. What you have above is exactly what I already have in my event sheet that I posted in my previous posts. I'm starting to think it's something to do with the spit animation being triggered by the turret function.

  • So take out jumped and landed as I don't need them. What you have above is exactly what I already have in my event sheet that I posted in my previous posts. I'm starting to think it's something to do with the spit animation being triggered by the turret function.

    Use variables and Boolean variables then you can get out of states, your character cant be alive and dead at the same time for this you need to use variables or Boolean variables.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Ok, i'll try switching everything to boolean as the regular variables aren't working.

  • Ok so we are getting there now. Everything is set to boolean. It now runs between 'spitting' however it only plays the first frame of the spit animation and stays on that frame throughout the whole 'spit'

  • Ok so we are getting there now. Everything is set to boolean. It now runs between 'spitting' however it only plays the first frame of the spit animation and stays on that frame throughout the whole 'spit'

    use the debugger to see states

  • on turret behavior you have line of sight also i think... if you dont you can calculate the distance... so you can do this by using 1 true condition and 1 inversed...

    True check condition : if distance(enemy.x,enemy.y,turet.x,turet.y)< turret.range Action. turet.setanimation to fire... play animation from beginning... loop animation... you dont need to set the loop animation since you can switch in animation editor.. to repeat and leave the repeat count on 1 will do endless animation repeat..

    then copy paste it and select inverse on it or add Else under that condition and set animation to idle /or patrolling what you have

    also i wold remove the spit and wait action call cause it will delay all other events also... not only the spit destroy action

    remove spit destroy and wait... and add on sprite spit the behavior fade out and set the time to fade in 0 fade out 0 wait time 1 destroy after fade out.. or add a condition since its a bullet.. you can use the expression distance traveled... and the condition for spit sprite will be something like : spit.bullet.distancetravelled> 200 Action Spit.Destroy

    also you can right click on the spit bullet condition check and make it an OR condition then add on collision with walls OR on collision with enemys ( the 200 above is the distance in pixel per tick )

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