So recently, I have been learning OOP and I want to use it for some of my games because I have a lot of guns / melee items in my game that use repetitive code. I was wondering how I can use this for a melee system? Because some of my melees have combo systems where you can do 2 attacks and lunge, and other’s dont, some may have special abilities, while others don’t, so I’m just looking for some guidance on how to do this
Hi, OOP paradigms aren’t always the answer to any design issues and that requires quite a reading and deep consideration for what you are willing to enhance with the benefits and the costs you are willing to take along with it. Under the assumption you want to use OOP, and that you stick to the principles it provides, you might consider the items as classes and objects.
Although we could provide guidance, the first step you could take is by learning what is minimum for your system to function. With a design plan in mind, you can probably make it.
1 Like
gimme the melee system and i’ll convert it into oop for you ![]()
1 Like