He has 'a fascination with guns,' a judge concluded