Steven Homoki was arrested on suspicion of possession of an assault weapon, possession of a high capacity magazine and child endangerment

A California man has been arrested after allegedly posting a YouTube clip where he appeared to be practicing a mass shooting.

Steven Homoki was arrested on Thursday on suspicion of possession of an assault weapon, possession of a high capacity magazine and child endangerment.

The 30-year-old allegedly posted videos showing a series of different guns being pointed towards a hotel window in San Diego.

Police received a tip-off on Monday about the clips and stating Homoki had 'gone off the deep end', adding he had a 'plan' in place.

In the videos which appear to be shot on a body camera, a figure can be seen in the hotel room with several assault weapons, magazines and bullets, inducing a hand gun as well as a machine gun.

The suspect was staying at the Sofia Hotel, which sits across the street from the San Diego courthouse, according to his arrest warrant.

In the YouTube grabs guns were pointed at the window of a San Diego hotel room and aimed at passers-by

A hand gun and assault weapons were seen being loaded and aimed at pedestrians in the clips posted online

In the videos posted on September 17 and 18, the guns appeared to be loaded, then the camera operator seemed to crawl on a bullet-strewn floor, re-load the weapons, then point them at pedestrians from the window.

The video begins with an unloaded hand gun being pointed at the window and fired as someone walks past.

Then an unloaded assault rifle was picked up and fired at another pedestrian, before another gun in the aimed in the same direction.

The figure then walks around the hotel room before crawling around the floor picking up bullets to load them in a magazine, saying: What do you do with this?'

At one point the trigger was pulled on an unloaded rifle aimed at passers-by and a voice said: 'One down, more to go.'

While running around the room with as assault rifle the figure, picked up what appears to be a bottle of spirits and repeatedly said, 'that's not true'.

Assault rifles and bullets could be seen in the videos that appeared to be acting out a mass shooting

The suspect was filmed throwing a hand gun on the floor before picking up an assault rifle

When the weapon appeared to jam, the figure threw the hand gun on the floor and picked up an empty machine gun before pulling the trigger.

The speaker then said quietly: 'You drop one mag, you pick up another, right? Then you pick up another. Then you drop it, you drop the gun, pick up another gun.'

San Diego's Joint Terrorism Task Force linked the video to Homoki and searched his home where several fire arms were found, according to ABC7.

Scott Brunner, San Diego FBI Special-Agent-In-Charge, said in a statement: 'Just three days ago Mr Homoki was an unknown poster of disturbing videos and is now behind bars, his threats neutralized.'

San Diego police did not provide more details on the child endangerment charge of which Homoki is also accused.