fix html compile issues
This commit is contained in:
@@ -1,7 +1,5 @@
|
|||||||
package;
|
package;
|
||||||
|
|
||||||
|
|
||||||
import webm.WebmPlayer;
|
|
||||||
import openfl.display.BlendMode;
|
import openfl.display.BlendMode;
|
||||||
import openfl.text.TextFormat;
|
import openfl.text.TextFormat;
|
||||||
import openfl.display.Application;
|
import openfl.display.Application;
|
||||||
@@ -77,10 +75,12 @@ class Main extends Sprite
|
|||||||
gameHeight = Math.ceil(stageHeight / zoom);
|
gameHeight = Math.ceil(stageHeight / zoom);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if cpp
|
||||||
initialState = Caching;
|
initialState = Caching;
|
||||||
|
|
||||||
game = new FlxGame(gameWidth, gameHeight, initialState, zoom, framerate, framerate, skipSplash, startFullscreen);
|
game = new FlxGame(gameWidth, gameHeight, initialState, zoom, framerate, framerate, skipSplash, startFullscreen);
|
||||||
|
#else
|
||||||
|
game = new FlxGame(gameWidth, gameHeight, initialState, zoom, framerate, framerate, skipSplash, startFullscreen);
|
||||||
|
#end
|
||||||
addChild(game);
|
addChild(game);
|
||||||
|
|
||||||
#if !mobile
|
#if !mobile
|
||||||
|
|||||||
@@ -6,7 +6,9 @@ import openfl.ui.Keyboard;
|
|||||||
import openfl.events.KeyboardEvent;
|
import openfl.events.KeyboardEvent;
|
||||||
import Replay.Ana;
|
import Replay.Ana;
|
||||||
import Replay.Analysis;
|
import Replay.Analysis;
|
||||||
|
#if cpp
|
||||||
import webm.WebmPlayer;
|
import webm.WebmPlayer;
|
||||||
|
#end
|
||||||
import flixel.input.keyboard.FlxKey;
|
import flixel.input.keyboard.FlxKey;
|
||||||
import haxe.Exception;
|
import haxe.Exception;
|
||||||
import openfl.geom.Matrix;
|
import openfl.geom.Matrix;
|
||||||
@@ -3352,6 +3354,7 @@ class PlayState extends MusicBeatState
|
|||||||
|
|
||||||
public function backgroundVideo(source:String) // for background videos
|
public function backgroundVideo(source:String) // for background videos
|
||||||
{
|
{
|
||||||
|
#if cpp
|
||||||
useVideo = true;
|
useVideo = true;
|
||||||
|
|
||||||
FlxG.stage.window.onFocusOut.add(focusOut);
|
FlxG.stage.window.onFocusOut.add(focusOut);
|
||||||
@@ -3402,6 +3405,7 @@ class PlayState extends MusicBeatState
|
|||||||
webmHandler.pause();
|
webmHandler.pause();
|
||||||
else
|
else
|
||||||
webmHandler.resume();
|
webmHandler.resume();
|
||||||
|
#end
|
||||||
}
|
}
|
||||||
|
|
||||||
function noteMiss(direction:Int = 1, daNote:Note):Void
|
function noteMiss(direction:Int = 1, daNote:Note):Void
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
package;
|
package;
|
||||||
|
|
||||||
|
#if sys
|
||||||
import smTools.SMFile;
|
import smTools.SMFile;
|
||||||
|
#end
|
||||||
import flixel.FlxG;
|
import flixel.FlxG;
|
||||||
import flixel.FlxSprite;
|
import flixel.FlxSprite;
|
||||||
import flixel.FlxState;
|
import flixel.FlxState;
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
#if sys
|
||||||
package smTools;
|
package smTools;
|
||||||
|
|
||||||
import sys.io.File;
|
import sys.io.File;
|
||||||
@@ -56,4 +57,5 @@ class SMFile
|
|||||||
}
|
}
|
||||||
trace(measures.length + " Measures");
|
trace(measures.length + " Measures");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#end
|
||||||
@@ -1,3 +1,4 @@
|
|||||||
|
#if sys
|
||||||
package smTools;
|
package smTools;
|
||||||
|
|
||||||
class SMHeader
|
class SMHeader
|
||||||
@@ -34,4 +35,5 @@ class SMHeader
|
|||||||
Reflect.setProperty(this,propName,value);
|
Reflect.setProperty(this,propName,value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#end
|
||||||
@@ -1,3 +1,4 @@
|
|||||||
|
#if sys
|
||||||
package smTools;
|
package smTools;
|
||||||
|
|
||||||
class SMMeasure
|
class SMMeasure
|
||||||
@@ -11,4 +12,5 @@ class SMMeasure
|
|||||||
_measure = measureData;
|
_measure = measureData;
|
||||||
notes = [];
|
notes = [];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#end
|
||||||
@@ -1,3 +1,4 @@
|
|||||||
|
#if sys
|
||||||
package smTools;
|
package smTools;
|
||||||
|
|
||||||
class SMNote
|
class SMNote
|
||||||
@@ -5,4 +6,5 @@ class SMNote
|
|||||||
public var time:Float;
|
public var time:Float;
|
||||||
public var data:Int;
|
public var data:Int;
|
||||||
public var length:Float;
|
public var length:Float;
|
||||||
}
|
}
|
||||||
|
#end
|
||||||
Reference in New Issue
Block a user