Skip to content

Commit

Permalink
Custom icon and fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
superpowers04 committed Jun 28, 2024
1 parent a509f75 commit f8d763f
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 35 deletions.
Binary file added assets/preload/images/icon64.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 9 additions & 7 deletions source/Options.hx
Original file line number Diff line number Diff line change
Expand Up @@ -393,11 +393,14 @@ class ReloadCharlist extends Option
acceptValues = true;
display = "Reload Char/Stage List";
}
public override function press():Bool
{
public static function RELOAD(){
SELoader.AssetPathCache = [];
TitleState.checkCharacters();
TitleState.loadNoteAssets(true,true);
}
public override function press():Bool
{
RELOAD();

// SickMenuState.reloadMusic = true;
return true;
Expand Down Expand Up @@ -748,14 +751,13 @@ class HCBoolOption extends Option{
public override function press():Bool{
try{

Reflect.setProperty(SESave.data,id,Reflect.getProperty(SESave.data,id) != true);
display = updateDisplay();
if(callback!=null)callback();
return true;
Reflect.setProperty(SESave.data,id,Reflect.getProperty(SESave.data,id) != true);
display = updateDisplay();
if(callback!=null)callback();
}catch(e){
FuckState.FUCK(e,'options.press');
return true;
}
return true;
}

override function updateDisplay():String
Expand Down
4 changes: 2 additions & 2 deletions source/OptionsMenu.hx
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,8 @@ class OptionsMenu extends MusicBeatState
],"Misc things"),
new OptionCategory("Compatibility", [
new HCBoolOption("Legacy hurt notes","Load legacy Tricky mod format notes","useHurtArrows"),
new HCBoolOption("Seperate PE chars from SE Chars","Add -pe to Psych character ID's to prevent conflicts","PECharSeperate"),
new HCBoolOption("Add Psych Engine Characters","(Requires a reload of character list) Allows Psych characters to load. Psych Characters are not properly implemented yet","PECharLoading"),
new HCBoolOption("Seperate PE chars from SE Chars","Add -pe to Psych character ID's to prevent conflicts","PECharSeperate",ReloadCharlist.RELOAD),
new HCBoolOption("Add Psych Engine Characters","(Requires a reload of character list) Allows Psych characters to load. Psych Characters are not properly implemented yet","PECharLoading",ReloadCharlist.RELOAD),
new HCBoolOption("Load Psych Events","Attempts to load Psych events from songs(Experimental)","loadPsychEvents"),
new HCBoolOption("Quick reloading songs","Allows songs to quick-reload when you restart. This can break some songs","QuickReloading"),
],'Toggle compatibility with specific features from mods/engines'),
Expand Down
28 changes: 3 additions & 25 deletions source/TitleState.hx
Original file line number Diff line number Diff line change
Expand Up @@ -735,37 +735,14 @@ class TitleState extends MusicBeatState

transIn = FlxTransitionableState.defaultTransIn;
transOut = FlxTransitionableState.defaultTransOut;

// FlxTween.tween(Main.fpsCounter,{alpha:1},0.2);


// HAD TO MODIFY SOME BACKEND SHIT
// IF THIS PR IS HERE IF ITS ACCEPTED UR GOOD TO GO
// https://github.com/HaxeFlixel/flixel-addons/pull/348

// var music:FlxSound = new FlxSound();
// music.loadStream(Paths.music('freakyMenu'));
// FlxG.sound.list.add(music);
// music.play();
FlxG.sound.playMusic(SELoader.loadSound('assets/music/StartItchBuild.ogg'), 0.1);
FlxG.sound.music.pause();
// LoadingState.loadingText = new FlxText(FlxG.width * 0.8,FlxG.height * 0.8,"Loading...");
// LoadingState.loadingText.setFormat();


#if android

FlxG.android.preventDefaultKeys = [BACK];
// trace(lime.system.System.applicationStorageDirectory);
// var reason = 0;
// if(!FileSystem.exists(lime.system.System.applicationStorageDirectory + '/path.txt')){
// reason = 1;
// }else if(!FileSystem.exists(sys.io.File.getContent(FileSystem.exists(lime.system.System.applicationStorageDirectory + '/path.txt')))){
// reason = 2;
// }
// if(reason != 0){

// }
var grantedPerms = Main.grantedPerms = android.Permissions.getGrantedPermissions();
if(!grantedPerms.contains('android.permission.WRITE_EXTERNAL_STORAGE')){
android.Permissions.requestPermission('android.permission.WRITE_EXTERNAL_STORAGE',1);
Expand Down Expand Up @@ -830,8 +807,8 @@ class TitleState extends MusicBeatState
Alphabet.Frames = null;
LoadingScreen.forceHide();
LoadingScreen.initScreen();
if((CoolUtil.font = if(SELoader.exists('mods/font.ttf')) SELoader.getPath('mods/font.ttf') else Paths.font(CoolUtil.fontName)
) != Paths.font("vcr.ttf")) flixel.system.FlxAssets.FONT_DEFAULT = CoolUtil.font;
CoolUtil.font = (SELoader.exists('mods/font.ttf') ? SELoader.getPath('mods/font.ttf') : Paths.font(CoolUtil.fontName));
if(CoolUtil.font == Paths.font("vcr.ttf")) flixel.system.FlxAssets.FONT_DEFAULT = CoolUtil.font;
#end
var isUsingPaths = false;
if(SELoader.exists('path.txt')){
Expand Down Expand Up @@ -976,6 +953,7 @@ class TitleState extends MusicBeatState
superLogo = new FlxSprite(0,FlxG.height*0.52);
}
add(superLogo);
lime.app.Application.current.window.setIcon(lime.graphics.Image.fromBitmapData(SELoader.loadBitmap('assets/images/icon64.png')));
superLogo.visible = false;
superLogo.screenCenter(X);

Expand Down
2 changes: 1 addition & 1 deletion version.downloadMe
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
24.06.27.2022;
24.06.27.2124;
* Better Psych character support(Still kinda experimental but should be more stable)
* Fix some small errors
* Fix characters not loading due to using ID instead of folderName
Expand Down

0 comments on commit f8d763f

Please sign in to comment.