public void drawImageString(JGEngineInterface eng,
	String string, double x, double y, int align,
	String imgmap, int char_offset, int spacing,boolean pf_relative) {
		ImageMap map = (ImageMap) imagemaps.get(imgmap);
		if (map==null) throw new JGameError(
				"Font image map '"+imgmap+"' not found.",true );
		if (align==0) {
			x -= (map.tilex+spacing) * string.length()/2;
		} else if (align==1) {
			x -= (map.tilex+spacing) * string.length();
		}
		//Image img = map.getScaledImage();
		StringBuffer lettername_buf = new StringBuffer(imgmap+"# ");
		int lastchar = lettername_buf.length()-1;
		String lettername=null;
		for (int i=0; i<string.length(); i++) {
			int imgnr = -char_offset+string.charAt(i);
			//String lettername = imgmap+"#"+string.charAt(i);
			lettername_buf.setCharAt(lastchar,string.charAt(i));
			lettername=lettername_buf.toString();
			if (!existsImage(lettername)) {
				defineImage(lettername, "FONT", 0,
					getSubImage(imgmap,imgnr),
					"-", 0,0,0,0);
			}
			JGImage letter = getImage(lettername);
			eng.drawImage(x,y,lettername,pf_relative);
			//eng.drawImage(buf_gfx, x,y,lettername,pf_relative);
			x += map.tilex + spacing;
		}
	}