Platformer and Attacking
TheGabfather
Member Posts: 633
Just last night I've started trying my hand at platformers and have been thinking up ways to design the character in such a way that attacking with a variety of melee to mid-range weapons and attack moves would be easy to implement.
This is the current concept I have in mind, making use of 1 Actor for the Animations, 1 Actor for the Character's collision Rules, and 1 to X Actors for the Attack points.
With this there is no longer any need to have a separate Actor for the Weapon (no more Rotating, swinging, etc).
All the visual weapon swings and other attacks would be left to the Actor assigned for animations, and the hit boxes for attacks would just Activate/Deactivate accordingly.
I think this is a pretty simple concept that other developers have already come across and maybe even implemented, but what I want to know before I start implementing is if there are any drawbacks to this method, such as slowdowns, scene load times caused by the amount of images needed for animations, etc.
Critiques and suggestions for improvements would be fantastic would love to hear how other people implement platformer attacking in their own ways!
This is the current concept I have in mind, making use of 1 Actor for the Animations, 1 Actor for the Character's collision Rules, and 1 to X Actors for the Attack points.
With this there is no longer any need to have a separate Actor for the Weapon (no more Rotating, swinging, etc).
All the visual weapon swings and other attacks would be left to the Actor assigned for animations, and the hit boxes for attacks would just Activate/Deactivate accordingly.
I think this is a pretty simple concept that other developers have already come across and maybe even implemented, but what I want to know before I start implementing is if there are any drawbacks to this method, such as slowdowns, scene load times caused by the amount of images needed for animations, etc.
Critiques and suggestions for improvements would be fantastic would love to hear how other people implement platformer attacking in their own ways!
Comments
In each of the enemies i added a constrain selfx to abs( game.HeroX - game.Enemy1X ) then when punch or kick is pressed check the distance is within a certain range you would also need to make sure the opponents are facing each other.
In my template i also had to make sure there on a similar Y axis but you might not need that.
Your way will work but i think theres a better way.
http://www.deepblueapps.com/double-dragon-template/
Darren.