mirror of
https://github.com/NotImplementedLife/FSPDS.git
synced 2025-06-18 17:05:33 -04:00
added behavior for Nitro mode (#14)
This commit is contained in:
parent
77909be2ed
commit
5f8a23a2ac
1
.gitignore
vendored
1
.gitignore
vendored
@ -2,6 +2,7 @@ __pycache__/
|
||||
.git/
|
||||
arm7/build/
|
||||
arm9/build/
|
||||
arm9/nitrofs/data/
|
||||
build/
|
||||
flipnotes-example/
|
||||
fs/
|
||||
|
17
Makefile
17
Makefile
@ -5,6 +5,9 @@ ifeq ($(strip $(DEVKITARM)),)
|
||||
$(error "Please set DEVKITARM in your environment. export DEVKITARM=<path to>devkitARM")
|
||||
endif
|
||||
|
||||
MAKEFILE_PATH:=$(realpath $(shell dirname $(firstword $(MAKEFILE_LIST))))
|
||||
$(info MAKEFILE_PATH=$(MAKEFILE_PATH))
|
||||
|
||||
include $(DEVKITARM)/ds_rules
|
||||
|
||||
export GAME_TITLE := FSPDS
|
||||
@ -12,7 +15,15 @@ export GAME_ICON := $(CURDIR)/icon.bmp
|
||||
export TARGET := FSPDS
|
||||
export NDS_FILE := $(TARGET)
|
||||
|
||||
NITRO := nitrofs
|
||||
USE_NTFS := ${shell grep -E "^NTFS\s*\=\s*.*\s*$$" $(MAKEFILE_PATH)/config.ini | sed -E "s/^NTFS\s*\=\s*(.*)\s*$$/\1/" | grep . || echo "0"}
|
||||
|
||||
ifeq ($(USE_NTFS), 1)
|
||||
$(info NTFS)
|
||||
NITRO := nitrofs
|
||||
else
|
||||
$(info NO_NTFS)
|
||||
NITRO :=
|
||||
endif
|
||||
|
||||
|
||||
ROOT_DIR:=$(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
|
||||
@ -38,11 +49,13 @@ all: $(TARGET).nds
|
||||
|
||||
ifneq ($(strip $(NITRO)),)
|
||||
$(TARGET).nds : arm7/$(TARGET).elf arm9/$(TARGET).elf $(NITRO_FILES)
|
||||
$(info ndstool -7 arm7/$(TARGET).elf -9 arm9/$(TARGET).elf -b $(GAME_ICON) "$(GAME_TITLE)" -d $(NITRO_FILES) -c $(TARGET).nds)
|
||||
@ndstool -7 arm7/$(TARGET).elf -9 arm9/$(TARGET).elf -b $(GAME_ICON) "$(GAME_TITLE)" -d $(NITRO_FILES) -c $(TARGET).nds
|
||||
@echo built ... $(notdir $@)
|
||||
mv $(TARGET).nds $(TARGET)-V${shell python build_counter.py}.nds
|
||||
mv $(TARGET).nds $(TARGET)-V$(TARGET_BUILD_VERSION).nds
|
||||
else
|
||||
$(TARGET).nds : arm7/$(TARGET).elf arm9/$(TARGET).elf
|
||||
$(info ndstool -7 arm7/$(TARGET).elf -9 arm9/$(TARGET).elf -b $(GAME_ICON) "$(GAME_TITLE)" -d $(NITRO_FILES) -c $(TARGET).nds)
|
||||
@ndstool -7 arm7/$(TARGET).elf -9 arm9/$(TARGET).elf -b $(GAME_ICON) "$(GAME_TITLE)" -c $(TARGET).nds
|
||||
@echo built ... $(notdir $@)
|
||||
mv $(TARGET).nds $(TARGET)-V$(TARGET_BUILD_VERSION).nds
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 2.4 KiB After Width: | Height: | Size: 1.0 KiB |
1
arm9/assets/title_spr_nitro.asset
Normal file
1
arm9/assets/title_spr_nitro.asset
Normal file
@ -0,0 +1 @@
|
||||
-tiles -8bpp -mw8 -mh8
|
BIN
arm9/assets/title_spr_nitro.png
Normal file
BIN
arm9/assets/title_spr_nitro.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 822 B |
Binary file not shown.
@ -8,6 +8,12 @@
|
||||
|
||||
#include "version.h"
|
||||
|
||||
#if USE_NTFS==1
|
||||
#define FMT_VERSION "FSPDS V%i.%i.%i Nitro"
|
||||
#else
|
||||
#define FMT_VERSION "FSPDS V%i.%i.%i"
|
||||
#endif
|
||||
|
||||
class HelpScene : public SimpleScene
|
||||
{
|
||||
private:
|
||||
@ -118,7 +124,9 @@ public:
|
||||
|
||||
|
||||
vwf_bottom.set_cursor(9, 8);
|
||||
vwf_bottom.put_text(str_print(buffer, "FSPDS V%i.%i.%i", MAJOR, MINOR, BUILD), Pal4bit, SolidColorBrush(0x1));
|
||||
|
||||
vwf_bottom.put_text(str_print(buffer, FMT_VERSION, MAJOR, MINOR, BUILD), Pal4bit, SolidColorBrush(0x1));
|
||||
|
||||
vwf_bottom.set_cursor(10, 8);
|
||||
vwf_bottom.put_text(str_print(buffer, "%s build", BUILD_TYPE=='D' ? "Debug" : "Release"), Pal4bit, SolidColorBrush(0x1));
|
||||
}
|
||||
|
@ -7,8 +7,6 @@
|
||||
#include "frame_decoder.hpp"
|
||||
#include "sound_decoder.hpp"
|
||||
|
||||
#include "0B33C4_0BC1601FB8421_000_bin.h"
|
||||
|
||||
#include "player_bg.h"
|
||||
#include "bar_fragments.h"
|
||||
#include "player_icons.h"
|
||||
@ -570,13 +568,13 @@ public:
|
||||
}
|
||||
else
|
||||
{
|
||||
int* d = (int*)ppm_reader;
|
||||
int* s = (int*)_0B33C4_0BC1601FB8421_000_bin;
|
||||
/*int* d = (int*)ppm_reader;
|
||||
int* s = (int*)...;
|
||||
|
||||
Debug::log("START = %X", d);
|
||||
|
||||
for(int i=0;i<253196/4;i++)
|
||||
*(d++)=*(s++);
|
||||
*(d++)=*(s++);*/
|
||||
}
|
||||
|
||||
soundFreq = ppm_reader->getSoundFreq();
|
||||
|
@ -16,13 +16,15 @@ Scene* folder_picker_return_to_playlists();
|
||||
class PlaylistsScene : public SimpleScene
|
||||
{
|
||||
private:
|
||||
ObjFrame* folder_highlighted_frame;
|
||||
Sprite* folder_icons[4];
|
||||
Sprite* add_folder_icon=nullptr;
|
||||
Sprite* back_arrow = nullptr;
|
||||
ObjFrame* folder_highlighted_frame;
|
||||
Sprite* back_arrow = nullptr;
|
||||
|
||||
#if USE_NTFS!=1
|
||||
Sprite* reindex_icon = nullptr;
|
||||
Sprite* remove_icon = nullptr;
|
||||
Sprite* add_folder_icon=nullptr;
|
||||
#endif
|
||||
|
||||
|
||||
VwfEngine* vwf = new VwfEngine(Resources::Fonts::default_8x16);
|
||||
@ -66,6 +68,7 @@ public:
|
||||
else if(keys & KEY_TOUCH)
|
||||
{
|
||||
touchRead(&touch);
|
||||
#if USE_NTFS!=1
|
||||
if(touch_in_rect(220, 0, 32, 32))
|
||||
{
|
||||
folder_picker_next_scene_gen = folder_picker_return_to_playlists;
|
||||
@ -110,6 +113,7 @@ public:
|
||||
{
|
||||
close()->next(gen_title_scene());
|
||||
}
|
||||
#endif // USE_NTFS!=1
|
||||
}
|
||||
else if(keys & KEY_B)
|
||||
{
|
||||
@ -149,6 +153,7 @@ public:
|
||||
folder_icons[i]->set_position(8, 32 + 32*i);
|
||||
}
|
||||
|
||||
#if USE_NTFS!=1
|
||||
add_folder_icon = create_sprite(new Sprite(SIZE_32x32, Engine::Sub));
|
||||
add_folder_icon->add_frame(new ObjFrame(&ROA_folder_icon8,0,3));
|
||||
add_folder_icon->set_position(220, 0);
|
||||
@ -164,6 +169,7 @@ public:
|
||||
remove_icon = create_sprite(new Sprite(SIZE_32x32, Engine::Sub));
|
||||
remove_icon->add_frame(new ObjFrame(&ROA_folder_icon8,0,5));
|
||||
remove_icon->set_position(140, 0);
|
||||
#endif
|
||||
|
||||
|
||||
end_sprites_init();
|
||||
@ -222,10 +228,11 @@ public:
|
||||
vwf->clear(Pal4bit);
|
||||
vwf->set_cursor(5, Strings::pcx_indexing_files);
|
||||
vwf->put_text(Strings::str_indexing_files, Pal4bit, SolidColorBrush(0x2));
|
||||
|
||||
#if USE_NTFS!=1
|
||||
add_folder_icon->hide();
|
||||
reindex_icon->hide();
|
||||
remove_icon->hide();
|
||||
#endif
|
||||
back_arrow->hide();
|
||||
GenericScene256::frame();
|
||||
swiWaitForVBlank();
|
||||
@ -302,10 +309,12 @@ public:
|
||||
swiWaitForVBlank();
|
||||
}
|
||||
|
||||
#if USE_NTFS!=1
|
||||
add_folder_icon->show();
|
||||
reindex_icon->show();
|
||||
remove_icon->show();
|
||||
back_arrow->show();
|
||||
#endif
|
||||
display_page();
|
||||
}
|
||||
|
||||
@ -375,16 +384,20 @@ public:
|
||||
int loc_selected_index=0;
|
||||
void display_page()
|
||||
{
|
||||
#if USE_NTFS!=1
|
||||
reindex_icon->show();
|
||||
remove_icon->show();
|
||||
#endif
|
||||
vwf->clear(Pal4bit);
|
||||
for(int i=0;i<4;i++)
|
||||
folder_icons[i]->hide();
|
||||
|
||||
if(locations_provider->get_count()==0)
|
||||
{
|
||||
#if USE_NTFS!=1
|
||||
reindex_icon->hide();
|
||||
remove_icon->hide();
|
||||
#endif
|
||||
vwf->set_cursor(6, Strings::pcx_no_flipnote_locations);
|
||||
vwf->put_text(Strings::str_no_flipnote_locations, Pal4bit, SolidColorBrush(0x3));
|
||||
return;
|
||||
@ -461,10 +474,11 @@ public:
|
||||
vwf->clear(Pal4bit);
|
||||
vwf->set_cursor(5, Strings::pcx_indexing_files);
|
||||
vwf->put_text(Strings::str_indexing_files, Pal4bit, SolidColorBrush(0x2));
|
||||
|
||||
#if USE_NTFS!=1
|
||||
add_folder_icon->hide();
|
||||
reindex_icon->hide();
|
||||
remove_icon->hide();
|
||||
#endif
|
||||
back_arrow->hide();
|
||||
GenericScene256::frame();
|
||||
swiWaitForVBlank();
|
||||
@ -540,14 +554,17 @@ public:
|
||||
for(int i=0;i<60;i++)
|
||||
swiWaitForVBlank();
|
||||
|
||||
#if USE_NTFS!=1
|
||||
add_folder_icon->show();
|
||||
reindex_icon->show();
|
||||
remove_icon->show();
|
||||
#endif
|
||||
back_arrow->show();
|
||||
}
|
||||
|
||||
~PlaylistsScene()
|
||||
{
|
||||
key_down.remove_event(&PlaylistsScene::on_key_down, this);
|
||||
delete vwf;
|
||||
for(int i=0;i<4;i++)
|
||||
{
|
||||
@ -556,15 +573,14 @@ public:
|
||||
delete[] list_buffer[i];
|
||||
}
|
||||
|
||||
delete back_arrow;
|
||||
delete add_folder_icon;
|
||||
|
||||
delete folder_highlighted_frame;
|
||||
key_down.remove_event(&PlaylistsScene::on_key_down, this);
|
||||
delete back_arrow;
|
||||
delete folder_highlighted_frame;
|
||||
delete locations_provider;
|
||||
|
||||
#if USE_NTFS!=1
|
||||
delete add_folder_icon;
|
||||
delete reindex_icon;
|
||||
delete remove_icon;
|
||||
#endif
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -7,11 +7,16 @@
|
||||
#include "logo_tb_bin.h"
|
||||
#include "esodev_logo.h"
|
||||
#include "background.h"
|
||||
#include "title_spr.h"
|
||||
#include "opt_box.h"
|
||||
#include "fat_fail.h"
|
||||
#include "empty.h"
|
||||
|
||||
#if USE_NTFS==1
|
||||
#include "title_spr_nitro.h"
|
||||
#else
|
||||
#include "title_spr.h"
|
||||
#endif
|
||||
|
||||
#include "scenes.hpp"
|
||||
|
||||
|
||||
@ -71,10 +76,15 @@ class TitleScene : public GenericScene256
|
||||
begin_sprites_init();
|
||||
|
||||
empty = create_sprite(new Sprite(SIZE_8x8, Engine::Sub));
|
||||
empty->add_frame(new ObjFrame(&ROA_empty8, 0,0));
|
||||
empty->add_frame(new ObjFrame(&ROA_empty8, 0,0));
|
||||
|
||||
#if USE_NTFS==1
|
||||
title[0]->add_frame(new ObjFrame(&ROA_title_spr_nitro8, 0,0));
|
||||
title[1]->add_frame(new ObjFrame(&ROA_title_spr_nitro8, 0,1));
|
||||
#else
|
||||
title[0]->add_frame(new ObjFrame(&ROA_title_spr8, 0,0));
|
||||
title[1]->add_frame(new ObjFrame(&ROA_title_spr8, 0,1));
|
||||
#endif
|
||||
|
||||
title[0]->set_position(128-64, 116);
|
||||
title[1]->set_position(128, 116);
|
||||
|
Loading…
Reference in New Issue
Block a user