I'm sorry, have forgot everything about seafight, but where do you go to repair the sails? Even tho, yes i have a idea, since the the sails window's name starts with Seafight, and seachart window's name starts with www, you just do a simple winactivate..
Here:
F3:: -------> This is going to change to seachart
ifwinexist

winactivate
return
F2:: -------> This is going to change to sailsmenu
ifwinexist Seafight |
winactivate
return