Reading data from a binary file.

I have a bunch of level files that were created with a different language. Im now trying to load them with java into my libgdx game. the maps are in my android “assets/maps” folder. i think the program doesnt know where to look for the specified file… i always get “unable to load level in the log”. If someone could give me a clue what im doing wrong, id really appreciate it!


	public void loadMap(String name){
		int readPointer = 2;
		byte bytes[];
		try{
        	File file = new File(name);
        	InputStream insputStream = new FileInputStream(file);
        	
        	long length = file.length();
        	bytes = new byte[(int) length];

        	insputStream.read(bytes);
        	insputStream.close();
        	Gdx.app.log( FluffyBunniesGame.LOG, "loaded level." );
        }catch(Exception e){
            Gdx.app.log( FluffyBunniesGame.LOG, "Unable to load level." );
            return;
        }
		mapSizeX = bytes[0];
		mapSizeY = bytes[1];
		for (int x = 0; x < mapSizeX; x++){
		for (int y = 0; y < mapSizeY; y++){
			map[x][y].type = bytes[readPointer++];
			map[x][y].frame = bytes[readPointer++];
		}
		}
	}