Updates and bug fixes from Rayman and myself