class ScriptBehavior extends Sup.Behavior
{
Test1 : Sup.Actor;
awake()
{
let MainCameraMan = new Sup.Actor("CamMain1");
//MainCameraMan.camera = new Sup.Camera(MainCameraMan);
// MainCameraMan.setPosition(0, 0, 0);
new Sup.Camera(MainCameraMan);
MainCameraMan.setPosition(0, 0, 0);
this.Test1 = new Sup.Actor("Derp");
this.Test1.setPosition(0, 0, 0);
new Sup.SpriteRenderer(this.Test1, "GameSprites/background1");
//Derp.spriteRenderer.setSprite("GameSprites/background1");
}
update()
{
}
}
Sup.registerBehavior(ScriptBehavior);
this is in a file script, and its added to a Empty actor in my start up scene (which is set to load on start), it gives me no errors and loads the screen as a BLACK object. The debugger is hard to figure out so I cant understand if something is spawning like it should or not. (unlike cosntruct 2 which is easy to see all entties in scene), anyway, Im just wondering WHAT am i doing wrong if it throws no errors? (again, this behavior has been added to an actor that is saved to the scene itself, no default camera tho, I wanted to instantiate one.) my only guess is, like in perhaps other javascript style use, I created the camera but did not append it to the scene, so its only stored as a variable and not in the scene yet?? thats weird.. doubt it cuz this engine is different?