Added very messily done UCS, will clean and comment when extra time is available