[My unity version is 5.5.0.f3 windows / i only made one little changes to my laser defender (my ship can move also in y direction) excepting the animations, sprites and other unimportant changes / and sry if i have some english errors :S]
Hi, i have one problem in my laser defender. i’m trying to give more hp to the enemy so that the player don’t kill the enemy so fast in the start of the animation .
[My enemy hp is 5 in idle state and my ship damage is 3]
(https://gyazo.com/63b6fde26a12138e63206e3323244071)
The problem is when you try to kill him, the enemy restarts his life every frame: (here is a sequence of images in the monodevelop debugger)
(https://gyazo.com/822cc7f49698fc4f64670ed80f662491)
(https://gyazo.com/5602d0bfe5eb942fa88697c5cb29c054)
(https://gyazo.com/580b1b50e31e5c9d596c7d8fb0c9a6ec)
and when i hit again the enemy has 5 hp again:
(https://gyazo.com/e824ef231f8b5adf029a7a9d4886ce23)
i want to learn how to instead the enemy restart his life every frame, the enemy could decrease his life every frame (for example 0.5f) and when get hitted decrease his life related with the player damage.
i tried to get the Enemy behaviour script [health] (5) in idle but is the same.
and this is my animator:
i hope i could understand how to manipulate scripts in animations to do some cool stuff in the future
Thanks to all who can help <3 ^^