You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
arthursw edited this page May 4, 2016
·
1 revision
functioncompile(x){returnrequire('uclass')()(global,x)}classMyComponent/*EditInlineNew*/extendsActorComponent{ctor(){this.Param1=23this.Param2={X:1,Y:2,Z:3}}properties(){this.Param1/*EditAnywhere+BlueprintReadOnly+Category:Javascript+int*/;this.Param2/*EditAnywhere+Category:Javascript+Vector*/;}}letMyComponent_C=compile(MyComponent)classMyActorextendsActor{// pre-ctor; you can switch subobject to another class defined in super class.prector(){MyMovementComponent_C.SetDefaultSubobjectClass("CharMoveComp")}ctor(){this.MyComponent=MyComponent_C.CreateDefaultSubobject("MyComponent")}properties(){this.MyComponent/*VisibleAnywhere+Category:Javascript+MyComponent*/;}}letMyActor_C=compile(MyActor)letactor=Actor.C(newMyActor_C(GWorld))