Broadcast added and bugs fixed