Skip to content

3D Rotation system for FlxSprites and FlxTexts with perspective and depth

License

Notifications You must be signed in to change notification settings

Blossomical/flixel-perspective

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

flixel-perspective

3D Rotation system for FlxSprites and FlxTexts with perspective and depth

EXAMPLE USAGE:

text = new PerspectiveText(0, 0, 0, 0, 'Hello World', 50);
add(text.screenCenter());
text.useDepthColor = true;
text.depthColor = 0xFF150523;
//
text.z += FlxG.mouse.wheel * 3;
text.angleY += (FlxG.keys.pressed.D ? 1 : (FlxG.keys.pressed.A ? -1 : 0));
text.angleX += (FlxG.keys.pressed.S ? 1 : (FlxG.keys.pressed.W ? -1 : 0));
phdjcs.mp4
sprite = new PerspectiveSprite(0);
add(sprite.loadGraphic('assets/images/missing').screenCenter());
sprite.screenCenter();
sprite.useDepthColor = true;
//
sprite.z += FlxG.mouse.wheel * 3;
sprite.angleY += (FlxG.keys.pressed.D ? 1 : (FlxG.keys.pressed.A ? -1 : 0));
sprite.angleX += (FlxG.keys.pressed.S ? 1 : (FlxG.keys.pressed.W ? -1 : 0));
2cntnr.mp4

About

3D Rotation system for FlxSprites and FlxTexts with perspective and depth

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages