Skip to content

Commit

Permalink
umm things
Browse files Browse the repository at this point in the history
  • Loading branch information
Joalor64GH authored Aug 23, 2023
1 parent eb6d08d commit 657022d
Show file tree
Hide file tree
Showing 8 changed files with 189 additions and 13 deletions.
156 changes: 156 additions & 0 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,156 @@
name: Nightly Build

on:
# push:
# branches: [ main ]
# pull_request:
# branches: [ main ]

workflow_dispatch:

jobs:
buildLinux:
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@main

- uses: krdlab/setup-haxe@master
with:
haxe-version: 4.2.5
- name: Install Haxelib
run: |
sudo apt-get update
sudo apt-get install gcc-multilib g++-multilib haxe -y
sudo apt-get install libvlc-dev
sudo apt-get install libvlccore-dev
sudo apt-get install vlc-bin
sudo apt-get -y install libidn12
haxelib setup ~/haxelib
haxelib install hxcpp > /dev/null
haxelib install lime
haxelib install openfl
haxelib --never install flixel 5.2.2
haxelib run lime setup flixel
haxelib run lime setup
haxelib install flixel-tools
haxelib install flixel-ui
haxelib git flixel-addons https://github.com/HaxeFlixel/flixel-addons.git dev
haxelib install hxCodec 2.5.1
haxelib install swf 3.2.0
haxelib git djFlixel https://github.com/john32b/djFlixel
haxelib git polymod-joalor64 https://github.com/Joalor64GH/polymod-joalor64
haxelib git fnf-modcharting-tools https://github.com/TheZoroForce240/FNF-Modcharting-Tools
haxelib git linc_luajit https://github.com/nebulazorua/linc_luajit
haxelib git hxvm-luajit https://github.com/nebulazorua/hxvm-luajit
haxelib install SScript 4.0.0
haxelib git hscript-yoshiengine https://github.com/YoshiCrafter29/hscript-improved
haxelib git hscript-ex https://github.com/ianharrigan/hscript-ex
haxelib git discord_rpc https://github.com/Aidan63/linc_discord-rpc
haxelib git extension-webm https://github.com/KadeDev/extension-webm
haxelib run lime rebuild extension-webm linux
haxelib install hxcpp-debug-server
haxelib install actuate
haxelib list
- name: Create Version Tag
run: echo "${{github.run_id}}" > VERSION
- name: Compile
run: haxelib run lime build Project.xml linux -Dnightly --app-version="4.0.0-${{ github.run_id}}"
- name: Publish Artifact
uses: actions/upload-artifact@main
with:
name: linuxBuild
path: 'export/release/linux/bin'
buildWindows64:
runs-on: windows-latest

steps:
- uses: actions/checkout@main

- uses: krdlab/setup-haxe@master
with:
haxe-version: 4.2.5
- name: Install Haxelib
run: |
haxelib setup C:/haxelib
haxelib install hxcpp > nul
haxelib install lime
haxelib install openfl
haxelib --never install flixel 5.2.2
haxelib run lime setup flixel
haxelib run lime setup
haxelib install flixel-tools
haxelib install flixel-ui
haxelib git flixel-addons https://github.com/HaxeFlixel/flixel-addons.git dev
haxelib install hxCodec 2.5.1
haxelib install swf 3.2.0
haxelib git djFlixel https://github.com/john32b/djFlixel
haxelib git polymod-joalor64 https://github.com/Joalor64GH/polymod-joalor64
haxelib git fnf-modcharting-tools https://github.com/TheZoroForce240/FNF-Modcharting-Tools
haxelib git linc_luajit https://github.com/nebulazorua/linc_luajit
haxelib git hxvm-luajit https://github.com/nebulazorua/hxvm-luajit
haxelib install SScript 4.0.0
haxelib git hscript-yoshiengine https://github.com/YoshiCrafter29/hscript-improved
haxelib git hscript-ex https://github.com/ianharrigan/hscript-ex
haxelib git discord_rpc https://github.com/Aidan63/linc_discord-rpc
haxelib git extension-webm https://github.com/KadeDev/extension-webm
haxelib run lime rebuild extension-webm windows
haxelib install hxcpp-debug-server
haxelib install actuate
haxelib list
shell: cmd
- name: Create Version Tag
run: echo "${{github.run_id}}" > VERSION
- name: Compile
run: haxelib run lime build windows -Dnightly --app-version="4.0.0-${{ github.run_id}}"
- name: Publish Artifact
uses: actions/upload-artifact@main
with:
name: windows64Build
path: export/release/windows/bin
buildMacOS:
runs-on: macos-latest

