Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
    <title>A-Frame Getting Started</title>
    <script src="https://cdn.rawgit.com/AdaRoseEdwards/aframe/v0.3.3-ada/dist/aframe.min.js"></script>
    <script src="https://cdn.rawgit.com/donmccurdy/aframe-physics-system/v1.0.3/dist/aframe-physics-system.js"></script>
</head>
<body>
    <a-scene physics fog="type: linear; color: #AAB; far: 10; near: 0">
        <a-assets>
            <!-- image to use on the floor -->
            <img src="https://img.gs/bbdkhfbzkk/stretch/https://i.imgur.com/25P1geh.png" id="grid" crossorigin="anonymous">
        </a-assets>
        <!-- camera with a sphere around it to push objects -->
        <a-camera universal-controls>
            <a-entity static-body visible="false" geometry="primitive: sphere;"></a-entity>
        </a-camera>
        <!-- blue ball -->
        <a-entity dynamic-body geometry="primitive: sphere;" position="0 2 -5" material="color:blue;"></a-entity>
        <!-- floor -->
        <a-entity position="0 0 0" rotation="-90 0 0" static-body geometry="primitive: plane; width: 100; height: 100;" material="src: #grid; repeat: 100 100; transparent: true;"></a-entity>
        <!-- sky -->
        <a-sky color="#AAB"></a-sky>
    </a-scene>
</body>
</html>
 
// A-Frame Physics Playground
var scene = document.querySelector('a-scene');
if (scene.hasLoaded) {
  run();
} else {
  scene.addEventListener('loaded', run);
}
function run () {
    // Run javascript here
}
Output 300px

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
AdaRoseEdwardspro
0viewers