Same as Settings, but for app startup (inside Project.new(settings)). Read-only values can still be edited at that stage.
Variables
targetWidth:Int
Target width. Affects window size at startup and affects screen scaling at any time. Ignored if set to 0 (default)
targetHeight:Int
Target height. Affects window size at startup and affects screen scaling at any time. Ignored if set to 0 (default)
targetDensity:Int
Target density. Affects the quality of textures being loaded. Changing it at runtime will update texture quality if needed. Ignored if set to 0 (default)
maxDelta:Float
Maximum app update delta time.
During app update (at each frame), app.delta
will be capped to maxDelta
if its value is above maxDelta
.
If needed, use app.realDelta
to get real elapsed time since last frame.
overrideDelta:Float
Override app update delta time. This can be used to ignore completely the actual elapsed time between frames and replace it with an explicit delta time of your choice. This will affect timers, tween, systems update etc... Use with caution.
preventDefaultMouseWheel:Bool
If set to true
(default). Default mouse wheel events
will be prevented. This is relevant when running the ceramic
app from an iframe
inside a page that can scroll.
preventDefaultTouches:Bool
If set to true
(default). Default touch events
will be prevented. This is relevant when running the ceramic
app from an iframe
inside a page that can scroll,
on a touchscreen device.
orientation:ScreenOrientation
Setup screen orientation. Default is NONE
,
meaning nothing is enforced and project defaults will be used.
Methods
inlinetargetSize(targetWidth:Int, targetHeight:Int):Void
Target width and height. Affects window size at startup and affects screen scaling at any time. Ignored if set to 0 (default)
Parameters:
targetWidth | Target width |
---|---|
targetHeight | Target height |
inlinewindowSize(windowWidth:Int, windowHeight:Int):Void
Target window width and height at startup
Uses targetWidth
and targetHeight
as fallback if set to 0 (default)
Parameters:
windowWidth | Window width |
---|---|
windowHeight | Window height |