Cheating in Ultima Underworld

Ultima Underworld has a few available cheats.

The Endless Potion
Breaking a potion by attacking it with spells turns it into a pile of garbage. However, the garbage still has the properties of the potion and will never run out! Especially useful with healing and mana potions. Can also be done with single-use spell scrolls, which can cause some ridiculous overpowering early in the game.

Open the Door
Should a locked door be annoying, use Dispel Rune. Despite an error message, all locks are removed.

Better Barter Stuff
When a barter attempt reveals a poor selection of items owned by the NPC, cancel the barter, save the game, and try again. Apparently, each time the game is saved, items up for barter by the NPC will be a slightly different selection (either new items, same items with different quality, or different quantity). However, this does not affect items that the player has bartered off, they will remain up for barter in the NPC's inventory regardless.

Also, things that are specifically set by programming (like the ring one bandit on level three got) are not affected by this tactic.

Eternal Light
To remove darkness from the game, delete SHADES.DAT from the game's data directory. This will cause all levels to be fully lit.

Item Duplication
There is a simple trick to duplicate items.

First, save your game while you have the items in question in your inventory. Next, put the items you want duplicated on the ground in front of you. After that is done, save on a different save slot. Now copy the PLAYER.DAT from the first save into the save directory of the second save. Once you load the second save, you suddenly have the items in your inventory and on the ground in front of you.

This works because items in the inventory, unlike the rest of the game world, are saved in the PLAYER.DAT file, meaning that transplanting a player is trivial.

Hex-Editing for Stats
The PLAYER.DAT of each save game can be manipulated in order to ramp up the stats significantly. Bytes 10 to 3F have to be set onto FF and the bytes 40 to 4F onto 64 in order to get a significant boost for the player stats and abilities. Doing this causes the game to mention stats being cheated at the end of the game.