private void loadDefinition(Buffer stream) {
		do {
			int attribute = stream.getUnsignedByte();
			if (attribute == 0)
				return;
			else if (attribute == 1) {
				rgbColour = stream.get3Bytes();
				rgbToHls(rgbColour);
			} else if (attribute == 2)
				textureId = stream.getUnsignedByte();
			else if (attribute == 3) {
			} // dummy attribute
			else if (attribute == 5)
				occlude = false;
			else if (attribute == 6)
				name = stream.getString();
			else if (attribute == 7) {
				int oldHue2 = hue2;
				int oldSat = saturation;
				int oldLight = lightness;
				int oldHue = hue;
				int rgb = stream.get3Bytes();
				rgbToHls(rgb);
				hue2 = oldHue2;
				saturation = oldSat;
				lightness = oldLight;
				hue = oldHue;
				hueDivisor = oldHue;
			} else {
				System.out.println("Error unrecognised config code: "
						+ attribute);
			}

		} while (true);
	}