Actor

From SMTheming Wiki

Jump to: navigation, search

Actor is the main class in StepMania. Pretty much everything is an Actor, including ActorFrames.

StepMania 3.9

In StepMania 3.9, files with the .actor extension are considered Actors, as well as each layer in a BGAnimation.

Example

This .actor file implements a BitmapText object:

[Actor]
Text=example text using .actor file
File=_shared2
OnCommand=
GainFocusCommand=
LoseFocusCommand=
EnabledCommand=
DisabledCommand=

and this BGAnimation file calls the Actor:

[BGAnimation]
 
[Layer1]
File=whatever.actor
Type=0
Command=x,320;y,280;shadowlength,0;rotationy,-10;rotationx,7;rotationz,-5;

StepMania 4.0

Actors are a lot more prominent in StepMania 4. LoadActor will take care of most Actor types for you.

return Def.ActorFrame{
	LoadActor(THEME:GetPathG("Common","window icon"))..{
		InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y+40;shadowlength,0;rotationy,-10;rotationx,7;rotationz,-5;);
	};
};
Personal tools