In my current 2D platformer prototype I’ve got a invisible player collider(quad) with all collision and movement scripting on it, and, a separate game object childed to that, with a animator on it, which handles the part of the character that’s been seen when playing.
All good and dandy, but I’ve also got power ups now, which change the current players state, like playerstate 0 = normal, playerstate 1= Super and playerstate 2 = firepower for now. My issue is something I read a lot about, but still isn’t clear to me;
I want to use different sprites, all with mostly same animations (idle, walk, jump) but for example when you’ve got the fire powerup, use my sprites where character has red shirt and hat. Until damaged by an enemy, so at the moment the playerstate decreases from 1 back to 0, but what I want to happen also is that the ‘normal’ basic sprites have to be used again. And then when getting a power up, getting damaged, use the sprites according to the current playerstate, etc.
I really hope someone can give me a solution for this, or point me in the right direction.