I'm currently developping a tool for a game to make this a bit easier, problem is, I need to detect certain things which should be done through pixel detection but one pixel can't really help me as some things repeat itself. Starting with the login, how do I make it to click the username and then the password without fixed coordinates? I could really use some help

sidenote: the username bar and password bar are both white obviously and that's why I need to seperate them by scanning the word before it, if anyone knows what I mean?