This commit is contained in:
RandomityGuy 2025-02-10 14:19:02 +05:30
parent fa009ad41b
commit 14fc385ada
2 changed files with 3 additions and 6 deletions

View file

@ -658,6 +658,8 @@ class Marble extends GameObject {
}
function loadMarbleAttributes() {
if (this.level == null || this.level.mission == null)
return;
var attribs = this.level.mission.marbleAttributes;
if (attribs.exists("maxrollvelocity"))
this._maxRollVelocity = MisParser.parseNumber(attribs.get("maxrollvelocity"));

View file

@ -30,12 +30,7 @@ class LeaderboardsGui extends GuiImage {
this.position = new Vector();
this.extent = new Vector(640, 480);
#if hl
var scene2d = hxd.Window.getInstance();
#end
#if js
var scene2d = MarbleGame.instance.scene2d;
#end
var scene2d = MarbleGame.canvas.scene2d;
var offsetX = (scene2d.width - 1280) / 2;
var offsetY = (scene2d.height - 720) / 2;