Good Morning everyone.
(Colleagues, I have tried hard to see the problem, but to no avail).
Experiment 14.
The experiments will slowly converge towards one big experiment: a simple game. I have just a little interest in games (perhaps I should have more), but making one - even a simple one - should be self rewarding.
However, now to the point.
* The experiment creates an array of rectangle objects.
* The rectangles are painted inside a Frame object at random x,y coords generated by a random number generator
* The rectangles are stationary.
* The rectangles are each assigned their own random colour.
* The array of rectangle objects is created inside the constructor of the class.
The actual code contains various other variables and methods which would distract from a quick analysis, so below is code
which has the same logical structure which also fails (instead of array of rectangles, I have used arrays of integers).
As always, thank you. Maybe I can help someone else one day.
(Colleagues, I have tried hard to see the problem, but to no avail).
Experiment 14.
The experiments will slowly converge towards one big experiment: a simple game. I have just a little interest in games (perhaps I should have more), but making one - even a simple one - should be self rewarding.
However, now to the point.
* The experiment creates an array of rectangle objects.
* The rectangles are painted inside a Frame object at random x,y coords generated by a random number generator
* The rectangles are stationary.
* The rectangles are each assigned their own random colour.
* The array of rectangle objects is created inside the constructor of the class.
The actual code contains various other variables and methods which would distract from a quick analysis, so below is code
which has the same logical structure which also fails (instead of array of rectangles, I have used arrays of integers).
As always, thank you. Maybe I can help someone else one day.