MainMenuCamera.re.js 428 B

12345678910111213141516171819202122232425
  1. import * as RE from 'rogue-engine'
  2. import * as THREE from 'three'
  3. export default class MainMenuCamera extends RE.Component {
  4. awake() {
  5. }
  6. start() {
  7. let light = this.object3d.getObjectByName("Directional Light")
  8. if(light == null) {
  9. RE.Debug.logError("Did not find light")
  10. return
  11. }
  12. light.target = new THREE.Object3D()
  13. }
  14. update() {
  15. }
  16. }
  17. RE.registerComponent(MainMenuCamera);