Hey everyone,
I am currently working on a basic game using a 2x16 parallax LCD screen and an Adruino Uno. So far i have the player character able to move up down right and left using 4 if statements and input from a controller I made on a bread board. Next i would like to make a monster npc that chases the player. I have made many programs like this before and am basing the code for my Adurino project after one I made in java script. I can easily make a single monster that chases the player around, again using about 4 if statements to control its movement and then one to detect when they are touching. However I haven't figured out how to add additional monsters using the same "brains" but having their own separate variables without adding more of the same code just with different variables. I did a little Minecraft modding before and I'm looking for something kind of like an entity files, where each 1 of the NPCs rendered can call on their file to know how to behave. If you need more info let me know. Any help at all would be great!
Thank you very much!
~aaaelite21