Updated from client source

Used lived code.