added some polling stuff ... really messy