The developer of an apartment tower just outside New Brunswick has sold the building for $54 million, in a deal brokered by HFF’s New Jersey office.