To discuss what Object Oriented Programming is, let’s discuss the problem it was designed to solve. Well, let’s get as close as we can to an explanation while keeping this readable for non-coders.
Originally, programming was procedural…
…but the problem (the argument goes) is that procedural programming (PP) can get out of hand in terms of complexity.
Let’s say we’ve got a game. We’ve got a big list of (say) space marines taking part in the simulation. Each space marine is nothing more than a block of data describing where it is, how it’s moving, what weapon it has, how many hit points it has, what team it’s on, what it’s AI is up to, what character model it’s using, if it’s dead, and so on.
Here, let’s make up a pretend data structure to hold our marine:
Continue reading 〉〉 “Object-Oriented Debate Part 2: Okay, so what is OOP?”