steps:
- uses: actions/checkout@main

- uses: krdlab/setup-haxe@master
with:
haxe-version: 4.2.5
- name: Install Haxelib
run: |
haxelib setup ~/haxelib
haxelib install hxcpp > /dev/null
haxelib install lime
haxelib install openfl
haxelib --never install flixel 5.2.2
haxelib run lime setup flixel
haxelib run lime setup
haxelib install flixel-tools
haxelib install flixel-ui
haxelib git flixel-addons https://github.com/HaxeFlixel/flixel-addons.git dev
haxelib install hxCodec 2.5.1
haxelib install swf 3.2.0
haxelib git djFlixel https://github.com/john32b/djFlixel
haxelib git polymod-joalor64 https://github.com/Joalor64GH/polymod-joalor64
haxelib git fnf-modcharting-tools https://github.com/TheZoroForce240/FNF-Modcharting-Tools
haxelib git linc_luajit https://github.com/nebulazorua/linc_luajit
haxelib git hxvm-luajit https://github.com/nebulazorua/hxvm-luajit
haxelib install SScript 4.0.0
haxelib git hscript-yoshiengine https://github.com/YoshiCrafter29/hscript-improved
haxelib git hscript-ex https://github.com/ianharrigan/hscript-ex
haxelib git discord_rpc https://github.com/Aidan63/linc_discord-rpc
haxelib git extension-webm https://github.com/KadeDev/extension-webm
haxelib run lime rebuild extension-webm mac
haxelib install hxcpp-debug-server
haxelib install actuate
haxelib list
- name: Create Version Tag
run: echo "${{github.run_id}}" > VERSION
- name: Compile
run: haxelib run lime build mac -Dnightly --app-version="4.0.0-${{ github.run_id}}"
- name: Publish Artifact
uses: actions/upload-artifact@main
with:
name: macOSBuild
path: export/release/macos/bin
16 changes: 13 additions & 3 deletions Project.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

<!-- Application Window Title and Executable File Name -->
<app title="Friday Night Funkin': Joalor64 Engine Rewritten" />

<app file="J64EngineRE_WIN" if="windows" />
<app file="J64EngineRE_APP" if="linux" />
<app file="J64EngineRE_MAC" if="mac" />
Expand All @@ -15,6 +16,13 @@
<app file="J64EngineRE_MAC DEBUG" if="mac" />
</section>

<!-- For nightly builds -->
<section if="nightly">
<app file="J64EngineRE_WIN NIGHTLY" if="windows" />
<app file="J64EngineRE_APP NIGHTLY" if="linux" />
<app file="J64EngineRE_MAC NIGHTLY" if="mac" />
</section>

<!-- Package Name (Mac) -->
<app package="com.joalor64gh.j64enginere" />

Expand Down Expand Up @@ -166,7 +174,7 @@
<haxedef name="no-deprecation-warnings"/>
</section>

<!--Used for Izzy Engine's crash handler-->
<!--Crash screen stuff-->
<section if="CRASH_HANDLER">
<haxedef name="HXCPP_CHECK_POINTER" />
<haxedef name="HXCPP_STACK_LINE" />
Expand All @@ -182,14 +190,16 @@
<haxeflag name="--macro" value="allowPackage('flash')" />
<haxeflag name="--macro" value="include('my.pack')" />

<!-- _________________________________ Miscellaneous _______________________________ -->
<!-- _________________________________ Icons _______________________________ -->

<assets path='art/iconOG.png' rename='icon.png' if="linux" /> <!-- workaround for linux -->

<icon path="art/icon16.png" size='16'/>
<icon path="art/icon32.png" size='32'/>
<icon path="art/icon64.png" size='64'/>
<icon path="art/iconOG.png" />

<!-- ________________________ Import Platform-Specific Stuff _____________________________ -->
<!-- _________________________________ Miscellaneous _______________________________ -->

<target id="haxe" tool="linker" if="linux">
<lib name="/usr/lib64/libX11.so" if="HXCPP_M64" /> <!--linux support-->
Expand Down
4 changes: 2 additions & 2 deletions source/Init.hx
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ class Init extends FlxState

FlxG.sound.play(Paths.sound('startup'));

load();
loadEverything();

