Hello all, i'm currently trying to create an alife program which simulates the life of a single organism, and its actions of eating, drinking and etc. I've already created the basic framework(pretty basic but not very smart). and in order to advance my program, I need a way to create a 2d coord system in that I can place food particles on random points on this coord map, and also have the organisms move around to different points at random, and eating only when one collides with food.
Could someone give me a hand in the right direction?
--- Update ---
EDIT: Sorry to double post but the edit button was not working. I forgot to add that I WOULD provide code, but the code I currently have has nothing to do with this(Nothing is incorporated yet) and also I have NO idea where to start with this, i've tried a few things but they all failed horrible. I just need a hand in the right direction!
--- Update ---
Once again, not trying to double post(Thank you mod who edited my last double post) but I thought i'd add this is NOT homework. The only "attemp" I can provide is this:
public int[][] g; for(int i = 0; i<g.length();i++){ g[i][]= x; honestly i'm just going to stop there. I have no earthly idea.