<commit_before>/*
* modified version of THREE.PointerLockControls by mrdoob / http://mrdoob.com
*/

THREE.PointerLockControls = function ( camera ) {

	var scope = this;
	camera.rotation.set( 0, 0, 0 );
	
	var pitchObject = new THREE.Object3D();
	pitchObject.add( camera );

	var yawObject = new THREE.Object3D();
	yawObject.position.y = 10;
	yawObject.add( pitchObject );

	var moveForward = false;
	var moveBackward = false;
	var moveLeft = false;
	var moveRight = false;
	var isOnObject = false;
	var canJump = false;
	var velocity = new THREE.Vector3();
	var PI_2 = Math.PI / 2;

	var onMouseClick = function ( event ) {
		
		if ( scope.enabled === false ) return;

		var d_func = controls.getDirection();
		var d = d_func( new THREE.Vector3() );
		d.multiplyScalar( 10 );
		d.add( yawObject.position );

		var msg = {
			x: d.x,
			y: d.y,
			z: d.z
		};

		ws.send( JSON.stringify(msg) );

	};

	var onMouseMove = function ( event ) {

		if ( scope.enabled === false ) return;

		var movementX = event.movementX || event.mozMovementX || event.webkitMovementX || 0;
		var movementY = event.movementY || event.mozMovementY || event.webkitMovementY || 0;

		yawObject.rotation.y -= movementX * 0.002;
		pitchObject.rotation.x -= movementY * 0.002;

		pitchObject.rotation.x = Math.max( - PI_2, Math.min( PI_2, pitchObject.rotation.x ) );

	};

	var onKeyDown = function ( event ) {
<commit_msg>CUBES IN FRONT OF CAMERA NOW!!!<commit_after>/*
* modified version of THREE.PointerLockControls by mrdoob / http://mrd<EMAIL>
*/

THREE.PointerLockControls = function ( camera ) {

	var scope = this;
	camera.rotation.set( 0, 0, 0 );
	
	var pitchObject = new THREE.Object3D();
	pitchObject.add( camera );

	var yawObject = new THREE.Object3D();
	yawObject.position.y = 10;
	yawObject.add( pitchObject );

	var moveForward = false;
	var moveBackward = false;
	var moveLeft = false;
	var moveRight = false;
	var isOnObject = false;
	var canJump = false;
	var velocity = new THREE.Vector3();
	var PI_2 = Math.PI / 2;

	var onMouseClick = function ( event ) {
		
		if ( scope.enabled === false ) return;

		var d_func = controls.getDirection();
		var d = d_func( new THREE.Vector3() );
		d.multiplyScalar( 50 );
		d.add( yawObject.position );

		var msg = {
			x: d.x,
			y: d.y,
			z: d.z
		};

		ws.send( JSON.stringify(msg) );

	};

	var onMouseMove = function ( event ) {

		if ( scope.enabled === false ) return;

		var movementX = event.movementX || event.mozMovementX || event.webkitMovementX || 0;
		var movementY = event.movementY || event.mozMovementY || event.webkitMovementY || 0;

		yawObject.rotation.y -= movementX * 0.002;
		pitchObject.rotation.x -= movementY * 0.002;

		pitchObject.rotation.x = Math.max( - PI_2, Math.min( PI_2, pitchObject.rotation.x ) );

	};

	var onKeyDown = function ( event ) {

{'fraction_non_alphanumeric': 0.1379800853485064, 'fraction_numerical': 0.017780938833570414, 'mean_word_length': 3.3343605546995376, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '902334', 'n_tokens_mistral': 1123, 'n_tokens_neox': 988, 'n_words': 253}