Creating Classes

Now you know how to use classes like the predefined p5.Vector class. You know that classes let you group a set of fields together, like the x and y fields of the p5.Vector class. And you know how to create instances of a class using the new keyword followed by the class name, also called a constructor.


This is a companion discussion topic for the original entry at https://happycoding.io/tutorials/p5js/creating-classes