ps1 work - sloppy, but working