File Author Date Description import * as Sein from 'seinjs' ; import 'seinjs-debug-tools' ; import 'seinjs-dom-hud' ; import { createDefaultCamera } from '../../utils' ; export default class MainScript extends Sein . LevelScriptActor { public onPreload ( ) { const game = this . getGame ( ) ; game . resource . load ( { type : 'Atlas' , name : '22.json' , url : getStaticAssetUrl ( '/assets/sprites/22.json' ) } ) ; game . resource . load ( { type : 'Atlas' , name : '33.json' , url : getStaticAssetUrl ( '/assets/sprites/33.json' ) } ) ; game . resource . cancel ( '22.json' ) ; } public onLoading ( state ) { console . log ( state ) ; } public onCreate ( ) { const game = this . getGame ( ) ; const world = this . getWorld ( ) ; createDefaultCamera ( game , { position : new Sein . Vector3 ( 0 , 0 , - 2 ) , target : new Sein . Vector3 ( 0 , 0 , 0 ) } ) ; const three = world . addActor ( '33' , Sein . SpriteActor , { atlas : game . resource . get < 'Atlas' > ( '33.json' ) , frameName : '01' , width : .66 , height : .9 , materialOptions : { transparent : true } } ) ; three . transform . setPosition ( 1 , 0 , 0 ) ; } }