1.3.1 • Published 5 years ago

aframe-supercraft-thing v1.3.1

Weekly downloads
7
License
MIT
Repository
-
Last release
5 years ago

supercraft-thing

A component for extracting things from Supercraft scenes.

For A-Frame and Supercraft.

API

PropertyDescriptionDefault Value
fromselector to supercraft-loader entity''
namename of the thing''
resetOriginset local coordinates of the thing in its center (by default is on 0,0,0)false
ignorePositionif true, position will be initialized to current entity's position instead of the position in the supercraft scenefalse

Installation

Browser

Install and use by directly including the browser files:

<head>
  <script src="https://aframe.io/releases/0.8.2/aframe.min.js"></script>
  <script src="https://unpkg.com/aframe-supercraft-loader/dist/aframe-supercraft-loader.min.js"></script>
  <script src="https://unpkg.com/aframe-supercraft-thing/dist/aframe-supercraft-thing.min.js"></script>
</head>

<body>
  <a-scene>
    <a-entity id="scene" supercraft-loader="name: respectful-master"></a-entity>
    <a-entity supercraft-thing="from:#scene; name: thing1"></a-entity>
  </a-scene>
</body>

npm

Install via npm:

npm install aframe-supercraft-thing

Then require and use.

require('aframe');
require('aframe-supercraft-loader');
require('aframe-supercraft-thing');