its all well & good stuffing everything into one file. but its not good practice - we look at classes.
starting off we create a simple project & start right away by creating a new file/class called 'Rect.hx'.
we go into that file and let it become a class that can draw a rectangle.
we go back to our 'Project.hx' & call it in & make it render on screen.
we go even further & create a folder, making this hierarchy levelling by sticking the 'Rect.hx' inside it & do some edits so its work perfectly.
link to my custom kha snippets:
https://gist.github.com/lewislepton/808d6d2bef1c1c71cf76
source code:
https://github.com/lewislepton/kha-tutorial-series
SUPPORT ON PATREON FROM AS LITTLE AS $1:
https://patreon.com/lewislepton
intro & outro music is from this EP:
https://lewislepton.bandcamp.com/album/coat-noise-ep
like, share & subscribe to stay up to date.
https://lewislepton.com
https://patreon.com/lewislepton
https://twitter.com/lewislepton
https://facebook.com/lewislepton
https://lewislepton.bandcamp.com
https://soundcloud.com/lewislepton
https://github.com/lewislepton