/run for i=1,GetNumFriends() do local name, _, _, _, connected = GetFriendInfo(i) if(connected) then print(name, 'is online') end end