Indeed that is pretty standard code... that also makes it quite odd that it's throwing an ArrayIndexOutOfBoundsException. I wonder if the height and width being passed in is inverted some where? I know I've done that a couple times in my own code.

On Mon, Apr 2, 2018 at 3:39 PM, Stewart Aitken <[log in to unmask]> wrote:
The 32 is thee code fault indicated and the controller is shown below.
Pretty much standard, I think.

        public static void main(String[] args) {
                SimEnviro2WithUI sim = new SimEnviro2WithUI();
                Console c = new Console(sim);
32              c.setVisible(true);


        public void init(Controller c) {
                display = new Display2D(450.0D, 400.0D, this);
                displayFrame = display.createFrame();
                portrayal = new ObjectGridPortrayal2D() {
                        public Portrayal getDefaultPortrayal() {
                                return new OvalPortrayal2D(, 1.0D) {
                                        public void draw(Object object, Graphics2D graphics, DrawInfo2D info) {
                                                if(object != null) {
                                                        super.draw(object, graphics, info);


                display.attach(this.portrayal, "von Neumann single offspring portrayal");