index.js 586 B

1234567891011121314151617181920212223242526
  1. Component({
  2. behaviors: [require('../common/share-behavior').default],
  3. properties: {
  4. envIndex: {
  5. type: Number,
  6. value: 0
  7. }
  8. },
  9. data: {
  10. loaded: false
  11. },
  12. lifetimes: {},
  13. methods: {
  14. handleReady({detail}) {
  15. const xrScene = this.scene = detail.value;
  16. console.log('xr-scene', xrScene);
  17. },
  18. handleAssetsProgress: function({detail}) {
  19. console.log('assets progress', detail.value);
  20. },
  21. handleAssetsLoaded: function({detail}) {
  22. console.log('assets loaded', detail.value);
  23. this.setData({loaded: true});
  24. }
  25. }
  26. })