+ image.getHeight() is throwing a error saying its retrieving a value when its supposed to be a variable if you need the full code for this just let me now
public void createPipe() { Pipe topPipe= new Pipe("top"); Pipe botPipe = new Pipe("bottom"); int pipeSpacing = 150; GreenfootImage image = botPipe.getImage(); int numOfPipes = Greenfoot.getRandomNumber(10) + 4; pipeCounter++; if(pipeCounter == 50) { if(getObjects(Pipe.class).size() < numOfPipes) { addObject(botPipe, getWidth(), getHeight() / 2 + image.getHeight() = Greenfoot.getRandomNumber(100) - 10); addObject(topPipe, getWidth(), botPipe.getY() - image.getHeight() - pipeSpacing); } pipeCounter = 0; } }