Hi I would like to get an Object placed in my World in order to get 2 Parameters from it and than safe it in a array. I tried to use:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | private void Bootespeichern() { for ( int y = 0 ; y < getHeight(); y++) { for ( int x = 0 ; x < getWidth(); x++) { if (!getObjectsAt(x,y,BootP1. class ).isEmpty()) //Boot1.class is a Class with the Parameters CordX, CordY, { int Ox = getObjectsAt(x,y,BootP1. class ).CordX; int Oy = getObjectsAt(x,y,BootP1. class ).CordY; BootevonP1 [ 1 ] [ 1 ] = getObjectsAt(x,y,BootP1. class ); } else { BootevonP1 [x] [y] = null ; } } } } |