Full Video –
Definition of Instances in Object-Oriented Programming –
Introduction to Variables –
Introduction to Functions –
Types are the blueprints of a group of similar objects in programming. With Types, we can define that group – like factions in video games – AntifaThugs are a Type. For each member of that Type, we have an instance of that type. Using the basis of variables that we learned in the last episode, you can use a variable to define which member of AntifaThugs that instance is with a variable that will be Int nAntifa = Antifa +1, with Var Int nAntifa = 0.
Then you can define what behaviours that instance will be involved in, by defining functions which allow those objects to do something that is being defined by the programmer, like attacking Trolly/Trollette, restoring their hp with a potion, etc, etc, etc.
This allows us to create programming which can look at individual behaviour of instances without making every single member of the group doing the exact same thing at the exact same time.
Thanks for watching and Making Games Great Again!