A man killed after a fight at a pub during last night's State of Origin game confronted his alleged attacker with a shovel moments before being shot dead, court documents show.

New South Wales rugby supporter Jed Coates, 18, and Queensland fan Matthew Perry, 21, were watching the game at the Colyton hotel in Sydney's west when police say a fight broke out between the men, who were high school acquaintances.

Court documents say Mr Coates and a friend he had been drinking with were ejected from the bar but later confronted Perry at his home, in nearby Nevada Avenue, just after 11pm (AEST).

Police have alleged Perry was armed with a rifle while Coates had a shovel and had shouted "shoot me, shoot me".

Perry allegedly shot him once in the neck and fled the scene.

Coates was treated at the scene by paramedics but later died at Westmead Hospital.

Police think the fight at the pub is what sparked the shooting but Detective Inspector Barry Vincent said it was unclear what the pair was fighting over.

"We believe that an incident predicated what happened here in the street, so certainly anyone who may have been present, that was witness to an assault or incident at Colyton Hotel, if they could contact the police," he said.

Perry was arrested at his home about 3am and charged with murder.

He faced Mount Druitt local court via video link today and was refused bail.

Coates had celebrated his 18th birthday with his twin brother Sam less than two weeks ago and the trip to watch the State of Origin was his first time legally drinking at the local pub.

Sam posted a tribute on his Facebook saying: "RIP Jed, my brother, my twin, your [sic] a king in my eyes, love you bro."