I am working on creating a simple matching game. I need to figure out how to make it so that when the player gets a question right, two of the images stay uploaded and when the player gets something wrong the pictures disappear. I have created buttons so that when the player clicks on a tile, an image pops up. Does anyone know how to write a coding for this?
size(635, 480);
//when adding the image first you must click on Sketch, adding file and then select the image you want. Remember that the name that you place in the brackets must be the exact name of the image that you use.
matching = loadImage ("matching.jpg");
//this makes the image appear from the top left hand corner of the screen.
image(matching, 0, 0);