mirror of
https://github.com/RandomityGuy/MBHaxe.git
synced 2025-10-30 08:11:25 +00:00
fix this
This commit is contained in:
parent
fa009ad41b
commit
14fc385ada
2 changed files with 3 additions and 6 deletions
|
|
@ -658,6 +658,8 @@ class Marble extends GameObject {
|
||||||
}
|
}
|
||||||
|
|
||||||
function loadMarbleAttributes() {
|
function loadMarbleAttributes() {
|
||||||
|
if (this.level == null || this.level.mission == null)
|
||||||
|
return;
|
||||||
var attribs = this.level.mission.marbleAttributes;
|
var attribs = this.level.mission.marbleAttributes;
|
||||||
if (attribs.exists("maxrollvelocity"))
|
if (attribs.exists("maxrollvelocity"))
|
||||||
this._maxRollVelocity = MisParser.parseNumber(attribs.get("maxrollvelocity"));
|
this._maxRollVelocity = MisParser.parseNumber(attribs.get("maxrollvelocity"));
|
||||||
|
|
|
||||||
|
|
@ -30,12 +30,7 @@ class LeaderboardsGui extends GuiImage {
|
||||||
this.position = new Vector();
|
this.position = new Vector();
|
||||||
this.extent = new Vector(640, 480);
|
this.extent = new Vector(640, 480);
|
||||||
|
|
||||||
#if hl
|
var scene2d = MarbleGame.canvas.scene2d;
|
||||||
var scene2d = hxd.Window.getInstance();
|
|
||||||
#end
|
|
||||||
#if js
|
|
||||||
var scene2d = MarbleGame.instance.scene2d;
|
|
||||||
#end
|
|
||||||
|
|
||||||
var offsetX = (scene2d.width - 1280) / 2;
|
var offsetX = (scene2d.width - 1280) / 2;
|
||||||
var offsetY = (scene2d.height - 720) / 2;
|
var offsetY = (scene2d.height - 720) / 2;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue