@Override
	public void setTMMoves(List<Integer> moveIndexes) {
		String tmDataPrefix;
		if (romEntry.romType == Type_DP || romEntry.romType == Type_Plat) {
			tmDataPrefix = "D300D400";
		} else {
			tmDataPrefix = "1E003200";
		}
		int offset = find(arm9, tmDataPrefix);
		if (offset > 0) {
			offset += 4; // because it was a prefix
			for (int i = 0; i < 92; i++) {
				writeWord(arm9, offset + i * 2, moveIndexes.get(i));
			}

			// Update TM item descriptions
			List<String> itemDescriptions = getStrings(romEntry
					.getInt("ItemDescriptionsTextOffset"));
			List<String> moveDescriptions = getStrings(romEntry
					.getInt("MoveDescriptionsTextOffset"));
			// TM01 is item 328 and so on
			for (int i = 0; i < 92; i++) {
				// Rewrite 5-line move descs into 3-line item descs
				itemDescriptions.set(i + 328, RomFunctions
						.rewriteDescriptionForNewLineSize(
								moveDescriptions.get(moveIndexes.get(i)),
								"\\n", 40, ssd));
			}
			// Save the new item descriptions
			setStrings(romEntry.getInt("ItemDescriptionsTextOffset"),
					itemDescriptions);
			// Palettes update
			String baseOfPalettes = "8D018E01210133018D018F0122013401";
			if (romEntry.romType == Type_DP) {
				baseOfPalettes = "8D018E01210132018D018F0122013301";
			}
			int offsPals = find(arm9, baseOfPalettes);
			if (offsPals > 0) {
				// Write pals
				for (int i = 0; i < 92; i++) {
					Move m = this.moves[moveIndexes.get(i)];
					int pal = this.typeTMPaletteNumber(m.type);
					writeWord(arm9, offsPals + i * 8 + 2, pal);
				}
			}
			// if we can't update the palettes its not a big deal...
		} else {
		}
	}