I've actually seen a similar mechanic in the game Rogue-like: Evolution, though the Sanity idea is new.