Drag the background!

Search JS code (of Worlds)

Search JavaScript code of all Worlds for: ABWorld camera


Ammo for AB
62 runs ♦ 0 likes
By Starter user  
Created: 19 Apr 2021
Modified: 19 Apr 2021
Ammo world for AB API
ABWorld.camera = new THREE.PerspectiveCamera ( 50, window.innerWidth / window.innerHeight, 0.1, maxRadius ); // near value of 0.1 to allow camera get closer to boxes
Model World
671 runs ♦ 2 likes
By Starter user  
Created: 8 Nov 2016
Modified: 18 Apr 2021
Demo of how to insert 3d models into World. Mind-controlled agent, actively-pursuing enemy. Skybox.
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
Touch World
355 runs ♦ 1 like
By Starter user  
Created: 6 Jan 2018
Modified: 18 Apr 2021
How to override default touch handling. Mobile: Touch drag moves agent, touch pinch zooms camera...
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
Collision World
1125 runs ♦ 4 likes
By Starter user  
Created: 21 Sep 2017
Modified: 4 Jul 2021
Demo of Physics API. Blocks fall under gravity and collide. Can modify gravity, friction, etc. S...
ABWorld.init3d ( startRadius, maxRadius, SKYCOLOR ); // sets up renderer, scene, camera
MineCraft
843 runs ♦ 2 likes
By Starter user  
Created: 27 Nov 2016
Modified: 4 Jul 2021
Use keyboard to draw blocks like in MineCraft. Use arrow keys and PgUp, PgDn to draw. Can save w...
ABWorld.drawCameraControls = false;
Bouncy Balls
443 runs ♦ 3 likes
By Starter user  
Created: 1 Oct 2017
Modified: 4 Jul 2021
Demo of Physics API. Balls bounce under gravity and collide in low friction world. Splash screen...
ABWorld.drawCameraControls = false;
ABWorld.init3d ( startRadius, maxRadius, SKYCOLOR ); // sets up renderer, scene, camera
Complex World
6468 runs ♦ 3 likes
By Starter user  
Created: 1 Oct 2016
Modified: 18 Apr 2021
World with a Mind-controlled agent, actively-pursuing enemy, random maze, skybox, music.
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
Castle World
616 runs ♦ 4 likes
By Starter user  
Created: 11 Nov 2016
Modified: 4 Jul 2021
Demo of how to insert 3d model into World. Mind-controlled agent, actively-pursuing enemy. Splas...
ABWorld.drawCameraControls = false;
Simple World
1368 runs ♦ 2 likes
By Starter user  
Created: 1 Oct 2016
Modified: 18 Apr 2021
Simple World with a Mind-controlled agent, randomly-moving enemy, paint blocks with texture.
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
Blank Three.js World
1152 runs ♦ 2 likes
By Starter user  
Created: 20 Nov 2016
Modified: 18 Apr 2021
A simple starter World. An Array of spheres. Painted with textures. Random motion.
ABWorld.drawCameraControls = false;
Websockets boxes
257 runs ♦ 0 likes
By Starter user  
Created: 29 Feb 2020
Modified: 4 Jul 2021
Demo of Websockets in 3D World. Click to change the boxes on the other user's machine, while the...
ABWorld.drawCameraControls = false;
Zombie Death Baby
561 runs ♦ 1 like
By Starter user  
Created: 11 Jun 2018
Modified: 4 Jul 2021
How to make a fun touch game for mobile. Touch drag and tap objects. Mouse drag and click object...
ABWorld.drawCameraControls = false;
User-controlled ...
636 runs ♦ 2 likes
By Starter user  
Created: 12 Feb 2017
Modified: 18 Apr 2021
3d model World. User controlled on desktop. Keyboard arrows to move. Switch to "Move with" camer...
ABWorld.follow.x = ABWorld.follow.x + ( CAMERASHIFT * Math.sin(agentRotation) );
ABWorld.follow.z = ABWorld.follow.z + ( CAMERASHIFT * Math.cos(agentRotation) );
Final Pool
979 runs ♦ 2 likes
By Ian Gilligan  
Created: 1 Mar 2019
Modified: 13 Aug 2019
Pool Predictor for CA326
ABWorld.drawCameraControls = false;
ABWorld.camera.position.set(0,100,0);
ABWorld.camera.position.set(50,50,30);
ABWorld.camera.position.set(50,50,-30);
ABWorld.camera.position.set(-50,50,-30);
ABWorld.camera.position.set(-50,50, 30);
ABWorld.init3d(startRadius, maxRadius, SKYCOLOR); // sets up renderer, scene, camera
CA318 2018 World
2063 runs ♦ 3 likes
By Mark Humphrys  
Created: 25 Sep 2018
Modified: 24 Mar 2019
CA318 practical 2018: Write a Mind to solve this World.
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
Expo World
168 runs ♦ 0 likes
By Mark Humphrys  
Created: 17 Oct 2018
Modified: 24 Mar 2019
Infinite changing demo for expos.
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
ABWorld.cameraTrack()
ABWorld.cameraMove()
ABWorld.cameraFixed()
Port of flying b...
395 runs ♦ 0 likes
By Discover three.js  
Created: 10 Feb 2019
Modified: 24 Mar 2019
Animated models. Port of flying birds with GLB models. From "Discover three.js". See project inf...
ABWorld.drawCameraControls = false;
1. Shapes
143 runs ♦ 0 likes
By "3D Game Program...  
Created: 16 Aug 2018
Modified: 24 Mar 2019
Port of code "shapes" from Ch.1
ABWorld.drawCameraControls = false;
3. Making an Avatar
101 runs ♦ 0 likes
By "3D Game Program...  
Created: 16 Aug 2018
Modified: 24 Mar 2019
Port of code "building_an_avatar" from Ch.3
ABWorld.drawCameraControls = false;
MineCraft (clone...
4 runs ♦ 0 likes
By Alex Murphy  
Created: 10 May 2019
Modified: 10 May 2019
Clone of "MineCraft" by Starter user
ABWorld.drawCameraControls = false;
Cloned Complex World
4 runs ♦ 0 likes
By Mathias Bazin  
Created: 10 Aug 2018
Modified: 10 Aug 2018
Clone of "Complex World" by Starter user
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
Tutorial : Contr...
11 runs ♦ 0 likes
By Nathan Bonnard  
Created: 14 Aug 2018
Modified: 14 Aug 2018
Tutorial for movement depending on camera position & Velocity
if((ABWorld.camera.rotation.y >= -Math.PI / 4 && ABWorld.camera.rotation.y <= Math.PI / 4) &&
(ABWorld.camera.rotation.x >= -Math.PI / 2 && ABWorld.camera.rotation.x <= 0) &&
(ABWorld.camera.rotation.z >= -Math.PI / 4 && ABWorld.camera.rotation.z <= Math.PI / 4))
else if((ABWorld.camera.rotation.y >= -Math.PI / 4 && ABWorld.camera.rotation.y <= Math.PI / 4) &&
(ABWorld.camera.rotation.x >= -Math.PI && ABWorld.camera.rotation.x <= -Math.PI / 2) &&
(ABWorld.camera.rotation.z >= 3 * Math.PI / 4 || ABWorld.camera.rotation.z <= -3 * Math.PI / 4))
else if((ABWorld.camera.rotation.y >= 0 && ABWorld.camera.rotation.y <= Math.PI / 2) &&
(ABWorld.camera.rotation.x >= -Math.PI && ABWorld.camera.rotation.x <= 0) &&
(ABWorld.camera.rotation.z >= 0 && ABWorld.camera.rotation.z <= Math.PI))
else if((ABWorld.camera.rotation.y >= -Math.PI / 2 && ABWorld.camera.rotation.y <= 0) &&
Complex World (c...
1 run ♦ 0 likes
By Piyush Wadhai  
Created: 13 Nov 2021
Modified: 13 Nov 2021
Clone of "Complex World" by Starter user
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
maze runner
18 runs ♦ 0 likes
By rohan  
Created: 29 Oct 2021
Modified: 4 Nov 2021
Clone of "Complex World (clone by rohan)" by rohan
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
CA1 (no diagonal)
44 runs ♦ 0 likes
By Cian  
Created: 17 Nov 2021
Modified: 17 Nov 2021
Clone of "CA1" by Cian
ABWorld.lookat.copy(theenemy.position); // if camera moving, look back at where the enemy is
Ian Gilligan v0....
1 run ♦ 0 likes
By Ian Gilligan  
Created: 6 Feb 2019
Modified: 6 Feb 2019
Clone of "v0.4 Pool Predictor Prototype" by Ian Gilligan
ABWorld.drawCameraControls = false;
ABWorld.init3d(startRadius, maxRadius, SKYCOLOR); // sets up renderer, scene, camera
Simple World (c...
0 runs ♦ 0 likes
By Brendan  
Created: 28 Oct 2019
Modified: 28 Oct 2019
Clone of "Simple World" by Starter user
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
Blank Three.js W...
17 runs ♦ 0 likes
By Patrick Travers  
Created: 7 Oct 2021
Modified: 7 Oct 2021
Clone of "Blank Three.js World" by Starter user
ABWorld.drawCameraControls = false;
seytan6161 Model...
0 runs ♦ 0 likes
By seytan6161  
Created: 12 Mar 2019
Modified: 12 Mar 2019
Clone of "Model World" by Starter user
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)
Complex World (c...
0 runs ♦ 0 likes
By Abdelshafa Abdala  
Created: 1 Nov 2021
Modified: 1 Nov 2021
Clone of "Complex World" by Starter user
ABWorld.lookat.copy ( theenemy.position ); // if camera moving, look back at where the enemy is
ABWorld.follow.copy ( theagent.position ); // follow vector = agent position (for camera following agent)


The background is a program, showing the JavaScript graphics used on this site.
The globes light up when you log in.
 
Font:

Website copyright Ancient Brain. 2018-2021.
Users retain ownership of user content.

Platforms      Stats      The name      Terms and conditions

Call for partners      Contact

Call for partners!
If you are interested in writing a programming course, textbook or tutorial videos, Ancient Brain is looking for partners. We will work with you, and integrate your course into the site. This is an opportunity for someone looking to develop a course or textbook to partner with a site to support it and promote it.