Skip to content

Commit

Permalink
Merge 0.2.9f changes
Browse files Browse the repository at this point in the history
  • Loading branch information
CommonLoon102 committed Apr 22, 2021
1 parent 91a619d commit d18efe7
Show file tree
Hide file tree
Showing 20 changed files with 242 additions and 161 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,9 @@ jobs:
cd ${{ env.build_dir }}
mkdir ${{ env.package_dir }}
if [[ "${{ runner.os }}" == 'Windows' ]]; then
cp ${{ matrix.config.build_type }}/${{ env.app_name }}.exe ${{ matrix.config.build_type }}/SDL2.dll ${{ matrix.config.build_type }}/getopt.dll ../${{ env.app_name }}.ini ${{ env.package_dir }}
cp ${{ matrix.config.build_type }}/${{ env.app_name }}.exe ${{ matrix.config.build_type }}/SDL2.dll ${{ matrix.config.build_type }}/getopt.dll ../${{ env.app_name }}.ini ../icon.bmp ${{ env.package_dir }}
else
cp ${{ env.app_name }} ../${{ env.app_name }}.ini ${{ env.package_dir }}
cp ${{ env.app_name }} ../${{ env.app_name }}.ini ../icon.bmp ${{ env.package_dir }}
fi
- name: Zip Package
Expand Down
5 changes: 5 additions & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
* release 0.2.9f
- added 'linear' graphics scaler
- enabled PSX options menu
- fixed '1x' scaling

* release 0.2.9e
- fixed graphics glitches with PSX backgrounds
- removed 'inih' and 'libxbr-standalone' dependencies
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ if(NSWITCH)
add_definitions(-D__SWITCH__)
add_custom_target(${CMAKE_PROJECT_NAME}.nro
DEPENDS ${CMAKE_PROJECT_NAME}
COMMAND nacptool --create "Heart of Darkness" "cyx, usineur" "0.2.9d" ${CMAKE_PROJECT_NAME}.nacp
COMMAND nacptool --create "Heart of Darkness" "cyx, usineur" "0.2.9f" ${CMAKE_PROJECT_NAME}.nacp
COMMAND elf2nro ${CMAKE_PROJECT_NAME} ${CMAKE_PROJECT_NAME}.nro --icon=${CMAKE_SOURCE_DIR}/3p/res/icon.jpg --nacp=${CMAKE_PROJECT_NAME}.nacp
)
add_custom_target(nxlink
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ SRCS = andy.cpp benchmark.cpp fileio.cpp fs_posix.cpp game.cpp \
resource.cpp screenshot.cpp sound.cpp staticres.cpp system_sdl2.cpp \
util.cpp video.cpp

SCALERS := scaler_nearest.cpp scaler_xbr.cpp
SCALERS := scaler_xbr.cpp

OBJS = $(SRCS:.cpp=.o) $(SCALERS:.cpp=.o)
DEPS = $(SRCS:.cpp=.d) $(SCALERS:.cpp=.d)
Expand Down
7 changes: 2 additions & 5 deletions game.h
Original file line number Diff line number Diff line change
Expand Up @@ -161,12 +161,10 @@ struct Game {
bool _specialAnimFlag;
AndyShootData _andyShootsTable[kMaxAndyShoots];
int _andyShootsCount;
uint8_t _mstOp68_type, _mstOp68_arg9, _mstOp67_type;
uint8_t _mstOp67_flags1;
uint16_t _mstOp67_unk;
uint8_t _mstOp68_type, _mstOp68_flags1, _mstOp67_type, _mstOp67_flags1;
int _mstOp67_x1, _mstOp67_x2, _mstOp67_y1, _mstOp67_y2;
int8_t _mstOp67_screenNum;
uint16_t _mstOp68_flags1;
uint16_t _mstOp68_flags2;
int _mstOp68_x1, _mstOp68_x2, _mstOp68_y1, _mstOp68_y2;
int8_t _mstOp68_screenNum;
uint32_t _mstLevelGatesMask;
Expand Down Expand Up @@ -204,7 +202,6 @@ struct Game {
int _xMstPos1, _yMstPos1;
int _xMstPos2, _yMstPos2; // xMstDist1, yMstDist1
int _xMstPos3, _yMstPos3;
int _mstHelper1Count;
int _mstActionNum;
uint32_t _mstAndyVarMask;
int _mstChasingMonstersCount;
Expand Down
Binary file added icon.bmp
Binary file not shown.
1 change: 0 additions & 1 deletion main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,6 @@ int main(int argc, char *argv[]) {
setupAudio(g);
if (isPsx) {
g->_video->initPsx();
_runMenu = false;
}
if (_displayLoadingScreen) {
g->displayLoadingScreen();
Expand Down
2 changes: 1 addition & 1 deletion mdec.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ static void decodeBlock(BitStream *bs, int x8, int y8, uint8_t *dst, int dstPitc
for (int y = 0; y < 8; y++) {
for (int x = 0; x < 8; x++) {
const int val = (int)round(idctData[y * 8 + x]); // (-128,127) range
dst[x] = (val < -128) ? 0 : ((val > 127) ? 255 : (128 + val));
dst[x] = (val <= -128) ? 0 : ((val >= 127) ? 255 : (128 + val));
}
dst += dstPitch;
}
Expand Down
Loading

0 comments on commit d18efe7

Please sign in to comment.