got socket code finally working, now correctly monitors match