new FlxTimer().start(10, function(timer)
{
Expand Down Expand Up @@ -128,7 +128,7 @@ class Init extends FlxState
super.update(elapsed);
}

function load()
function loadEverything()
{
#if html5
Paths.initPaths();
Expand Down
9 changes: 9 additions & 0 deletions source/Main.hx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ import sys.FileSystem;
import sys.io.File;
#end

#if linux
import lime.graphics.Image;
#end

using StringTools;

#if linux
Expand Down Expand Up @@ -141,6 +145,11 @@ class Main extends Sprite
GlobalVideo.setWebm(webmHandle);
#end

#if linux
var icon = Image.fromFile("icon.png");
Lib.current.stage.window.setIcon(icon);
#end

#if html5
FlxG.autoPause = FlxG.mouse.visible = false;
#end
Expand Down
4 changes: 3 additions & 1 deletion source/meta/state/MainMenuState.hx
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ typedef MenuData =

class MainMenuState extends MusicBeatState
{
public static var nightly:String = #if nightly '-nightly' #else '' #end;

public static var joalor64EngineVersion:String = '1.4.0 (UNRELEASED)'; // Used for Discord RPC

public static var psychEngineVersion:String = '0.6.3';
Expand Down Expand Up @@ -281,7 +283,7 @@ class MainMenuState extends MusicBeatState

// Watermarks
var versionShitArray:Array<String> = [
'Joalor64 Engine Rewritten v$joalor64EngineVersion',
'Joalor64 Engine Rewritten v$joalor64EngineVersion' + nightly,
'Psych Engine v$psychEngineVersion [$psychGitBuild]',
"Friday Night Funkin' v" + Application.current.meta.get('version')
];
Expand Down
2 changes: 1 addition & 1 deletion source/meta/state/SimpleMainMenuState.hx
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ class SimpleMainMenuState extends MusicBeatState

initOptions();

var versionShit:FlxText = new FlxText(12, FlxG.height - 64, 0, "Joalor64 Engine Rewritten v" + MainMenuState.joalor64EngineVersion, 12);
var versionShit:FlxText = new FlxText(12, FlxG.height - 64, 0, "Joalor64 Engine Rewritten v" + MainMenuState.joalor64EngineVersion #if nightly + MainMenuState.nightly #end, 12);
versionShit.scrollFactor.set();
versionShit.setFormat("VCR OSD Mono", 16, FlxColor.WHITE, LEFT, FlxTextBorderStyle.OUTLINE, FlxColor.BLACK);
add(versionShit);
Expand Down
7 changes: 3 additions & 4 deletions source/modcharting/ModchartEditorState.hx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package modcharting;
import flixel.input.keyboard.FlxKey;
import lime.utils.Assets;
import flixel.graphics.frames.FlxFramesCollection;
import flixel.util.FlxAxes;
import flixel.math.FlxPoint;
import flixel.addons.ui.FlxUITooltipManager;
import flixel.addons.ui.FlxUITooltipManager.FlxUITooltipData;
Expand Down Expand Up @@ -395,10 +394,10 @@ class ModchartEditorState extends MusicBeatState
//strumLineNotes.cameras = [camHUD];
//notes.cameras = [camHUD];

#if ("flixel-addons" >= "3.0.0")
grid = new FlxBackdrop(FlxGraphic.fromBitmapData(createGrid(gridSize, gridSize, Std.int(gridSize*48), gridSize)), FlxAxes.X, 0, 0);
#else
#if (flixel-addons < "3.0.0")
grid = new FlxBackdrop(FlxGraphic.fromBitmapData(createGrid(gridSize, gridSize, Std.int(gridSize*48), gridSize)), 0, 0, true, false);
#else
grid = new FlxBackdrop(FlxGraphic.fromBitmapData(createGrid(gridSize, gridSize, Std.int(gridSize*48), gridSize)));
#end

add(grid);
Expand Down
4 changes: 2 additions & 2 deletions source/modcharting/ModchartUtil.hx
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ class ModchartUtil
return instance.currentOptions.downScroll;
#elseif KADE
return PlayStateChangeables.useDownscroll;
/*
#elseif FOREVER_LEGACY //forever might not work just yet because of the multiple strumgroups
/* had to comment because this Init.hx is different
#elseif FOREVER_LEGACY // forever might not work just yet because of the multiple strumgroups
return Init.trueSettings.get('Downscroll');
*/
#elseif FPSPLUS
Expand Down

0 comments on commit 657022d

Please sign in to comment.