Basics
Guides
API Reference
Basics
Guides
API Reference
[20:7] extends: Scene
Wraps FXGL's FXGLScene, the abstract base for every FXGL-engine scene (GameScene, LoadingScene, FXGLMenu). FXGLScene adds a Viewport, padding rectangles, and shortcuts for setting the cursor and background. The constructor requires a running FXGL engine because it reads the application width / height from FXGL.getAppWidth / getAppHeight at init time. Aussom users hold an FXGLScene wrapper via adopt after obtaining one from the engine; direct construction from Aussom is not supported here.
FXGLScene ()
Empty default constructor; populated by adopt.
adopt (object Ajo)
Wraps an existing FXGLScene AussomJavaObject.
Ajo is an AussomJavaObject around an FXGLScene.A new wrapper.getAppWidth ()
Returns the application width passed at scene construction.
An int.getAppHeight ()
Returns the application height passed at scene construction.
An int.setBackgroundColor (object ColorObj)
Sets the scene background to a solid color.
ColorObj is a Color wrapper.this objectgetViewport ()
Returns the scene's Viewport (used for camera pan / zoom / follow). The Viewport is the standard way for game code to scroll the game scene around the world.
An AussomJavaObject around a Viewport.getWidth ()
Returns the scaled scene width in pixels.
A double.getHeight ()
Returns the scaled scene height in pixels.
A double.getPaddingTop ()
Returns the top padding rectangle (used for letterboxing).
An AussomJavaObject around a JavaFX Rectangle.getPaddingBot ()
Returns the bottom padding rectangle.
An AussomJavaObject around a JavaFX Rectangle.getPaddingLeft ()
Returns the left padding rectangle.
An AussomJavaObject around a JavaFX Rectangle.getPaddingRight ()
Returns the right padding rectangle.
An AussomJavaObject around a JavaFX Rectangle.setCursor (object CursorObj)
Sets the scene mouse cursor.
CursorObj is an AussomJavaObject around a JavaFX Cursor.this objectsetImageCursor (object ImageObj, double HotspotX, double HotspotY)
Sets a custom image cursor with a hotspot.
ImageObj is a fx.Image wrapper.HotspotX is the hotspot X.HotspotY is the hotspot Y.this objectsetCursorInvisible ()
Hides the cursor while it is over this scene.
this objectisCursorInvisible ()
Returns whether the cursor is currently set invisible.
A bool.activeProperty ()
Returns the active-state BooleanProperty for this scene (true while the scene is on top of the scene stack).
An AussomJavaObject around a BooleanProperty.setEffect (object EffectObj)
Applies a JavaFX Effect to the scene root.
EffectObj is an AussomJavaObject around an Effect, or null to clear.this objectgetEffect ()
Returns the current scene Effect.
An AussomJavaObject around an Effect, or null.clearEffect ()
Clears any applied Effect.
this objectappendCSS (string Css)
Appends a stylesheet by URL string to the scene.
Css is the stylesheet URL.this objectclearCSS ()
Clears every stylesheet from the scene.
this objectsetBackgroundRepeat (string ImageName)
Sets the scene background to a tiled image by name (looked up through the AssetLoader).
ImageName is the image asset name.this objectsetBackgroundRepeatImage (object ImageObj)
Sets the scene background to a tiled JavaFX Image.
ImageObj is a fx.Image wrapper.this object
Aussom
Write once. Embed everywhere.
Copyright 2026 Austin Lehman. All rights reserved.