laboratory accepts that you've seen in your program steve had experience with these kind things before what we do is we initialize the target the target managers lineup these lines wexler meister the target is basically just a rectangle who sizes some constant target size that's defined down here on the show that you target site abstinence ten seeker sizes twenty in as a pos time tend to say you know target square is going to be the target target square is going to be some neji wreck that we set up and that's a local or a pride instance variable i want to keep track of my target square is just a private jira my secret sauce and indian prodigy rectum and keep track of the target but i want to get to in a private x and y location honest architects in line so when i start off i guess at my target to be a square of this size it's colors are red and it's phil to be true so just initializes the target and now i say i have a target start in the middle of the screen presuming that would be any instructions for the assignment and so i get the middle of the screen no like you know your standard ways computing the centers as something always good to know and then i can't might target to ascension the center of the screen which means if i remember that my target square the place i added to it and this is actually upper left-hand corner i need to take the target acts which the middle of the screen and subtract off half the width of the target both the extraction in the why those direction to get its upper left hand and then i added to the strength of this just set up a target then i set up a seeker and the secrets also square of size supersized by supersized and it just started zero zero dots presumably something that would give him be given to in the problem of the secret to start a different location and once i set up for it target and the secret adam announce listeners cuz i need to know where a mouse clicks and then i just have this loop that just always seeking it is always trying to find wherever the target is the target starts off the coast target xy location dot sorts always how we're always going to keep track of it so what happens is on every step of seek we pause just so the secret of his job fair it's not very exciting if the secret just jumps there every time and we say is the midpoint of the seeker let's get that that's just the secret current x location with his upper left mantra plus half the size of the sme secret come in and we do the same thing on the why which means we would go down half the size of the seeker in the wider action if my target taxes greater than my current acts that i need to move positively in the extraction otherwise i want to move negatively in the extraction and similarly with the white cord right if my why so i find the secret midpoint why if my wife is less than the target y i need to move toward the target why so i mean it increase why if my target wise less than the seekers why i'm going to decrease y so i just find these offset reading to move in a positive or negative extraction or even a move in the positive or negative y direction and then i was going to have the seagram move one step in that direction 