Two weeks ago, a friend pulled William K. Weaver aside and delivered a bombshell to the lobbyist for the Maryland Bankers Association: Within 24 hours, the friend said, Gov. Harry Hughes would reveal a secret agreement with Citicorp under which the giant New York bank could win the right to establish branches in Maryland.

Weaver was surprised but not paralyzed. By the next morning when Hughes told a packed news conference that Citicorp could have its coveted full-banking services after opening a large credit card service center in Hagerstown, Weaver had already mobilized key members of his 89-bank association and launched a counterattack that started the major lobbying war of this legislative session.

Weaver's efforts have stalled and may kill the Citicorp agreement.

His success in snarling what at first seemed a relatively simple deal -- give Citicorp the benefit of full banking in exchange for nearly 1,000 new jobs and a $25 million capital investment in Hagerstown -- is a testament to his effectiveness after 17 years of plying State House corridors for his banker bosses.

Weaver's campaign and the equally intense effort by Citicorp lobbyists to rescue the agreement illuminate some of the ways in which this political town works and how the best-laid plans of politicians can go awry.

"There's nothing like going up against the Maryland Bankers Association," sighed Hughes aide Benjamin Bialek as he prepared to defend Hughes' agreement today before the Senate Finance Committee.

Bialek told the committee that expansion of Citicorp in Maryland would be a boon for economic development in depressed Washington County and for consumers who would have "more convenience [in banking services] and better interest rates, hopefully."

Weaver, by contrast, has argued that allowing the $150 billion Citicorp, the nation's largest bank, to expand would mean the demise of smaller banks, leading to less competition which would cost consumers more in the long run.

Weaver and the bankers also contend that the agreement violates the spirit, if not the letter, of a separate compromise hammered out last year that would let Maryland banks enjoy four years of regional banking with 12 southeastern states and the District of Columbia before Maryland's borders would be opened to full interstate banking.

Associates say killing the Citicorp agreement is one of the toughest assignments Weaver has had as a lobbyist. Colleagues say his success hinges on three things: His own persuasive powers, the power of bankers who have orchestrated telephone calls and private meetings with legislators, and time -- a crucial factor as the legislature rushes to conclude its work in 19 days.

Those same factors apply to Citicorp lobbyist Franklin Goldstein, who with Bialek is Weaver's nemesis in the debate over the Citicorp agreement.

Weaver and Goldstein are a study in contrasts and shared traits. Where Weaver, 60, resembles a banker with his white hair and preppy attire, Goldstein, who turned 57 last week, is short and balding. The Maryland bankers' representative is a District native and Army brat who used to negotiate labor contracts for management; Citicorp's chief lobbyist was born and raised in Baltimore and except for short stints at graduate school (Harvard Law, class of 1953) and in Philadelphia, has lived there all his life.

The Maryland bankers paid Weaver $47,365 last year; he had no other clients. Goldstein, who was paid $64,990 in 1984 by Citicorp and a subsidiary, earned more than $164,000 during the last legislative session.

The two aren't always on opposite sides. They joined forces two years ago to win passage of a sweeping credit card deregulation bill that gave Citicorp its first real toehold in Maryland.

Both Goldstein, a former assistant attorney general who has lobbied here for nearly 20 years, and Weaver, who was working in Annapolis when some lawmakers were teen-agers, have exploited their time-honored access to the House and Senate leadership this week.

About noon today, for instance, Goldstein slipped into the office of Senate President Melvin A. Steinberg (D-Baltimore) and for 15 minutes politely berated Steinberg about his objections to the Citicorp agreement, Steinberg said.

"I told him that what worries me -- and nobody has answered it yet -- is what happens to the regional banking compact if the Citicorp agreement is approved but the compact is thrown out" in court, Steinberg said.

Citicorp has challenged regional banking agreements in the U.S. Supreme Court.

Weaver, too, has Steinberg's ear. Last Friday, at the Senate president's request, Weaver arranged a private meeting with several bankers in Baltimore.

The two-hour meeting not only afforded Steinberg and Finance Committee Chairman Dennis Rasmussen a chance to smooth bankers' egos bruised by Hughes' failure to inform most of them of his agreement with Citicorp. It also gave the bankers the opportunity to outline their objections to the agreement in private.

On Friday, Rasmussen's committee is expected to approve a regional banking bill that makes little or no provision for the kind of national banking that Citicorp officials and industry experts believe is inevitable.

If such a bill is approved by the Senate and House without measures tailored to Citicorp, the New York bank might drop its planned development near Hagerstown and would have to return to Annapolis next year.