Compare commits
58 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
824af61fbb | ||
|
|
b05b70d6b7 | ||
|
|
59c19c8046 | ||
|
|
3c731721fa | ||
|
|
4c4f6377f6 | ||
|
|
af7c7a0064 | ||
|
|
4b18de8528 | ||
|
|
b88a660255 | ||
|
|
34cf507e3f | ||
|
|
bc19d2263b | ||
|
|
909c743527 | ||
|
|
7096111235 | ||
|
|
a09f283d77 | ||
|
|
d327c22bb5 | ||
|
|
05bae8b611 | ||
|
|
d19750362c | ||
|
|
54d85f487c | ||
|
|
a95def6dc0 | ||
|
|
07b827eb2d | ||
|
|
1bb770e5d7 | ||
|
|
5fbbec3502 | ||
|
|
b480f7bfce | ||
|
|
10efa92153 | ||
|
|
dee0ba15d4 | ||
|
|
c1bcbdc067 | ||
|
|
d3b45cf2b4 | ||
|
|
3b31d9fcfc | ||
|
|
c54fd002ec | ||
|
|
30c462a8ef | ||
|
|
1acc0961d4 | ||
|
|
6a27eb7356 | ||
|
|
b942deb12b | ||
|
|
4713782189 | ||
|
|
cb9b14841b | ||
|
|
c272403fe0 | ||
|
|
aad91097cd | ||
|
|
6a92b96c64 | ||
|
|
caea40c6aa | ||
|
|
ed2a2225d7 | ||
|
|
e40e69e1d8 | ||
|
|
a978d8d325 | ||
|
|
a443a0a7c7 | ||
|
|
4438f7d9c8 | ||
|
|
30d80d66a0 | ||
|
|
8000ff491a | ||
|
|
bf958a1f29 | ||
|
|
bc6dbf0254 | ||
|
|
39549e415e | ||
|
|
6e53c813fc | ||
|
|
69ff202bae | ||
|
|
670a2c4c62 | ||
|
|
14918e187e | ||
|
|
1bd8f3e14e | ||
|
|
5eb32764a5 | ||
|
|
84801ecdc7 | ||
|
|
2509e01125 | ||
|
|
ba0d7ef58c | ||
|
|
9fb738e2ed |
336 changed files with 12689 additions and 6437 deletions
6
.gitmodules
vendored
6
.gitmodules
vendored
|
|
@ -1,3 +1,9 @@
|
|||
[submodule "extern/musyx"]
|
||||
path = extern/musyx
|
||||
url = https://github.com/AxioDL/musyx
|
||||
[submodule "extern/aurora"]
|
||||
path = extern/aurora
|
||||
url = https://github.com/dbalatoni13/aurora.git
|
||||
[submodule "extern/libco"]
|
||||
path = extern/libco
|
||||
url = https://github.com/higan-emu/libco.git
|
||||
|
|
|
|||
203
CMakeLists.txt
Normal file
203
CMakeLists.txt
Normal file
|
|
@ -0,0 +1,203 @@
|
|||
cmake_minimum_required(VERSION 3.13)
|
||||
if (APPLE)
|
||||
project(marioparty4 LANGUAGES C CXX OBJC)
|
||||
else ()
|
||||
project(marioparty4 LANGUAGES C CXX)
|
||||
endif ()
|
||||
|
||||
set(CMAKE_C_STANDARD 11)
|
||||
set(CMAKE_CXX_STANDARD 20)
|
||||
|
||||
set(VERSION 0)
|
||||
|
||||
# Set build type to Debug if not specified
|
||||
if (NOT CMAKE_BUILD_TYPE)
|
||||
set(CMAKE_BUILD_TYPE Debug)
|
||||
endif ()
|
||||
|
||||
if (CMAKE_SYSTEM_NAME STREQUAL Linux)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m32 -fsanitize=address -fsanitize-address-use-after-scope -Wno-unknown-pragmas -Wno-unused-variable -Wno-unused-parameter -fPIC")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32 -fsanitize=address -fsanitize-address-use-after-scope -Wno-register -fPIC")
|
||||
set(CMAKE_PREFIX_PATH /usr)
|
||||
set(CMAKE_LIBRARY_ARCHITECTURE i386-linux-gnu)
|
||||
set(CMAKE_LIBRARY_PATH "/usr/lib32" "/usr/lib/i386-linux-gnu" CACHE PATH "")
|
||||
set(CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX 32)
|
||||
elseif (APPLE)
|
||||
add_compile_options(-Wno-declaration-after-statement)
|
||||
elseif (MSVC)
|
||||
add_compile_options(/bigobj)
|
||||
endif ()
|
||||
|
||||
# add_compile_options(-fsanitize=address)
|
||||
|
||||
add_subdirectory(extern/aurora EXCLUDE_FROM_ALL)
|
||||
add_subdirectory(extern/musyx EXCLUDE_FROM_ALL)
|
||||
|
||||
set(DOLPHIN_FILES
|
||||
src/dolphin/mtx/mtx.c
|
||||
src/dolphin/mtx/mtx44.c
|
||||
src/dolphin/mtx/vec.c
|
||||
src/dolphin/mtx/quat.c
|
||||
src/dolphin/os/OSAlloc.c
|
||||
src/dolphin/os/OSArena.c
|
||||
src/dolphin/os/OSStopwatch.c
|
||||
)
|
||||
|
||||
set(GAME_FILES
|
||||
src/game/board/audio.c
|
||||
src/game/board/basic_space.c
|
||||
src/game/board/battle.c
|
||||
src/game/board/block.c
|
||||
src/game/board/boo.c
|
||||
src/game/board/boo_house.c
|
||||
src/game/board/bowser.c
|
||||
src/game/board/char_wheel.c
|
||||
src/game/board/com.c
|
||||
src/game/board/com_path.c
|
||||
src/game/board/fortune.c
|
||||
src/game/board/item.c
|
||||
src/game/board/last5.c
|
||||
src/game/board/lottery.c
|
||||
src/game/board/main.c
|
||||
src/game/board/mg_setup.c
|
||||
src/game/board/model.c
|
||||
src/game/board/mushroom.c
|
||||
src/game/board/pause.c
|
||||
src/game/board/player.c
|
||||
src/game/board/roll.c
|
||||
src/game/board/shop.c
|
||||
src/game/board/space.c
|
||||
src/game/board/star.c
|
||||
src/game/board/start.c
|
||||
src/game/board/tutorial.c
|
||||
src/game/board/ui.c
|
||||
src/game/board/view.c
|
||||
src/game/board/warp.c
|
||||
src/game/board/window.c
|
||||
|
||||
src/game/armem.c
|
||||
src/game/card.c
|
||||
src/game/chrman.c
|
||||
src/game/ClusterExec.c
|
||||
src/game/data.c
|
||||
src/game/decode.c
|
||||
src/game/dvd.c
|
||||
src/game/EnvelopeExec.c
|
||||
src/game/esprite.c
|
||||
src/game/fault.c
|
||||
src/game/flag.c
|
||||
src/game/font.c
|
||||
src/game/frand.c
|
||||
src/game/gamework.c
|
||||
src/game/hsfanim.c
|
||||
src/game/hsfdraw.c
|
||||
src/game/hsfex.c
|
||||
src/game/hsfload.c
|
||||
src/game/hsfman.c
|
||||
src/game/hsfmotion.c
|
||||
src/game/init.c
|
||||
src/game/main.c
|
||||
src/game/malloc.c
|
||||
src/game/mapspace.c
|
||||
src/game/memory.c
|
||||
src/game/messdata.c
|
||||
src/game/minigame_seq.c
|
||||
src/game/objdll.c
|
||||
src/game/objmain.c
|
||||
src/game/objsub.c
|
||||
src/game/objsysobj.c
|
||||
src/game/ovllist.c
|
||||
src/game/pad.c
|
||||
src/game/perf.c
|
||||
src/game/printfunc.c
|
||||
src/game/process.c
|
||||
src/game/saveload.c
|
||||
src/game/ShapeExec.c
|
||||
src/game/sprman.c
|
||||
src/game/sprput.c
|
||||
src/game/window.c
|
||||
src/game/wipe.c
|
||||
|
||||
src/libhu/setvf.c
|
||||
src/libhu/subvf.c
|
||||
)
|
||||
|
||||
set(PORT_FILES
|
||||
src/port/ar.c
|
||||
src/port/arq.c
|
||||
src/port/audio.c
|
||||
src/port/byteswap.cpp
|
||||
src/port/dvd.c
|
||||
src/port/imgui.cpp
|
||||
src/port/OS.c
|
||||
src/port/stubs.c
|
||||
)
|
||||
|
||||
source_group("Dolphin" FILES ${DOLPHIN_FILES})
|
||||
source_group("Game" FILES ${GAME_FILES})
|
||||
source_group("Port" FILES ${PORT_FILES})
|
||||
|
||||
if (NOT MSVC)
|
||||
foreach (file ${DOLPHIN_FILES})
|
||||
set_source_files_properties(${file} PROPERTIES COMPILE_FLAGS "-Dinline=")
|
||||
endforeach ()
|
||||
foreach (file ${GAME_FILES})
|
||||
set_source_files_properties(${file} PROPERTIES COMPILE_FLAGS "-Dinline=")
|
||||
endforeach ()
|
||||
endif ()
|
||||
|
||||
add_library(dol SHARED ${DOLPHIN_FILES} ${GAME_FILES} ${PORT_FILES} extern/libco/libco.c)
|
||||
target_compile_definitions(dol PRIVATE TARGET_PC NON_MATCHING TARGET_DOL VERSION=${VERSION} MUSY_VERSION_MAJOR=1 MUSY_VERSION_MINOR=5 MUSY_VERSION_PATCH=4)
|
||||
target_include_directories(dol PRIVATE include build/GMPE01_00/include extern/libco)
|
||||
target_link_libraries(dol PRIVATE aurora::core aurora::gx aurora::si aurora::vi aurora::pad musyx)
|
||||
set_source_files_properties(${DOLPHIN_FILES} ${GAME_FILES} PROPERTIES COMPILE_OPTIONS "-fsanitize=address")
|
||||
if (MSVC)
|
||||
target_link_options(dol PRIVATE "/DEF:${CMAKE_SOURCE_DIR}/dol.def")
|
||||
target_compile_options(dol PRIVATE "/Zi")
|
||||
target_compile_options(dol PRIVATE "/Ob0")
|
||||
target_compile_options(dol PRIVATE "/Od")
|
||||
target_compile_options(dol PRIVATE "/RTC1")
|
||||
else ()
|
||||
# target_compile_options(dol PRIVATE "-fvisibility=hidden")
|
||||
# target_link_options(dol PRIVATE "LINKER:--version-script=${CMAKE_CURRENT_SOURCE_DIR}/dol.map")
|
||||
endif ()
|
||||
|
||||
add_executable(marioparty4 src/port/portmain.c)
|
||||
target_compile_definitions(marioparty4 PRIVATE TARGET_PC NON_MATCHING VERSION=${VERSION})
|
||||
target_include_directories(marioparty4 PRIVATE include)
|
||||
target_link_libraries(marioparty4 PRIVATE dol aurora::main)
|
||||
|
||||
file(GLOB REL_DIRS RELATIVE ${CMAKE_SOURCE_DIR}/src/REL ${CMAKE_SOURCE_DIR}/src/REL/*)
|
||||
set(EXCLUDED_RELS "nisDll" "safDll")
|
||||
|
||||
foreach (dir ${REL_DIRS})
|
||||
if (IS_DIRECTORY ${CMAKE_SOURCE_DIR}/src/REL/${dir})
|
||||
if (dir IN_LIST EXCLUDED_RELS)
|
||||
continue()
|
||||
endif()
|
||||
file(GLOB_RECURSE REL_FILES src/REL/${dir}/*.c)
|
||||
|
||||
if (REL_FILES)
|
||||
add_library(${dir} SHARED ${REL_FILES})
|
||||
set_source_files_properties(${REL_FILES} PROPERTIES COMPILE_OPTIONS "-fsanitize=address")
|
||||
if (dir MATCHES "^w..Dll")
|
||||
target_sources(${dir} PRIVATE src/REL/board_executor.c)
|
||||
endif()
|
||||
target_compile_definitions(${dir} PRIVATE TARGET_PC NON_MATCHING VERSION=${VERSION})
|
||||
target_include_directories(${dir} PRIVATE include build/GMPE01_00/include extern/libco)
|
||||
if (MSVC)
|
||||
set_target_properties(${dir} PROPERTIES LINK_FLAGS "/EXPORT:ObjectSetup")
|
||||
target_compile_options(${dir} PRIVATE "/Zi")
|
||||
target_compile_options(${dir} PRIVATE "/Ob0")
|
||||
target_compile_options(${dir} PRIVATE "/Od")
|
||||
target_compile_options(${dir} PRIVATE "/RTC1")
|
||||
elseif (NOT CMAKE_SYSTEM_NAME STREQUAL Windows)
|
||||
target_compile_options(${dir} PRIVATE "-fvisibility=hidden")
|
||||
target_link_options(${dir} PRIVATE "LINKER:--version-script=${CMAKE_CURRENT_SOURCE_DIR}/rel.map")
|
||||
set_target_properties(${dir} PROPERTIES PREFIX "")
|
||||
endif ()
|
||||
target_link_libraries(${dir} PRIVATE dol musyx)
|
||||
add_dependencies(marioparty4 ${dir})
|
||||
endif ()
|
||||
endif ()
|
||||
endforeach ()
|
||||
18
README.md
18
README.md
|
|
@ -59,7 +59,7 @@ Linux
|
|||
- For non-x86(_64) platforms: Install wine from your package manager.
|
||||
- For x86(_64), [wibo](https://github.com/decompals/wibo), a minimal 32-bit Windows binary wrapper, will be automatically downloaded and used.
|
||||
|
||||
Building
|
||||
Building the game for the GameCube
|
||||
========
|
||||
|
||||
- Clone the repository:
|
||||
|
|
@ -89,11 +89,13 @@ Building
|
|||
ninja
|
||||
```
|
||||
|
||||
Diffing
|
||||
=======
|
||||
Building the game for PC
|
||||
=====
|
||||
After you got the GameCube build up and running for `GMPE01_00`:
|
||||
- Generate project files using CMake:
|
||||
```
|
||||
cmake -B build/port -G "Visual Studio 17 2022" -A Win32
|
||||
```
|
||||
Linux and MacOS, and x64 support is coming later.
|
||||
|
||||
Once the initial build succeeds, an `objdiff.json` should exist in the project root.
|
||||
|
||||
Download the latest release from [encounter/objdiff](https://github.com/encounter/objdiff). Under project settings, set `Project directory`. The configuration should be loaded automatically.
|
||||
|
||||
Select an object from the left sidebar to begin diffing. Changes to the project will rebuild automatically: changes to source files, headers, `configure.py`, `splits.txt` or `symbols.txt`.
|
||||
- Open the solution in Visual Studio and build.
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ fn_1_0 = .text:0x00000000; // type:function size:0x4C
|
|||
fn_1_4C = .text:0x0000004C; // type:function size:0x58
|
||||
_prolog = .text:0x000000A4; // type:function size:0x54 scope:global
|
||||
_epilog = .text:0x000000F8; // type:function size:0x4C scope:global
|
||||
fn_1_144 = .text:0x00000144; // type:function size:0xC8
|
||||
ObjectSetup = .text:0x00000144; // type:function size:0xC8
|
||||
fn_1_20C = .text:0x0000020C; // type:function size:0x28
|
||||
fn_1_234 = .text:0x00000234; // type:function size:0x20
|
||||
fn_1_254 = .text:0x00000254; // type:function size:0xD8
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ fn_1_0 = .text:0x00000000; // type:function size:0xEC
|
|||
fn_1_EC = .text:0x000000EC; // type:function size:0x115C
|
||||
_prolog = .text:0x00001248; // type:function size:0x54 scope:global
|
||||
_epilog = .text:0x0000129C; // type:function size:0x4C scope:global
|
||||
fn_1_12E8 = .text:0x000012E8; // type:function size:0xB8
|
||||
ObjectSetup = .text:0x000012E8; // type:function size:0xB8
|
||||
fn_1_13A0 = .text:0x000013A0; // type:function size:0x68C
|
||||
_ctors = .ctors:0x00000000; // type:label scope:global data:4byte
|
||||
_dtors = .dtors:0x00000000; // type:label scope:global data:4byte
|
||||
|
|
|
|||
|
|
@ -103,7 +103,7 @@ CreateNote = .text:0x00007710; // type:function size:0x190 scope:local
|
|||
CreateNoteSpawner = .text:0x000078A0; // type:function size:0x60 scope:local
|
||||
KillNoteSpawner = .text:0x00007900; // type:function size:0x3C scope:local
|
||||
ExecNoteSpawner = .text:0x0000793C; // type:function size:0x5C4 scope:local
|
||||
PlaySound = .text:0x00007F00; // type:function size:0x148 scope:local
|
||||
OptionPlaySound = .text:0x00007F00; // type:function size:0x148 scope:local
|
||||
FadeSound = .text:0x00008048; // type:function size:0x9C scope:local
|
||||
OptionRecordCreate = .text:0x000080E4; // type:function size:0x178
|
||||
OptionRecordKill = .text:0x0000825C; // type:function size:0x54
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ PresentSelectedIDSet = .text:0x0000186C; // type:function size:0xBC
|
|||
ExecSelectRoom = .text:0x00001928; // type:function size:0x680 scope:local
|
||||
ChangeRoom = .text:0x00001FA8; // type:function size:0x140 scope:local
|
||||
ExecSelectPresent = .text:0x000020E8; // type:function size:0x5A4 scope:local
|
||||
GetCursorPos = .text:0x0000268C; // type:function size:0x7C scope:local
|
||||
PresentGetCursorPos = .text:0x0000268C; // type:function size:0x7C scope:local
|
||||
SetCameraRot = .text:0x00002708; // type:function size:0x6C scope:local
|
||||
RotateCamera = .text:0x00002774; // type:function size:0x17C scope:local
|
||||
CameraRotationDoneCheck = .text:0x000028F0; // type:function size:0x34 scope:local
|
||||
|
|
|
|||
|
|
@ -207,4 +207,4 @@ lbl_1_bss_19F8 = .bss:0x000019F8; // type:object size:0x20
|
|||
lbl_1_bss_1A18 = .bss:0x00001A18; // type:object size:0x2
|
||||
stageSprId = .bss:0x00001A1A; // type:object size:0x42 data:2byte
|
||||
stageMotId = .bss:0x00001A5C; // type:object size:0x40 data:2byte
|
||||
stageSprId = .bss:0x00001A9C; // type:object size:0x40 data:2byte
|
||||
stageMdlId = .bss:0x00001A9C; // type:object size:0x40 data:2byte
|
||||
|
|
|
|||
|
|
@ -4620,7 +4620,7 @@ lbl_80192160 = .bss:0x80192160; // type:object size:0x100
|
|||
lbl_80192260 = .bss:0x80192260; // type:object size:0x100
|
||||
wipeData = .bss:0x80192360; // type:object size:0x4C data:4byte
|
||||
winData = .bss:0x801923C0; // type:object size:0x3000 align:32 data:byte
|
||||
winKey = .bss:0x801953C0; // type:object size:0x10
|
||||
winKey = .bss:0x801953C0; // type:object size:0x10 scope:local
|
||||
winComKeyBuf = .bss:0x801953D0; // type:object size:0x1400
|
||||
ARInfo = .bss:0x801967E0; // type:object size:0x400 scope:local data:byte
|
||||
arqReq = .bss:0x80196BE0; // type:object size:0x20 scope:local
|
||||
|
|
|
|||
|
|
@ -4619,7 +4619,7 @@ lbl_80192160 = .bss:0x80192160; // type:object size:0x100
|
|||
lbl_80192260 = .bss:0x80192260; // type:object size:0x100
|
||||
wipeData = .bss:0x80192360; // type:object size:0x4C data:4byte
|
||||
winData = .bss:0x801923C0; // type:object size:0x3000 align:32 data:byte
|
||||
winKey = .bss:0x801953C0; // type:object size:0x10
|
||||
winKey = .bss:0x801953C0; // type:object size:0x10 scope:local
|
||||
winComKeyBuf = .bss:0x801953D0; // type:object size:0x1400
|
||||
ARInfo = .bss:0x801967E0; // type:object size:0x400 data:byte
|
||||
arqReq = .bss:0x80196BE0; // type:object size:0x20 scope:local
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ fn_1_0 = .text:0x00000000; // type:function size:0x4C
|
|||
fn_1_4C = .text:0x0000004C; // type:function size:0x58
|
||||
_prolog = .text:0x000000A4; // type:function size:0x54 scope:global
|
||||
_epilog = .text:0x000000F8; // type:function size:0x4C scope:global
|
||||
fn_1_144 = .text:0x00000144; // type:function size:0xC8
|
||||
ObjectSetup = .text:0x00000144; // type:function size:0xC8
|
||||
fn_1_20C = .text:0x0000020C; // type:function size:0x28
|
||||
fn_1_234 = .text:0x00000234; // type:function size:0x20
|
||||
fn_1_254 = .text:0x00000254; // type:function size:0xD8
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ fn_1_0 = .text:0x00000000; // type:function size:0xEC
|
|||
fn_1_EC = .text:0x000000EC; // type:function size:0x115C
|
||||
_prolog = .text:0x00001248; // type:function size:0x54 scope:global
|
||||
_epilog = .text:0x0000129C; // type:function size:0x4C scope:global
|
||||
fn_1_12E8 = .text:0x000012E8; // type:function size:0xB8
|
||||
ObjectSetup = .text:0x000012E8; // type:function size:0xB8
|
||||
fn_1_13A0 = .text:0x000013A0; // type:function size:0x68C
|
||||
_ctors = .ctors:0x00000000; // type:label scope:global data:4byte
|
||||
_dtors = .dtors:0x00000000; // type:label scope:global data:4byte
|
||||
|
|
|
|||
|
|
@ -4452,7 +4452,7 @@ lbl_80192160 = .bss:0x80191E00; // type:object size:0x100
|
|||
lbl_80192260 = .bss:0x80191F00; // type:object size:0x100
|
||||
wipeData = .bss:0x80192000; // type:object size:0x4C data:4byte
|
||||
winData = .bss:0x80192060; // type:object size:0x3000 data:byte
|
||||
winKey = .bss:0x80195060; // type:object size:0x10
|
||||
winKey = .bss:0x80195060; // type:object size:0x10 scope:local
|
||||
winComKeyBuf = .bss:0x80195070; // type:object size:0x1400
|
||||
ARInfo = .bss:0x80196480; // type:object size:0x400 scope:local data:byte
|
||||
arqReq = .bss:0x80196880; // type:object size:0x20 scope:local
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ fn_1_0 = .text:0x00000000; // type:function size:0x4C
|
|||
fn_1_4C = .text:0x0000004C; // type:function size:0x58
|
||||
_prolog = .text:0x000000A4; // type:function size:0x54 scope:global
|
||||
_epilog = .text:0x000000F8; // type:function size:0x4C scope:global
|
||||
fn_1_144 = .text:0x00000144; // type:function size:0xC8
|
||||
ObjectSetup = .text:0x00000144; // type:function size:0xC8
|
||||
fn_1_20C = .text:0x0000020C; // type:function size:0x28
|
||||
fn_1_234 = .text:0x00000234; // type:function size:0x20
|
||||
fn_1_254 = .text:0x00000254; // type:function size:0xD8
|
||||
|
|
|
|||
|
|
@ -103,7 +103,7 @@ CreateNote = .text:0x00007710; // type:function size:0x190 scope:local
|
|||
CreateNoteSpawner = .text:0x000078A0; // type:function size:0x60 scope:local
|
||||
KillNoteSpawner = .text:0x00007900; // type:function size:0x3C scope:local
|
||||
ExecNoteSpawner = .text:0x0000793C; // type:function size:0x5C4 scope:local
|
||||
PlaySound = .text:0x00007F00; // type:function size:0x148 scope:local
|
||||
OptionPlaySound = .text:0x00007F00; // type:function size:0x148 scope:local
|
||||
FadeSound = .text:0x00008048; // type:function size:0x9C scope:local
|
||||
OptionRecordCreate = .text:0x000080E4; // type:function size:0x178
|
||||
OptionRecordKill = .text:0x0000825C; // type:function size:0x54
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ PresentSelectedIDSet = .text:0x0000186C; // type:function size:0xBC
|
|||
ExecSelectRoom = .text:0x00001928; // type:function size:0x680 scope:local
|
||||
ChangeRoom = .text:0x00001FA8; // type:function size:0x140 scope:local
|
||||
ExecSelectPresent = .text:0x000020E8; // type:function size:0x5A4 scope:local
|
||||
GetCursorPos = .text:0x0000268C; // type:function size:0x7C scope:local
|
||||
PresentGetCursorPos = .text:0x0000268C; // type:function size:0x7C scope:local
|
||||
SetCameraRot = .text:0x00002708; // type:function size:0x6C scope:local
|
||||
RotateCamera = .text:0x00002774; // type:function size:0x17C scope:local
|
||||
CameraRotationDoneCheck = .text:0x000028F0; // type:function size:0x34 scope:local
|
||||
|
|
|
|||
|
|
@ -5547,7 +5547,7 @@ lbl_80192160 = .bss:0x801AF500; // type:object size:0x100
|
|||
lbl_80192260 = .bss:0x801AF600; // type:object size:0x100
|
||||
wipeData = .bss:0x801AF700; // type:object size:0x4C data:4byte
|
||||
winData = .bss:0x801AF760; // type:object size:0x3000 align:32 data:byte
|
||||
winKey = .bss:0x801B2760; // type:object size:0x10
|
||||
winKey = .bss:0x801B2760; // type:object size:0x10 scope:local
|
||||
winComKeyBuf = .bss:0x801B2770; // type:object size:0x1400
|
||||
mesWInsert = .bss:0x801B3B70; // type:object size:0x10 scope:local
|
||||
ARInfo = .bss:0x801B3B80; // type:object size:0x400 data:byte
|
||||
|
|
|
|||
|
|
@ -160,6 +160,7 @@ config.asflags = [
|
|||
"-mgekko",
|
||||
"--strip-local-absolute",
|
||||
"-I include",
|
||||
"-I libc",
|
||||
f"-I build/{config.version}/include",
|
||||
f"--defsym version={version_num}",
|
||||
]
|
||||
|
|
@ -192,6 +193,7 @@ cflags_base = [
|
|||
"-fp_contract on",
|
||||
"-str reuse",
|
||||
"-i include",
|
||||
"-i libc",
|
||||
"-i extern/musyx/include",
|
||||
f"-i build/{config.version}/include",
|
||||
"-multibyte",
|
||||
|
|
@ -270,6 +272,7 @@ cflags_musyx = [
|
|||
"-nodefaults",
|
||||
"-nosyspath",
|
||||
"-i include",
|
||||
"-i libc",
|
||||
"-i extern/musyx/include",
|
||||
"-inline auto",
|
||||
"-O4,p",
|
||||
|
|
|
|||
1
extern/aurora
vendored
Submodule
1
extern/aurora
vendored
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit 23522538e13f67957d62a7119bc617700fa0c6ab
|
||||
1
extern/libco
vendored
Submodule
1
extern/libco
vendored
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit e18e09d634d612a01781168ad4d76be10a7e3bad
|
||||
2
extern/musyx
vendored
2
extern/musyx
vendored
|
|
@ -1 +1 @@
|
|||
Subproject commit a170f2ef4a3f51edb89bc792dff79d55b2c42a89
|
||||
Subproject commit 37e8ecd4e6503e90b97ea81cd7d669357861d501
|
||||
|
|
@ -3,6 +3,8 @@
|
|||
|
||||
#include "game/object.h"
|
||||
|
||||
#define ARRAY_COUNT(arr) (s32)(sizeof(arr) / sizeof(arr[0]))
|
||||
|
||||
typedef void (*VoidFuncs)(void);
|
||||
typedef void (*ObjFuncs)(omObjData *);
|
||||
|
||||
|
|
@ -16,6 +18,9 @@ void fn_1_334(void);
|
|||
void fn_1_388(u8, s32);
|
||||
void fn_1_3C4(u8);
|
||||
void fn_1_404(void);
|
||||
#ifndef __MWERKS__
|
||||
s32 fn_1_4C0(u8 arg0);
|
||||
#endif
|
||||
s32 fn_1_508(u8);
|
||||
s32 fn_1_53C(u8);
|
||||
void fn_1_568(s16, s16, s16);
|
||||
|
|
@ -35,6 +40,7 @@ void fn_1_2564(void);
|
|||
void fn_1_25C0(void);
|
||||
s32 fn_1_2880(void);
|
||||
#ifndef __MWERKS__
|
||||
void fn_1_2770(u8 arg0);
|
||||
s16 fn_1_28B8(u8 arg0);
|
||||
s16 fn_1_28D4(void);
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -205,6 +205,10 @@ void fn_1_28AC(s32 arg0);
|
|||
s32 fn_1_28DC(void);
|
||||
float fn_1_2FD4(float arg8, float arg9, float argA);
|
||||
float fn_1_30F0(float arg8, float arg9);
|
||||
void fn_1_31A4(Process *process);
|
||||
void fn_1_31F8(void);
|
||||
void fn_1_33A8(Process *objman);
|
||||
void fn_1_3484(void);
|
||||
s32 fn_1_76B8(Vec arg0, Vec arg1, u16 arg2);
|
||||
void fn_1_77E8(void *arg0);
|
||||
void fn_1_77F8(u16 arg0, Vec *arg1);
|
||||
|
|
@ -213,5 +217,6 @@ void fn_1_7888(u16 arg0, u16 arg1, Vec *arg2);
|
|||
s32 fn_1_79F8(s16 arg0, char *arg1, Mtx arg2);
|
||||
void fn_1_7AC4(HsfObject *arg0, Mtx arg1, char *arg2, Mtx arg3);
|
||||
void fn_1_7E30(Process *objman);
|
||||
void fn_1_806C(void);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
#include "game/hsfman.h"
|
||||
#include "game/object.h"
|
||||
|
||||
extern u8 texMtxTbl[];
|
||||
SHARED_SYM extern u8 texMtxTbl[];
|
||||
|
||||
#define FABS(x) ((x < 0.0f) ? -(x) : (x))
|
||||
|
||||
|
|
@ -257,6 +257,7 @@ float fn_1_7520(float, float *, float *, float *, s32);
|
|||
void fn_1_7674(float *, Vec *, Vec *, s32);
|
||||
void fn_1_7A54(float, Vec *, float *, Vec *, Vec *, s32);
|
||||
// map.c
|
||||
void fn_1_8780(s16 arg0, s16 arg1);
|
||||
void fn_1_95C0(ModelData *, Mtx);
|
||||
AnimData **fn_1_9734(s16);
|
||||
void fn_1_9DC8(unkSubStruct2 *);
|
||||
|
|
@ -266,11 +267,16 @@ s16 fn_1_A94C(u32, s16, s16);
|
|||
void fn_1_ACF4(s16, s16, s16, s16, s16, s16);
|
||||
void fn_1_AF48(s16);
|
||||
u8 fn_1_AFC8(s16, u8, s32, s16, s16);
|
||||
u8 fn_1_B038(s16 arg0, u8 arg1, s32 arg2);
|
||||
s32 fn_1_B0B8(s16, u8, s16);
|
||||
void fn_1_B634(void);
|
||||
void fn_1_B864(s16, float, float, float);
|
||||
void fn_1_B8D0(s16 arg0, s16 arg1, f32 arg8, f32 arg9, f32 argA);
|
||||
void fn_1_BB4C(s16, float, float, float);
|
||||
void fn_1_BC9C(s16, float, float, float);
|
||||
void fn_1_BD08(s16, s16, float, float, float);
|
||||
void fn_1_BE30(s16 arg0, s16 arg1, s32 arg2);
|
||||
void fn_1_C110(s16 arg0, s16 arg1, u8 arg2, u8 arg3, u8 arg4, u8 arg5);
|
||||
void fn_1_C264(s16, u8);
|
||||
void fn_1_C2D0(s16, s16, u8);
|
||||
void fn_1_C410(s16, s16, u8, u8);
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
#include "dolphin.h"
|
||||
#ifndef M424DLL_H
|
||||
#define M424DLL_H
|
||||
|
||||
#include "game/object.h"
|
||||
|
||||
|
|
@ -31,6 +32,7 @@ extern M424DllBallStruct2 lbl_1_bss_60[9];
|
|||
extern u8 lbl_1_bss_58;
|
||||
extern s16 lbl_1_bss_24[4];
|
||||
|
||||
s32 fn_1_FE0(void);
|
||||
float fn_1_1358(float, float);
|
||||
float fn_1_1470(float, float, float);
|
||||
omObjData *fn_1_1AB8(Process *);
|
||||
|
|
@ -42,9 +44,13 @@ void fn_1_2720(Process *);
|
|||
void fn_1_2880(void);
|
||||
Vec *fn_1_8A00(u8);
|
||||
s32 fn_1_8A2C(void);
|
||||
s32 fn_1_907C(Vec *arg0, Vec *arg1);
|
||||
omObjData *fn_1_93F0(Process *);
|
||||
void fn_1_94A4(void);
|
||||
s32 fn_1_B804(void);
|
||||
s32 fn_1_B888(void);
|
||||
s32 fn_1_B8AC(void);
|
||||
s32 fn_1_B924(void);
|
||||
void fn_1_C2E0(s32 arg0);
|
||||
|
||||
#endif
|
||||
|
|
@ -6,6 +6,9 @@
|
|||
void fn_1_1C44(s32 arg0, s32 arg1);
|
||||
s32 fn_1_1C88(s32 arg0);
|
||||
s32 fn_1_1CB8(void);
|
||||
#ifndef __MWERKS__
|
||||
s16 fn_1_1D44(void);
|
||||
#endif
|
||||
s32 fn_1_1D54(void);
|
||||
void fn_1_1D64(s32 arg0);
|
||||
s32 fn_1_1D74(s32 arg0);
|
||||
|
|
|
|||
|
|
@ -109,7 +109,7 @@ typedef struct _unkStruct6 {
|
|||
m440Func6 unk38;
|
||||
s16 unk3C;
|
||||
s16 unk3E;
|
||||
} unkStruct6; // sizeof 0x40
|
||||
} unkStruct6; // sizeof 0x40 // TODO same as unkStruct14?
|
||||
|
||||
typedef struct _unkStruct7 {
|
||||
GXColor unk0;
|
||||
|
|
@ -178,7 +178,8 @@ typedef struct _unkStruct13 {
|
|||
typedef struct _unkStruct14 {
|
||||
s16 unk0;
|
||||
s16 unk2;
|
||||
char unk4[0x8];
|
||||
char unk4[4];
|
||||
s32 unk8;
|
||||
void *unkC;
|
||||
char unk10[0x4];
|
||||
void *unk14;
|
||||
|
|
@ -240,6 +241,7 @@ typedef struct _unkObjStruct {
|
|||
float unk68;
|
||||
float unk6C;
|
||||
float unk70;
|
||||
char unk74[0x4];
|
||||
} unkObjStruct;
|
||||
|
||||
#if VERSION_NTSC
|
||||
|
|
|
|||
|
|
@ -235,6 +235,7 @@ void fn_1_34A0(unkStruct5 *, unkStruct4 **, s32, s32);
|
|||
s32 m446DeckPushCard(unkStruct5 *, unkStruct4 *, s32);
|
||||
s32 m446DeckPopCard(unkStruct2 **, unkStruct4 **);
|
||||
void fn_1_38B0(unkStruct2 **);
|
||||
// void fn_1_38E0(u32 arg0); // TODO
|
||||
s32 fn_1_38F0(void);
|
||||
// table.c
|
||||
s32 fn_1_3924(void);
|
||||
|
|
|
|||
|
|
@ -29,9 +29,6 @@ typedef struct {
|
|||
HsfObject *obj; // 0030
|
||||
} HuObjUnk;
|
||||
|
||||
extern Vec CRot;
|
||||
extern Vec Center;
|
||||
extern float CZoom;
|
||||
void fn_1_29C();
|
||||
void fn_1_28F8(Vec *arg0, Vec *arg1);
|
||||
void fn_1_37DC(omObjData *);
|
||||
|
|
|
|||
|
|
@ -27,7 +27,9 @@ typedef struct datalist_sprite {
|
|||
GXColor color;
|
||||
} DataListSprite;
|
||||
|
||||
// void fn_1_1EC0(s16 view);
|
||||
#ifndef __MWERKS__
|
||||
void fn_1_1EC0(s16 view);
|
||||
#endif
|
||||
|
||||
s32 fn_1_2490(void);
|
||||
s32 fn_1_37DC(void);
|
||||
|
|
|
|||
|
|
@ -8,6 +8,8 @@
|
|||
#include "game/window.h"
|
||||
#include "game/object.h"
|
||||
|
||||
#define ARRAY_COUNT(arr) (s32)(sizeof(arr) / sizeof(arr[0]))
|
||||
|
||||
enum {
|
||||
MAPOBJ_MAX = 12
|
||||
};
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ typedef struct tutorial_scene {
|
|||
TutorialSceneFunc func;
|
||||
} TutorialScene;
|
||||
|
||||
extern s32 boardTutorialData[4];
|
||||
SHARED_SYM extern s32 boardTutorialData[4];
|
||||
|
||||
void HostPosSet(s16);
|
||||
void fn_1_1FB0(void);
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ typedef void (*ARCallback)(void);
|
|||
|
||||
ARCallback ARRegisterDMACallback(ARCallback callback);
|
||||
u32 ARGetDMAStatus(void);
|
||||
void ARStartDMA(u32 type, u32 mainmem_addr, u32 aram_addr, u32 length);
|
||||
void ARStartDMA(u32 type, uintptr_t mainmem_addr, u32 aram_addr, u32 length);
|
||||
u32 ARInit(u32* stack_index_addr, u32 num_entries);
|
||||
u32 ARGetBaseAddress(void);
|
||||
BOOL ARCheckInit(void);
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ extern "C" {
|
|||
#define ARQ_PRIORITY_LOW 0
|
||||
#define ARQ_PRIORITY_HIGH 1
|
||||
|
||||
typedef void (*ARQCallback)(u32 pointerToARQRequest);
|
||||
typedef void (*ARQCallback)(uintptr_t pointerToARQRequest);
|
||||
|
||||
typedef struct ARQRequest {
|
||||
|
||||
|
|
@ -37,7 +37,7 @@ typedef struct ARQRequest {
|
|||
|
||||
void ARQInit(void);
|
||||
void ARQReset(void);
|
||||
void ARQPostRequest(ARQRequest* task, u32 owner, u32 type, u32 priority, u32 source, u32 dest,
|
||||
void ARQPostRequest(ARQRequest* task, u32 owner, u32 type, u32 priority, uintptr_t source, uintptr_t dest,
|
||||
u32 length, ARQCallback callback);
|
||||
void ARQRemoveRequest(ARQRequest* task);
|
||||
void ARQRemoveOwnerRequest(u32 owner);
|
||||
|
|
|
|||
|
|
@ -29,10 +29,10 @@ typedef enum {
|
|||
DEMO_STAT_IO = 4
|
||||
} DEMO_STAT_DISP;
|
||||
|
||||
extern unsigned char DemoStatEnable;
|
||||
|
||||
void DEMOSetStats(DemoStatData * stat, unsigned long nstats, DEMO_STAT_DISP disp);
|
||||
void DEMOUpdateStats(unsigned char inc);
|
||||
void DEMOPrintStats(void);
|
||||
void DEMOUpdateStats(unsigned char inc);
|
||||
void DEMOPrintStats(void);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -20,9 +20,10 @@ void GXSetTevIndirect(GXTevStageID tev_stage, GXIndTexStageID ind_stage, GXIndTe
|
|||
GXIndTexWrap wrap_t, GXBool add_prev, GXBool ind_lod,
|
||||
GXIndTexAlphaSel alpha_sel);
|
||||
//Must be implicit to match m455dll
|
||||
//void GXSetTevIndWarp(GXTevStageID tev_stage, GXIndTexStageID ind_stage, GXBool signed_offsets,
|
||||
// GXBool replace_mode, GXIndTexMtxID matrix_sel);
|
||||
|
||||
#ifndef __MWERKS__
|
||||
void GXSetTevIndWarp(GXTevStageID tev_stage, GXIndTexStageID ind_stage, GXBool signed_offsets,
|
||||
GXBool replace_mode, GXIndTexMtxID matrix_sel);
|
||||
#endif
|
||||
void GXSetTevIndTile (GXTevStageID tev_stage, GXIndTexStageID ind_stage,
|
||||
u16 tilesize_s, u16 tilesize_t,
|
||||
u16 tilespacing_s, u16 tilespacing_t,
|
||||
|
|
|
|||
|
|
@ -7,8 +7,15 @@
|
|||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef AURORA
|
||||
#define GXCallDisplayListNative GXCallDisplayListLE
|
||||
#else
|
||||
#define GXCallDisplayListNative GXCallDisplayList
|
||||
#endif
|
||||
|
||||
void GXBeginDisplayList(void* list, u32 size);
|
||||
u32 GXEndDisplayList(void);
|
||||
void GXCallDisplayListLE(const void* list, u32 nbytes);
|
||||
void GXCallDisplayList(const void* list, u32 nbytes);
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
|
|
|||
|
|
@ -20,8 +20,10 @@ void GXSetPointSize(u8 pointSize, GXTexOffset texOffsets);
|
|||
void GXEnableTexOffsets(GXTexCoordID coord, GXBool line_enable, GXBool point_enable);
|
||||
#ifdef TARGET_PC
|
||||
void GXSetArray(GXAttr attr, const void* data, u32 size, u8 stride);
|
||||
#define GXSETARRAY(attr, data, size, stride) GXSetArray((attr), (data), (size), (stride))
|
||||
#else
|
||||
void GXSetArray(GXAttr attr, const void* data, u8 stride);
|
||||
#define GXSETARRAY(attr, data, size, stride) GXSetArray((attr), (data), (stride))
|
||||
#endif
|
||||
void GXInvalidateVtxCache(void);
|
||||
|
||||
|
|
|
|||
|
|
@ -2,8 +2,9 @@
|
|||
#define _DOLPHIN_GXPRIV
|
||||
|
||||
#include "dolphin/gx.h"
|
||||
#include "dolphin/os.h"
|
||||
|
||||
#ifdef DEBUG
|
||||
#ifndef NDEBUG
|
||||
#define ASSERTLINE(line, cond) \
|
||||
((cond) || (OSPanic(__FILE__, line, "Failed assertion " #cond), 0))
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,11 @@
|
|||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#if defined(__MWERKS__) && !defined(GEKKO)
|
||||
#define GEKKO
|
||||
#endif
|
||||
|
||||
#ifndef GEKKO
|
||||
#define MTX_USE_C
|
||||
#undef MTX_USE_PS
|
||||
|
|
@ -35,6 +39,7 @@ typedef struct {
|
|||
#define MTXRadToDeg(a) ((a)*57.29577951f)
|
||||
#define MTXRowCol(m, r, c) ((m)[(r)][(c)])
|
||||
|
||||
|
||||
void C_MTXIdentity(Mtx m);
|
||||
void C_MTXCopy(const Mtx src, Mtx dst);
|
||||
void C_MTXConcat(const Mtx a, const Mtx b, Mtx ab);
|
||||
|
|
@ -42,6 +47,8 @@ void C_MTXConcatArray(const Mtx a, const Mtx* srcBase, Mtx* dstBase, u32 count);
|
|||
void C_MTXTranspose(const Mtx src, Mtx xPose);
|
||||
u32 C_MTXInverse(const Mtx src, Mtx inv);
|
||||
u32 C_MTXInvXpose(const Mtx src, Mtx invX);
|
||||
void C_MTXReorder(const Mtx src, ROMtx dest);
|
||||
void C_MTXROMultVecArray(const ROMtx m, const Vec *srcBase, Vec *dstBase, u32 count);
|
||||
|
||||
#ifdef GEKKO
|
||||
void PSMTXIdentity(Mtx m);
|
||||
|
|
@ -302,6 +309,20 @@ void PSMTXMultS16VecArray(const Mtx m, const S16Vec* srcBase, Vec* dstBase, u32
|
|||
void PSMTXROMultS16VecArray(const ROMtx m, const S16Vec* srcBase, Vec* dstBase, u32 count);
|
||||
#endif
|
||||
|
||||
#ifdef MTX_USE_PS
|
||||
#define MTXReorder PSMTXReorder
|
||||
#define MTXROMultVecArray PSMTXROMultVecArray
|
||||
#define MTXROSkin2VecArray PSMTXROSkin2VecArray
|
||||
#define MTXROMultS16VecArray PSMTXROMultS16VecArray
|
||||
#define MTXMultS16VecArray PSMTXMultS16VecArray
|
||||
#else // MTX_USE_C
|
||||
#define MTXReorder C_MTXReorder
|
||||
#define MTXROMultVecArray C_MTXROMultVecArray
|
||||
#define MTXROSkin2VecArray C_MTXROSkin2VecArray
|
||||
#define MTXROMultS16VecArray C_MTXROMultS16VecArray
|
||||
#define MTXMultS16VecArray C_MTXMultS16VecArray
|
||||
#endif
|
||||
|
||||
void MTXInitStack(MtxStack* sPtr, u32 numMtx);
|
||||
MtxPtr MTXPush(MtxStack* sPtr, const Mtx m);
|
||||
MtxPtr MTXPushFwd(MtxStack* sPtr, const Mtx m);
|
||||
|
|
|
|||
|
|
@ -23,10 +23,15 @@ extern "C" {
|
|||
#endif
|
||||
typedef s64 OSTime;
|
||||
typedef u32 OSTick;
|
||||
#ifdef __MWERKS__
|
||||
u32 __OSBusClock AT_ADDRESS(OS_BASE_CACHED | 0x00F8); // sync with OSLoMem.h
|
||||
u32 __OSCoreClock AT_ADDRESS(OS_BASE_CACHED | 0x00FC); // sync with OSLoMem.h
|
||||
#define OS_BUS_CLOCK (u32) __OSBusClock
|
||||
#define OS_CORE_CLOCK __OSCoreClock
|
||||
#else
|
||||
#define OS_BUS_CLOCK 162000000ull
|
||||
#define OS_CORE_CLOCK 486000000ull
|
||||
#endif
|
||||
#define OS_TIMER_CLOCK (OS_BUS_CLOCK / 4)
|
||||
|
||||
#ifndef _DEBUG
|
||||
|
|
@ -57,8 +62,8 @@ u32 OSUncachedToCached(void *ucaddr);
|
|||
|
||||
#define OSDiffTick(tick1, tick0) ((s32)(tick1) - (s32)(tick0))
|
||||
|
||||
#define OSRoundUp32B(x) (((u32)(x) + 0x1F) & ~(0x1F))
|
||||
#define OSRoundDown32B(x) (((u32)(x)) & ~(0x1F))
|
||||
#define OSRoundUp32B(x) (((size_t)(x) + 0x1F) & ~(0x1F))
|
||||
#define OSRoundDown32B(x) (((size_t)(x)) & ~(0x1F))
|
||||
|
||||
#define OSRoundUp(x, align) (((x) + (align)-1) & (-(align)))
|
||||
#define OSRoundUpPtr(x, align) ((void*)((((u32)(x)) + (align)-1) & (~((align)-1))))
|
||||
|
|
|
|||
|
|
@ -9,17 +9,17 @@ extern "C" {
|
|||
typedef int OSHeapHandle;
|
||||
typedef void (*OSAllocVisitor)(void *obj, u32 size);
|
||||
void *OSInitAlloc(void *arenaStart, void *arenaEnd, int maxHeaps);
|
||||
OSHeapHandle OSCreateHeap(void *start, void *end);
|
||||
uintptr_t OSCreateHeap(void *start, void *end);
|
||||
void OSDestroyHeap(OSHeapHandle heap);
|
||||
void OSAddToHeap(OSHeapHandle heap, void *start, void *end);
|
||||
OSHeapHandle OSSetCurrentHeap(OSHeapHandle heap);
|
||||
void *OSAllocFromHeap(OSHeapHandle heap, u32 size);
|
||||
void *OSAllocFromHeap(int heap, unsigned long size);
|
||||
void *OSAllocFixed(void **rstart, void **rend);
|
||||
void OSFreeToHeap(OSHeapHandle heap, void *ptr);
|
||||
long OSCheckHeap(OSHeapHandle heap);
|
||||
void OSDumpHeap(OSHeapHandle heap);
|
||||
u32 OSReferentSize(void *ptr);
|
||||
void OSVisitAllocated(OSAllocVisitor visitor);
|
||||
unsigned long OSReferentSize(void *ptr);
|
||||
void OSVisitAllocated(void (*visitor)(void *, unsigned long));
|
||||
extern volatile OSHeapHandle __OSCurrHeap;
|
||||
#define OSAlloc(size) OSAllocFromHeap(__OSCurrHeap, (size))
|
||||
#define OSFree(ptr) OSFreeToHeap(__OSCurrHeap, (ptr))
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
#ifndef _DOLPHIN_OSFASTCAST
|
||||
#define _DOLPHIN_OSFASTCAST
|
||||
|
||||
#include "dolphin/types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
|
@ -44,6 +46,7 @@ static inline void OSInitFastCast(void) {
|
|||
|
||||
static inline s16 __OSf32tos16(register f32 inF)
|
||||
{
|
||||
#ifdef __MWERKS__
|
||||
u32 tmp;
|
||||
register u32* tmpPtr = &tmp;
|
||||
register s16 out;
|
||||
|
|
@ -55,12 +58,16 @@ static inline s16 __OSf32tos16(register f32 inF)
|
|||
// clang-format on
|
||||
|
||||
return out;
|
||||
#else
|
||||
return (s16) inF;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void OSf32tos16(f32 *f, s16 *out) { *out = __OSf32tos16(*f); }
|
||||
|
||||
static inline u8 __OSf32tou8(register f32 inF)
|
||||
{
|
||||
#ifdef __MWERKS__
|
||||
u32 tmp;
|
||||
register u32 *tmpPtr = &tmp;
|
||||
register u8 out;
|
||||
|
|
@ -72,12 +79,16 @@ static inline u8 __OSf32tou8(register f32 inF)
|
|||
// clang-format on
|
||||
|
||||
return out;
|
||||
#else
|
||||
return (u8)inF;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void OSf32tou8(f32 *f, u8 *out) { *out = __OSf32tou8(*f); }
|
||||
|
||||
static inline s8 __OSf32tos8(register f32 inF)
|
||||
{
|
||||
#ifdef __MWERKS__
|
||||
u32 tmp;
|
||||
register u32 *tmpPtr = &tmp;
|
||||
register s8 out;
|
||||
|
|
@ -90,12 +101,16 @@ static inline s8 __OSf32tos8(register f32 inF)
|
|||
// clang-format on
|
||||
|
||||
return out;
|
||||
#else
|
||||
return (s8) inF;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void OSf32tos8(f32 *f, s8 *out) { *out = __OSf32tos8(*f); }
|
||||
|
||||
static inline u16 __OSf32tou16(register f32 inF)
|
||||
{
|
||||
#ifdef __MWERKS__
|
||||
u32 tmp;
|
||||
register u32 *tmpPtr = &tmp;
|
||||
register u16 out;
|
||||
|
|
@ -107,11 +122,15 @@ static inline u16 __OSf32tou16(register f32 inF)
|
|||
// clang-format on
|
||||
|
||||
return out;
|
||||
#else
|
||||
return (u16) inF;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void OSf32tou16(f32 *f, u16 *out) { *out = __OSf32tou16(*f); }
|
||||
|
||||
static inline float __OSs8tof32(register const s8* arg) {
|
||||
#ifdef __MWERKS__
|
||||
register float ret;
|
||||
|
||||
asm {
|
||||
|
|
@ -119,11 +138,15 @@ static inline float __OSs8tof32(register const s8* arg) {
|
|||
}
|
||||
|
||||
return ret;
|
||||
#else
|
||||
return (f32)*arg;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void OSs8tof32(const s8* in, float* out) { *out = __OSs8tof32(in); }
|
||||
|
||||
static inline float __OSs16tof32(register const s16* arg) {
|
||||
#ifdef __MWERKS__
|
||||
register float ret;
|
||||
|
||||
asm {
|
||||
|
|
@ -131,11 +154,15 @@ static inline float __OSs16tof32(register const s16* arg) {
|
|||
}
|
||||
|
||||
return ret;
|
||||
#else
|
||||
return (f32)*arg;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void OSs16tof32(const s16* in, float* out) { *out = __OSs16tof32(in); }
|
||||
|
||||
static inline float __OSu8tof32(register const u8* arg) {
|
||||
#ifdef __MWERKS__
|
||||
register float ret;
|
||||
|
||||
asm {
|
||||
|
|
@ -143,11 +170,15 @@ static inline float __OSu8tof32(register const u8* arg) {
|
|||
}
|
||||
|
||||
return ret;
|
||||
#else
|
||||
return (f32)*arg;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void OSu8tof32(const u8* in, float* out) { *out = __OSu8tof32(in); }
|
||||
|
||||
static inline float __OSu16tof32(register const u16* arg) {
|
||||
#ifdef __MWERKS__
|
||||
register float ret;
|
||||
|
||||
asm {
|
||||
|
|
@ -155,6 +186,9 @@ static inline float __OSu16tof32(register const u16* arg) {
|
|||
}
|
||||
|
||||
return ret;
|
||||
#else
|
||||
return (f32)*arg;
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void OSu16tof32(const u16* in, float* out) { *out = __OSu16tof32(in); }
|
||||
|
|
|
|||
|
|
@ -84,8 +84,8 @@ PADSamplingCallback PADSetSamplingCallback(PADSamplingCallback);
|
|||
#ifdef TARGET_PC
|
||||
/* New API to facilitate controller interactions */
|
||||
typedef struct PADDeadZones {
|
||||
bool emulateTriggers;
|
||||
bool useDeadzones;
|
||||
BOOL emulateTriggers;
|
||||
BOOL useDeadzones;
|
||||
u16 stickDeadZone;
|
||||
u16 substickDeadZone;
|
||||
u16 leftTriggerActivationZone;
|
||||
|
|
@ -118,7 +118,7 @@ const char* PADGetNativeButtonName(u32 button);
|
|||
/* Returns any pressed native button */
|
||||
s32 PADGetNativeButtonPressed(u32 port);
|
||||
void PADRestoreDefaultMapping(u32 port);
|
||||
void PADBlockInput(bool block);
|
||||
void PADBlockInput(BOOL block);
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
|
|
|||
|
|
@ -20,6 +20,9 @@ typedef unsigned char u8;
|
|||
typedef unsigned short int u16;
|
||||
typedef unsigned long u32;
|
||||
typedef unsigned long long int u64;
|
||||
|
||||
typedef u32 size_t;
|
||||
typedef u32 uintptr_t;
|
||||
#endif
|
||||
|
||||
typedef volatile u8 vu8;
|
||||
|
|
@ -64,7 +67,7 @@ typedef int BOOL;
|
|||
#define NULL ((void *)0)
|
||||
#endif
|
||||
#endif
|
||||
#if !defined(__cplusplus) || __cplusplus < 201103L
|
||||
#if !defined(__cplusplus)
|
||||
#ifndef nullptr
|
||||
#define nullptr NULL
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ u32 VIGetTvFormat(void);
|
|||
void VISetNextFrameBuffer(void* fb);
|
||||
void VIWaitForRetrace(void);
|
||||
void VISetBlack(BOOL black);
|
||||
void VIConfigurePan(u16 xOrg, u16 yOrg, u16 width, u16 height);
|
||||
|
||||
#ifdef TARGET_PC
|
||||
void VISetWindowTitle(const char* title);
|
||||
|
|
|
|||
|
|
@ -4,6 +4,10 @@
|
|||
#include "math.h"
|
||||
#include "dolphin/mtx.h"
|
||||
|
||||
#ifndef M_PI
|
||||
#define M_PI 3.141592653589793
|
||||
#endif
|
||||
|
||||
typedef struct vec2f {
|
||||
float x;
|
||||
float y;
|
||||
|
|
@ -33,7 +37,8 @@ typedef struct vec2f {
|
|||
#define atan2d(y, x) (180.0*(atan2((y), (x)) / M_PI))
|
||||
|
||||
#ifndef __MWERKS__
|
||||
void HuSetVecF(Vec* arg0, f32 arg8, f32 arg9, f32 argA)
|
||||
void HuSetVecF(Vec *arg0, f32 arg8, f32 arg9, f32 argA);
|
||||
void HuSubVecF(Vec* out, Vec* in, Vec* sub);
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -78,6 +78,13 @@ typedef struct anim_data {
|
|||
/* 0x08 */ AnimBankData *bank;
|
||||
/* 0x0C */ AnimPatData *pat;
|
||||
/* 0x10 */ AnimBmpData *bmp;
|
||||
#ifdef TARGET_PC
|
||||
u32 valid;
|
||||
#endif
|
||||
} AnimData; //sizeof 0x14
|
||||
|
||||
#ifdef TARGET_PC
|
||||
#define ANIM_DATA_ALLOCATION_VALID 0xD3D3D3D3
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
#define _GAME_AUDIO_H
|
||||
|
||||
#include "dolphin.h"
|
||||
#include "version.h"
|
||||
|
||||
typedef struct sndGrpTbl_s {
|
||||
s16 ovl;
|
||||
|
|
@ -74,6 +75,6 @@ extern float Snd3DDistOffset;
|
|||
extern s32 musicOffF;
|
||||
extern u8 fadeStat;
|
||||
|
||||
extern SNDGRPTBL sndGrpTable[];
|
||||
SHARED_SYM extern SNDGRPTBL sndGrpTable[];
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -3,6 +3,8 @@
|
|||
|
||||
#include "dolphin.h"
|
||||
|
||||
void BoardLandBlueExec(s32 player, s32 space);
|
||||
void BoardLandRedExec(s32 player, s32 space);
|
||||
void BoardEventLandBlue(s32, s32);
|
||||
void BoardEventLandRed(s32, s32);
|
||||
s8 BoardCoinChgCreate(Vec*, s8);
|
||||
|
|
|
|||
|
|
@ -8,10 +8,6 @@ s16 BoardBooCreate(s32 arg0, Vec *arg1);
|
|||
void BoardBooKill(void);
|
||||
s32 BoardBooStealTypeSet(s32 arg0);
|
||||
s32 BoardBooStealMain(void);
|
||||
BOOL CheckBallCoinDone(void);
|
||||
void TakeBallStar(void);
|
||||
void ExecTakeBallStar(omObjData *arg0);
|
||||
BOOL CheckTakeBallStarDone(void);
|
||||
s32 BoardBooStealValueGet(s16 *arg0, s16 *arg1);
|
||||
BOOL BoardBooStealLightCheck(void);
|
||||
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ void BoardBooHouseHostSet(s16);
|
|||
s16 BoardBooHouseHostGet(void);
|
||||
void BoardBooHouseCreate(void);
|
||||
void BoardBooHouseExec(s32);
|
||||
void BoardBooHouseKill(void);
|
||||
|
||||
s32 BoardBooComUseCheck(s32);
|
||||
void BoardBooHouseTutorialExec(void);
|
||||
|
|
|
|||
8
include/game/board/bowser.h
Normal file
8
include/game/board/bowser.h
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
#ifndef _BOARD_BOWSER_H
|
||||
#define _BOARD_BOWSER_H
|
||||
|
||||
#include "game/process.h"
|
||||
|
||||
void BoardBowserExec(s32 player, s32 space);
|
||||
|
||||
#endif
|
||||
8
include/game/board/fortune.h
Normal file
8
include/game/board/fortune.h
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
#ifndef _BOARD_FORTUNE_H
|
||||
#define _BOARD_FORTUNE_H
|
||||
|
||||
#include "game/process.h"
|
||||
|
||||
void BoardFortuneExec(s32 player, s32 space);
|
||||
|
||||
#endif
|
||||
|
|
@ -6,5 +6,8 @@
|
|||
void BoardItemStart(s32 arg0, s32 arg1);
|
||||
BOOL BoardItemDoneCheck(void);
|
||||
void BoardItemBagItemSet(s16 *arg0);
|
||||
#ifndef __MWERKS__
|
||||
void BoardItemPlayerRestore(s32 arg0, s32 arg1);
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,72 +1,73 @@
|
|||
#ifndef _BOARD_MAIN_H
|
||||
#define _BOARD_MAIN_H
|
||||
|
||||
#include "dolphin.h"
|
||||
#include "game/data.h"
|
||||
#include "game/gamework_data.h"
|
||||
#include "game/object.h"
|
||||
#include "game/data.h"
|
||||
#include "dolphin.h"
|
||||
|
||||
#define BOARD_ID_MAIN1 0 //TOADS_MIDWAY_MADNESS
|
||||
#define BOARD_ID_MAIN2 1 //GOOMBAS_GREEDY_GALA
|
||||
#define BOARD_ID_MAIN3 2 //SHY_GUYS_JUNGLE_JAM
|
||||
#define BOARD_ID_MAIN4 3 //BOOS_HAUNTED_BASH
|
||||
#define BOARD_ID_MAIN5 4 //KOOPAS_SEASIDE_SOIREE
|
||||
#define BOARD_ID_MAIN6 5 //BOWSERS_GNARLY_PARTY
|
||||
#define BOARD_ID_TUTORIAL 6 //TUTORIAL_BOARD
|
||||
#define BOARD_ID_EXTRA1 7 //MEGA_BOARD_MAYHEM
|
||||
#define BOARD_ID_EXTRA2 8 //MINI_BOARD_MAD_DASH
|
||||
|
||||
#define BOARD_ID_MAIN1 0 // TOADS_MIDWAY_MADNESS
|
||||
#define BOARD_ID_MAIN2 1 // GOOMBAS_GREEDY_GALA
|
||||
#define BOARD_ID_MAIN3 2 // SHY_GUYS_JUNGLE_JAM
|
||||
#define BOARD_ID_MAIN4 3 // BOOS_HAUNTED_BASH
|
||||
#define BOARD_ID_MAIN5 4 // KOOPAS_SEASIDE_SOIREE
|
||||
#define BOARD_ID_MAIN6 5 // BOWSERS_GNARLY_PARTY
|
||||
#define BOARD_ID_TUTORIAL 6 // TUTORIAL_BOARD
|
||||
#define BOARD_ID_EXTRA1 7 // MEGA_BOARD_MAYHEM
|
||||
#define BOARD_ID_EXTRA2 8 // MINI_BOARD_MAD_DASH
|
||||
|
||||
#define BOARD_FABS(value) ((value < 0) ? -(value) : (value))
|
||||
|
||||
typedef struct board_focus_data {
|
||||
u16 view_type;
|
||||
s16 time;
|
||||
s16 max_time;
|
||||
float fov_start;
|
||||
float fov_end;
|
||||
float zoom_start;
|
||||
float zoom_end;
|
||||
Vec rot_start;
|
||||
Vec rot_end;
|
||||
Vec target_start;
|
||||
Vec target_end;
|
||||
u16 view_type;
|
||||
s16 time;
|
||||
s16 max_time;
|
||||
float fov_start;
|
||||
float fov_end;
|
||||
float zoom_start;
|
||||
float zoom_end;
|
||||
Vec rot_start;
|
||||
Vec rot_end;
|
||||
Vec target_start;
|
||||
Vec target_end;
|
||||
} BoardFocusData;
|
||||
|
||||
typedef struct board_camera_data {
|
||||
struct {
|
||||
u8 hide_all : 1;
|
||||
u8 moving : 1;
|
||||
u8 quaking : 1;
|
||||
};
|
||||
u16 mask;
|
||||
s16 target_mdl;
|
||||
s16 target_space;
|
||||
s32 quake_timer;
|
||||
float quake_strength;
|
||||
float fov;
|
||||
float near;
|
||||
float far;
|
||||
float aspect;
|
||||
float viewport_x;
|
||||
float viewport_y;
|
||||
float viewport_w;
|
||||
float viewport_h;
|
||||
float viewport_near;
|
||||
float viewport_far;
|
||||
Vec pos;
|
||||
Vec up;
|
||||
Vec target;
|
||||
Vec offset;
|
||||
Vec rot;
|
||||
float zoom;
|
||||
void (*pos_calc)(struct board_camera_data *);
|
||||
BoardFocusData focus;
|
||||
struct {
|
||||
u8 hide_all : 1;
|
||||
u8 moving : 1;
|
||||
u8 quaking : 1;
|
||||
};
|
||||
u16 mask;
|
||||
s16 target_mdl;
|
||||
s16 target_space;
|
||||
s32 quake_timer;
|
||||
float quake_strength;
|
||||
float fov;
|
||||
float nnear;
|
||||
float ffar;
|
||||
float aspect;
|
||||
float viewport_x;
|
||||
float viewport_y;
|
||||
float viewport_w;
|
||||
float viewport_h;
|
||||
float viewport_near;
|
||||
float viewport_far;
|
||||
Vec pos;
|
||||
Vec up;
|
||||
Vec target;
|
||||
Vec offset;
|
||||
Vec rot;
|
||||
float zoom;
|
||||
void (*pos_calc)(struct board_camera_data *);
|
||||
BoardFocusData focus;
|
||||
} BoardCameraData;
|
||||
|
||||
extern BoardCameraData boardCamera;
|
||||
extern Process *boardObjMan;
|
||||
extern Process *boardMainProc;
|
||||
extern u32 boardRandSeed;
|
||||
SHARED_SYM extern Process *boardObjMan;
|
||||
SHARED_SYM extern Process *boardMainProc;
|
||||
SHARED_SYM extern u32 boardRandSeed;
|
||||
extern omObjData *boardMainObj;
|
||||
|
||||
typedef void (*BoardFunc)(void);
|
||||
|
|
@ -78,11 +79,11 @@ typedef void (*BoardCameraPosCalcFunc)(BoardCameraData *camera);
|
|||
|
||||
typedef void (*BoardTurnStartHook)(s32 player, s32 space);
|
||||
|
||||
extern BoardTurnStartHook boardTurnStartFunc;
|
||||
extern void (*boardStarShowNextHook)(void);
|
||||
extern void (*boardStarGiveHook)(void);
|
||||
extern BoardBowserHook boardBowserHook;
|
||||
extern BoardFunc boardTurnFunc;
|
||||
SHARED_SYM extern BoardTurnStartHook boardTurnStartFunc;
|
||||
SHARED_SYM extern void (*boardStarShowNextHook)(void);
|
||||
SHARED_SYM extern void (*boardStarGiveHook)(void);
|
||||
SHARED_SYM extern BoardBowserHook boardBowserHook;
|
||||
SHARED_SYM extern BoardFunc boardTurnFunc;
|
||||
extern BoardLightHook boardLightResetHook;
|
||||
extern BoardLightHook boardLightSetHook;
|
||||
|
||||
|
|
@ -119,12 +120,15 @@ void BoardCameraTargetSpaceSet(s32 space);
|
|||
void BoardCameraQuakeSet(s32 duration, float strength);
|
||||
void BoardCameraQuakeReset();
|
||||
void BoardCameraTargetSet(float x, float y, float z);
|
||||
#ifndef __MWERKS__
|
||||
void BoardCameraPosCalcFuncSet(BoardCameraPosCalcFunc func);
|
||||
#endif
|
||||
void BoardCameraPosSet(float x, float y, float z);
|
||||
void BoardCameraXRotZoomSet(float zoom, float x_rot);
|
||||
void BoardCameraZoomSet(float zoom);
|
||||
void BoardCameraRotSet(float x, float y);
|
||||
void BoardCameraNearFarSet(float near, float far);
|
||||
void BoardCameraNearFarGet(float *near, float *far);
|
||||
void BoardCameraNearFarSet(float nnear, float ffar);
|
||||
void BoardCameraNearFarGet(float *nnear, float *ffar);
|
||||
void BoardCameraMotionStart(s16 model_target, Vec *rot_target, float zoom_target, float fov_target);
|
||||
void BoardCameraMotionStartEx(s16 model_target, Vec *rot_target, Vec *offset_end, float zoom_target, float fov_target, s16 max_time);
|
||||
void BoardCameraFovSet(float fov);
|
||||
|
|
@ -166,4 +170,4 @@ void BoardTauntKill(void);
|
|||
s32 BoardDataDirReadAsync(s32 data_num);
|
||||
void BoardDataAsyncWait(s32 status);
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -41,6 +41,7 @@ s32 BoardModelMotionUpdateSet(s16 model, s32 flag);
|
|||
s32 BoardModelVoiceEnableSet(s16 model, s32 motion, s32 flag);
|
||||
s32 BoardModelMotionStart(s16 model, s32 slot, u32 attr);
|
||||
s32 BoardModelMotionShiftSet(s16 model, s32 motion, float time, float shift_time, u32 attr);
|
||||
s32 BoardModelMotionShiftIDGet(s16 model);
|
||||
s32 BoardModelAttrSet(s16 model, u32 attr);
|
||||
s32 BoardModelAttrReset(s16 model, u32 attr);
|
||||
s32 BoardModelMotionTimeSet(s16 model, float time);
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
#include "game/board/space.h"
|
||||
#include "game/board/ui.h"
|
||||
|
||||
extern s16 boardPlayerMdl[4];
|
||||
SHARED_SYM extern s16 boardPlayerMdl[4];
|
||||
|
||||
static inline s32 BoardPlayerHandicapGet(s32 player)
|
||||
{
|
||||
|
|
@ -97,6 +97,9 @@ void BoardJunctionMaskReset(s32);
|
|||
void BoardJunctionMaskZero(void);
|
||||
void BoardPlayerVoiceEnableSet(s32, s32, s32);
|
||||
|
||||
#ifndef __MWERKS__
|
||||
void BoardPlayerMoveBetween(s32 arg0, s32 arg1, s32 arg2);
|
||||
#endif
|
||||
|
||||
void BoardPlayerMoveTo(s32, s32);
|
||||
void BoardPlayerMoveToAsync(s32, s32);
|
||||
|
|
|
|||
|
|
@ -17,6 +17,7 @@ typedef struct board_space {
|
|||
u16 link[BOARD_SPACE_LINKMAX+1];
|
||||
} BoardSpace;
|
||||
|
||||
s32 BoardSpaceWalkExec(s32 player, s32 space);
|
||||
void BoardSpaceWalkEventFuncSet(BoardSpaceEventFunc func);
|
||||
void BoardSpaceWalkMiniEventFuncSet(BoardSpaceEventFunc func);
|
||||
void BoardSpaceLandEventFuncSet(BoardSpaceEventFunc func);
|
||||
|
|
@ -27,6 +28,7 @@ BoardSpace *BoardSpaceGet(s32 layer, s32 index);
|
|||
void BoardSpaceAttrSet(s32 layer, u32 attr);
|
||||
void BoardSpaceAttrReset(s32 layer, u32 attr);
|
||||
u32 BoardSpaceFlagGet(s32 layer, s32 index);
|
||||
void BoardSpaceTypeForce(u16 from, u16 to);
|
||||
s32 BoardSpaceTypeGet(s32 layer, s32 index);
|
||||
void BoardSpaceTypeSet(s32 layer, s32 index, s32 type);
|
||||
s32 BoardSpacePosGet(s32 layer, s32 index, Vec *pos);
|
||||
|
|
@ -40,6 +42,7 @@ s32 BoardSpaceLinkTargetListGet(s32 layer, s32 target, s16 *list);
|
|||
s32 BoardSpaceLinkTypeSearch(s32 layer, s32 target, u16 type);
|
||||
s32 BoardSpaceLinkTransformGet(s32 flag, Vec *pos, Vec *rot, Vec *scale);
|
||||
void BoardSpaceHostSet(s32 space);
|
||||
void BoardSpaceHide(s32 value);
|
||||
void BoardSpaceStarSetIndex(s32 index);
|
||||
s32 BoardSpaceStarGetNext(void);
|
||||
s32 BoardSpaceStarGetRandom(s32 excl_pos);
|
||||
|
|
@ -49,6 +52,7 @@ s32 BoardSpaceStarGetCurr(void);
|
|||
s32 BoardSpaceStarCheck(s32 index);
|
||||
void BoardSpaceLandExec(s32 player, s32 space);
|
||||
void BoardSpaceCameraSet(u16 mask);
|
||||
s32 BoardSpaceBlockExec(s32 player, s32 space);
|
||||
void BoardSpaceBlockPosSet(void);
|
||||
void BoardSpaceInit(s32 data_num);
|
||||
void BoardSpaceDestroy(void);
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
#define _BOARD_TUTORIAL_H
|
||||
|
||||
#include "dolphin/types.h"
|
||||
#include "version.h"
|
||||
|
||||
void BoardTutorialInit(void);
|
||||
void BoardTutorialKill(void);
|
||||
|
|
@ -16,7 +17,7 @@ void BoardTutorialItemSet(s8 arg0);
|
|||
void BoardTutorialHostSet(s16 arg0);
|
||||
void BoardTutorialHostHide(s8 arg0);
|
||||
|
||||
extern s32 boardTutorialData[4];
|
||||
SHARED_SYM extern s32 boardTutorialData[4];
|
||||
extern s8 boardTutorialDirInputX;
|
||||
extern s8 boardTutorialDirInputY;
|
||||
extern s16 boardTutorialDirInputTime;
|
||||
|
|
@ -24,6 +25,6 @@ extern s32 boardTutorialBlockPos;
|
|||
extern s8 boardTutorialBlockItem;
|
||||
extern s8 boardTutorialBlockF;
|
||||
extern s8 boardTutorialUseItem;
|
||||
extern s8 boardTutorialF;
|
||||
SHARED_SYM extern s8 boardTutorialF;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -2,8 +2,9 @@
|
|||
#define _GAME_CARD_H
|
||||
|
||||
#include "dolphin.h"
|
||||
#include "version.h"
|
||||
|
||||
extern u8 UnMountCnt;
|
||||
SHARED_SYM extern u8 UnMountCnt;
|
||||
|
||||
void HuCardInit(void);
|
||||
s32 HuCardCheck(void);
|
||||
|
|
|
|||
|
|
@ -44,8 +44,6 @@ s32 CharModelEffectNpcInit(s16 arg0, s16 arg1, s16 arg2, s16 arg3);
|
|||
s32 CharModelEffectNpcInitSilent(s16 arg0, s16 arg1, s16 arg2);
|
||||
void CharModelStepTypeSet(s16 character, s32 arg1);
|
||||
|
||||
#define CHARNO_MAX 8
|
||||
#define CHAR_NPC_MAX 7
|
||||
#define CHAR_EFFECT_AND_PARTICLE_MAX 8
|
||||
#define GW_CHARACTER_MAX 8
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -34,7 +34,6 @@ s32 HuDataReadChk(s32 data_num);
|
|||
DataReadStat *HuDataGetStatus(void *dir_ptr);
|
||||
void *HuDataGetDirPtr(s32 data_num);
|
||||
DataReadStat *HuDataDirRead(s32 data_num);
|
||||
DataReadStat *HuDataDirReadNum(s32 data_num, s32 num);
|
||||
DataReadStat *HuDataDirSet(void *dir_ptr, s32 data_num);
|
||||
void HuDataDirReadAsyncCallBack(s32 result, DVDFileInfo* fileInfo);
|
||||
s32 HuDataDirReadAsync(s32 data_num);
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
#include "game/flag.h"
|
||||
#include "version.h"
|
||||
|
||||
//HACK: to prevent prototype errors
|
||||
// HACK: to prevent prototype errors
|
||||
extern void HuPadRumbleAllStop(void);
|
||||
|
||||
typedef struct player_config {
|
||||
|
|
@ -17,12 +17,12 @@ typedef struct player_config {
|
|||
} PlayerConfig;
|
||||
|
||||
typedef struct system_state {
|
||||
/* 0x00 */ struct {
|
||||
/* 0x00 */ struct {
|
||||
u8 party : 1;
|
||||
u8 team : 1;
|
||||
};
|
||||
/* 0x01 */ u8 diff_story;
|
||||
/* 0x02 */ struct {
|
||||
/* 0x01 */ u8 diff_story;
|
||||
/* 0x02 */ struct {
|
||||
u16 bonus_star : 1;
|
||||
u16 explain_mg : 1;
|
||||
u16 show_com_mg : 1;
|
||||
|
|
@ -30,35 +30,35 @@ typedef struct system_state {
|
|||
u16 mess_speed : 2;
|
||||
u16 save_mode : 2;
|
||||
};
|
||||
/* 0x04 */ u8 turn;
|
||||
/* 0x05 */ u8 max_turn;
|
||||
/* 0x06 */ u8 star_flag;
|
||||
/* 0x07 */ u8 star_total;
|
||||
/* 0x08 */ struct {
|
||||
u8 star_pos : 3;
|
||||
u8 board : 5;
|
||||
};
|
||||
/* 0x09 */ s8 last5_effect;
|
||||
/* 0x0A */ s8 player_curr;
|
||||
/* 0x0B */ u8 storyCharBit;
|
||||
/* 0x0C */ s8 storyChar;
|
||||
/* 0x0E */ s16 block_pos;
|
||||
/* 0x10 */ u8 ATTRIBUTE_ALIGN(4) board_data[32];
|
||||
/* 0x30 */ u8 mess_delay;
|
||||
/* 0x31 */ struct {
|
||||
/* 0x04 */ u8 turn;
|
||||
/* 0x05 */ u8 max_turn;
|
||||
/* 0x06 */ u8 star_flag;
|
||||
/* 0x07 */ u8 star_total;
|
||||
/* 0x08 */ struct {
|
||||
u8 star_pos : 3;
|
||||
u8 board : 5;
|
||||
};
|
||||
/* 0x09 */ s8 last5_effect;
|
||||
/* 0x0A */ s8 player_curr;
|
||||
/* 0x0B */ u8 storyCharBit;
|
||||
/* 0x0C */ s8 storyChar;
|
||||
/* 0x0E */ s16 block_pos;
|
||||
/* 0x10 */ u8 ATTRIBUTE_ALIGN(4) board_data[32];
|
||||
/* 0x30 */ u8 mess_delay;
|
||||
/* 0x31 */ struct {
|
||||
u8 bowser_loss : 4;
|
||||
u8 bowser_event : 4;
|
||||
};
|
||||
/* 0x32 */ s8 lucky_value;
|
||||
/* 0x34 */ u16 mg_next;
|
||||
/* 0x36 */ s16 mg_type;
|
||||
/* 0x38 */ u16 unk_38;
|
||||
/* 0x3A */ u8 flag[3][16];
|
||||
/* 0x6A */ u8 unk_6A[0x72];
|
||||
} SystemState; //8018fcf8, sizeof 0xDC
|
||||
/* 0x32 */ s8 lucky_value;
|
||||
/* 0x34 */ u16 mg_next;
|
||||
/* 0x36 */ s16 mg_type;
|
||||
/* 0x38 */ u16 unk_38;
|
||||
/* 0x3A */ u8 flag[3][16];
|
||||
/* 0x6A */ u8 unk_6A[0x72];
|
||||
} SystemState; // 8018fcf8, sizeof 0xDC
|
||||
|
||||
typedef struct player_state {
|
||||
/* 0x00 */ struct {
|
||||
/* 0x00 */ struct {
|
||||
u16 diff : 2;
|
||||
u16 com : 1;
|
||||
u16 character : 4;
|
||||
|
|
@ -66,15 +66,15 @@ typedef struct player_state {
|
|||
u16 draw_ticket : 1;
|
||||
u16 ticket_player : 6;
|
||||
};
|
||||
/* 0x02 */ struct {
|
||||
/* 0x02 */ struct {
|
||||
u8 team : 1;
|
||||
u8 spark : 1;
|
||||
u8 player_idx : 2;
|
||||
};
|
||||
/* 0x03 */ s8 handicap;
|
||||
/* 0x04 */ s8 port;
|
||||
/* 0x05 */ s8 items[3];
|
||||
/* 0x08 */ struct {
|
||||
/* 0x03 */ s8 handicap;
|
||||
/* 0x04 */ s8 port;
|
||||
/* 0x05 */ s8 items[3];
|
||||
/* 0x08 */ struct {
|
||||
u16 color : 2;
|
||||
u16 moving : 1;
|
||||
u16 jump : 1;
|
||||
|
|
@ -85,30 +85,30 @@ typedef struct player_state {
|
|||
u16 bowser_suit : 1;
|
||||
u16 team_backup : 1;
|
||||
};
|
||||
/* 0x0A */ s8 roll;
|
||||
/* 0x0C */ s16 space_curr;
|
||||
/* 0x0E */ s16 space_prev;
|
||||
/* 0x10 */ s16 space_next;
|
||||
/* 0x12 */ s16 space_shock;
|
||||
/* 0x14 */ s8 blue_count;
|
||||
/* 0x15 */ s8 red_count;
|
||||
/* 0x16 */ s8 question_count;
|
||||
/* 0x17 */ s8 fortune_count;
|
||||
/* 0x18 */ s8 bowser_count;
|
||||
/* 0x19 */ s8 battle_count;
|
||||
/* 0x1A */ s8 mushroom_count;
|
||||
/* 0x1B */ s8 warp_count;
|
||||
/* 0x1C */ s16 coins;
|
||||
/* 0x1E */ s16 coins_mg;
|
||||
/* 0x20 */ s16 coins_total;
|
||||
/* 0x22 */ s16 coins_max;
|
||||
/* 0x24 */ s16 coins_battle;
|
||||
/* 0x26 */ s16 coin_collect;
|
||||
/* 0x28 */ s16 coin_win;
|
||||
/* 0x2A */ s16 stars;
|
||||
/* 0x2C */ s16 stars_max;
|
||||
/* 0x2E */ char unk_2E[2];
|
||||
} PlayerState; //size of 0x30
|
||||
/* 0x0A */ s8 roll;
|
||||
/* 0x0C */ s16 space_curr;
|
||||
/* 0x0E */ s16 space_prev;
|
||||
/* 0x10 */ s16 space_next;
|
||||
/* 0x12 */ s16 space_shock;
|
||||
/* 0x14 */ s8 blue_count;
|
||||
/* 0x15 */ s8 red_count;
|
||||
/* 0x16 */ s8 question_count;
|
||||
/* 0x17 */ s8 fortune_count;
|
||||
/* 0x18 */ s8 bowser_count;
|
||||
/* 0x19 */ s8 battle_count;
|
||||
/* 0x1A */ s8 mushroom_count;
|
||||
/* 0x1B */ s8 warp_count;
|
||||
/* 0x1C */ s16 coins;
|
||||
/* 0x1E */ s16 coins_mg;
|
||||
/* 0x20 */ s16 coins_total;
|
||||
/* 0x22 */ s16 coins_max;
|
||||
/* 0x24 */ s16 coins_battle;
|
||||
/* 0x26 */ s16 coin_collect;
|
||||
/* 0x28 */ s16 coin_win;
|
||||
/* 0x2A */ s16 stars;
|
||||
/* 0x2C */ s16 stars_max;
|
||||
/* 0x2E */ char unk_2E[2];
|
||||
} PlayerState; // size of 0x30
|
||||
|
||||
typedef struct pause_backup_config {
|
||||
u8 explain_mg : 1;
|
||||
|
|
@ -119,21 +119,21 @@ typedef struct pause_backup_config {
|
|||
} PauseBackupConfig;
|
||||
|
||||
typedef struct game_stat {
|
||||
/* 0x0 */ s16 unk_00;
|
||||
/* 0x2 */ u8 language;
|
||||
/* 0x3 */ u8 sound_mode;
|
||||
/* 0x4 */ s8 rumble;
|
||||
/* 0x6 */ u16 total_stars;
|
||||
/* 0x8 */ OSTime create_time;
|
||||
/* 0x10 */ u32 mg_custom[2];
|
||||
/* 0x18 */ u32 mg_avail[2];
|
||||
/* 0x20 */ u32 mg_record[15];
|
||||
/* 0x5C */ u8 board_win_count[9][8];
|
||||
/* 0xA4 */ u8 board_play_count[9];
|
||||
/* 0xAE */ u16 board_max_stars[9];
|
||||
/* 0xC0 */ u16 board_max_coins[9];
|
||||
/* 0xD2 */ u8 present[60];
|
||||
/* 0x10E */ struct {
|
||||
/* 0x0 */ s16 unk_00;
|
||||
/* 0x2 */ u8 language;
|
||||
/* 0x3 */ u8 sound_mode;
|
||||
/* 0x4 */ s8 rumble;
|
||||
/* 0x6 */ u16 total_stars;
|
||||
/* 0x8 */ OSTime create_time;
|
||||
/* 0x10 */ u32 mg_custom[2];
|
||||
/* 0x18 */ u32 mg_avail[2];
|
||||
/* 0x20 */ u32 mg_record[15];
|
||||
/* 0x5C */ u8 board_win_count[9][8];
|
||||
/* 0xA4 */ u8 board_play_count[9];
|
||||
/* 0xAE */ u16 board_max_stars[9];
|
||||
/* 0xC0 */ u16 board_max_coins[9];
|
||||
/* 0xD2 */ u8 present[60];
|
||||
/* 0x10E */ struct {
|
||||
u8 story_continue : 1;
|
||||
u8 party_continue : 1;
|
||||
u8 open_w06 : 1;
|
||||
|
|
@ -141,17 +141,17 @@ typedef struct game_stat {
|
|||
u8 customPackEnable : 1;
|
||||
u8 musicAllF : 1;
|
||||
};
|
||||
/* 0x10F */ PauseBackupConfig story_pause;
|
||||
/* 0x110 */ PauseBackupConfig party_pause;
|
||||
/* 0x10F */ PauseBackupConfig story_pause;
|
||||
/* 0x110 */ PauseBackupConfig party_pause;
|
||||
} GameStat;
|
||||
|
||||
extern s16 GwLanguage;
|
||||
extern s16 GwLanguageSave;
|
||||
SHARED_SYM extern s16 GwLanguage;
|
||||
SHARED_SYM extern s16 GwLanguageSave;
|
||||
|
||||
extern PlayerConfig GWPlayerCfg[4];
|
||||
extern PlayerState GWPlayer[4];
|
||||
extern SystemState GWSystem;
|
||||
extern GameStat GWGameStat;
|
||||
SHARED_SYM extern PlayerConfig GWPlayerCfg[4];
|
||||
SHARED_SYM extern PlayerState GWPlayer[4];
|
||||
SHARED_SYM extern SystemState GWSystem;
|
||||
SHARED_SYM extern GameStat GWGameStat;
|
||||
|
||||
static inline s32 GWPlayerCfgGroupGet(s32 player)
|
||||
{
|
||||
|
|
@ -196,7 +196,7 @@ static inline s32 GWRumbleGet(void)
|
|||
static inline void GWRumbleSet(s32 value)
|
||||
{
|
||||
GWGameStat.rumble = value;
|
||||
if(value == 0) {
|
||||
if (value == 0) {
|
||||
HuPadRumbleAllStop();
|
||||
}
|
||||
}
|
||||
|
|
@ -206,7 +206,6 @@ static inline s32 GWBonusStarGet(void)
|
|||
return GWSystem.bonus_star;
|
||||
}
|
||||
|
||||
|
||||
static inline s32 GWMGExplainGet(void)
|
||||
{
|
||||
return GWSystem.explain_mg;
|
||||
|
|
@ -250,9 +249,9 @@ static inline s32 GWMessSpeedGet(void)
|
|||
|
||||
static inline void GWMessSpeedSet(s32 value)
|
||||
{
|
||||
#if VERSION_NTSC
|
||||
#if VERSION_NTSC
|
||||
GWSystem.mess_speed = value;
|
||||
switch(value) {
|
||||
switch (value) {
|
||||
case 0:
|
||||
GWSystem.mess_delay = 16;
|
||||
break;
|
||||
|
|
@ -265,9 +264,9 @@ static inline void GWMessSpeedSet(s32 value)
|
|||
GWSystem.mess_delay = 32;
|
||||
break;
|
||||
}
|
||||
#else
|
||||
#else
|
||||
GWSystem.mess_speed = value;
|
||||
switch(value) {
|
||||
switch (value) {
|
||||
case 0:
|
||||
GWSystem.mess_delay = 32;
|
||||
break;
|
||||
|
|
@ -275,7 +274,7 @@ static inline void GWMessSpeedSet(s32 value)
|
|||
case 2:
|
||||
GWSystem.mess_delay = 64;
|
||||
break;
|
||||
|
||||
|
||||
case 1:
|
||||
GWSystem.mess_delay = 48;
|
||||
break;
|
||||
|
|
@ -284,7 +283,7 @@ static inline void GWMessSpeedSet(s32 value)
|
|||
GWSystem.mess_delay = 120;
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void GWSaveModeSet(s32 value)
|
||||
|
|
@ -367,7 +366,7 @@ static inline void GWPlayerCoinWinSet(s32 player, s16 value)
|
|||
}
|
||||
}
|
||||
|
||||
#define GWPlayerCoinWinAdd(player, value) GWPlayerCoinWinSet((player), GWPlayerCoinWinGet((player))+(value))
|
||||
#define GWPlayerCoinCollectAdd(player, value) GWPlayerCoinCollectSet((player), (s32)GWPlayerCoinCollectGet((player))+(value))
|
||||
#define GWPlayerCoinWinAdd(player, value) GWPlayerCoinWinSet((player), GWPlayerCoinWinGet((player)) + (value))
|
||||
#define GWPlayerCoinCollectAdd(player, value) GWPlayerCoinCollectSet((player), (s32)GWPlayerCoinCollectGet((player)) + (value))
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -4,10 +4,15 @@
|
|||
#include "game/hsfformat.h"
|
||||
#include "game/hsfman.h"
|
||||
#include "game/animdata.h"
|
||||
#include "version.h"
|
||||
|
||||
typedef struct model_data ModelData;
|
||||
typedef struct particle_data ParticleData;
|
||||
|
||||
#ifdef TARGET_PC
|
||||
typedef void (*ParticleDLCallFunc)(ParticleData *particle);
|
||||
#endif
|
||||
|
||||
typedef void (*ParticleHook)(ModelData *model, ParticleData *particle, Mtx matrix);
|
||||
|
||||
typedef struct {
|
||||
|
|
@ -44,11 +49,11 @@ struct particle_data {
|
|||
/* 0x34 */ u32 unk_34;
|
||||
/* 0x38 */ s32 unk_38;
|
||||
/* 0x3C */ u32 unk_3C;
|
||||
/* 0x40 */ s32 unk_40;
|
||||
/* 0x40 */ s32 unk_40; // dlSize
|
||||
/* 0x44 */ AnimData *unk_44;
|
||||
/* 0x48 */ HsfanimStruct01 *unk_48;
|
||||
/* 0x4C */ Vec *unk_4C;
|
||||
/* 0x50 */ void *unk_50;
|
||||
/* 0x50 */ void *unk_50; // dlPtr
|
||||
/* 0x54 */ ParticleHook unk_54;
|
||||
}; // Size 0x58
|
||||
|
||||
|
|
@ -138,7 +143,7 @@ void Hu3DParManTimeLimitSet(s16 arg0, s32 arg1);
|
|||
void Hu3DParManVacumeSet(s16 arg0, float arg1, float arg2, float arg3, float arg4);
|
||||
void Hu3DParManColorSet(s16 arg0, s16 arg1);
|
||||
|
||||
extern Hu3DTexAnimDataStruct Hu3DTexAnimData[256];
|
||||
extern Hu3DTexScrDataStruct Hu3DTexScrData[16];
|
||||
SHARED_SYM extern Hu3DTexAnimDataStruct Hu3DTexAnimData[256];
|
||||
SHARED_SYM extern Hu3DTexScrDataStruct Hu3DTexScrData[16];
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ typedef struct hsfdraw_struct_01 {
|
|||
/* 0x1C */ float unk1C;
|
||||
/* 0x20 */ float unk20;
|
||||
/* 0x24 */ float unk24;
|
||||
/* 0x28 */ float unk28;
|
||||
/* 0x28 */ float unk28;
|
||||
/* 0x2C */ float unk2C;
|
||||
/* 0x30 */ float unk30;
|
||||
/* 0x34 */ float unk34;
|
||||
|
|
@ -56,9 +56,8 @@ typedef struct hsf_draw_object {
|
|||
void Hu3DDrawPreInit(void);
|
||||
void Hu3DDraw(ModelData *arg0, Mtx arg1, Vec *arg2);
|
||||
s32 ObjCullCheck(HsfData *arg0, HsfObject *arg1, Mtx arg2);
|
||||
void FaceDraw(HsfDrawObject *arg0, HsfFace *arg1);
|
||||
void Hu3DDrawPost(void);
|
||||
void MakeDisplayList(s16 arg0, u32 arg1);
|
||||
void MakeDisplayList(s16 arg0, uintptr_t arg1);
|
||||
HsfConstData *ObjConstantMake(HsfObject *arg0, u32 arg1);
|
||||
void mtxTransCat(Mtx arg0, float arg1, float arg2, float arg3);
|
||||
void mtxRotCat(Mtx arg0, float arg1, float arg2, float arg3);
|
||||
|
|
@ -71,7 +70,7 @@ void Hu3DModelObjMtxGet(s16 arg0, char *arg1, Mtx arg2);
|
|||
void PGObjCall(ModelData *arg0, HsfObject *arg1);
|
||||
void PGObjCalc(ModelData *arg0, HsfObject *arg1);
|
||||
void PGObjReplica(ModelData *arg0, HsfObject *arg1);
|
||||
HsfObject *Hu3DObjDuplicate(HsfData *arg0, u32 arg1);
|
||||
HsfObject *Hu3DObjDuplicate(HsfData *arg0, uintptr_t arg1);
|
||||
void Hu3DModelObjDrawInit(void);
|
||||
void Hu3DModelObjDraw(s16 arg0, char *arg1, Mtx arg2);
|
||||
|
||||
|
|
|
|||
|
|
@ -227,9 +227,8 @@ typedef struct hsf_cluster {
|
|||
s32 target;
|
||||
};
|
||||
HsfPart *part;
|
||||
float unk10;
|
||||
float unk14[1]; // unknown array size
|
||||
u8 unk18[124];
|
||||
float index;
|
||||
float weight[32]; // unknown array size
|
||||
u8 adjusted;
|
||||
u8 unk95;
|
||||
u16 type;
|
||||
|
|
@ -261,7 +260,7 @@ typedef struct hsf_object_data {
|
|||
} mesh;
|
||||
struct hsf_object *replica;
|
||||
};
|
||||
|
||||
|
||||
HsfBuffer *face;
|
||||
HsfBuffer *vertex;
|
||||
HsfBuffer *normal;
|
||||
|
|
@ -278,7 +277,8 @@ typedef struct hsf_object_data {
|
|||
HsfCluster **cluster;
|
||||
u32 cenvCnt;
|
||||
HsfCenv *cenv;
|
||||
void *file[2];
|
||||
HsfVector3f *vtxtop;
|
||||
HsfVector3f *normtop;
|
||||
} HsfObjectData;
|
||||
|
||||
typedef struct hsf_camera {
|
||||
|
|
@ -286,8 +286,8 @@ typedef struct hsf_camera {
|
|||
HsfVector3f pos;
|
||||
float aspect_dupe;
|
||||
float fov;
|
||||
float near;
|
||||
float far;
|
||||
float nnear;
|
||||
float ffar;
|
||||
} HsfCamera;
|
||||
|
||||
typedef struct hsf_light {
|
||||
|
|
@ -351,6 +351,9 @@ typedef struct hsf_track {
|
|||
float value;
|
||||
void *data;
|
||||
};
|
||||
#ifdef TARGET_PC
|
||||
void *dataTop;
|
||||
#endif
|
||||
} HsfTrack;
|
||||
|
||||
typedef struct hsf_motion {
|
||||
|
|
@ -397,6 +400,9 @@ typedef struct hsf_data {
|
|||
HsfObject *object;
|
||||
HsfMapAttr *mapAttr;
|
||||
HsfMatrix *matrix;
|
||||
#ifdef TARGET_PC
|
||||
void **symbol;
|
||||
#endif
|
||||
s16 sceneCnt;
|
||||
s16 attributeCnt;
|
||||
s16 materialCnt;
|
||||
|
|
|
|||
|
|
@ -8,5 +8,8 @@ void ClusterAdjustObject(HsfData *model, HsfData *src_model);
|
|||
char *SetName(u32 *str_ofs);
|
||||
char *MakeObjectName(char *name);
|
||||
s32 CmpObjectName(char *name1, char *name2);
|
||||
#ifdef TARGET_PC
|
||||
void KillHSF(HsfData *data);
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
@ -5,6 +5,7 @@
|
|||
#include "game/hsfanim.h"
|
||||
#include "game/hsfformat.h"
|
||||
#include "game/memory.h"
|
||||
#include "version.h"
|
||||
|
||||
#define HU3D_MODEL_MAX 512
|
||||
#define HU3D_MOTION_MAX 256
|
||||
|
|
@ -104,7 +105,7 @@ struct model_data {
|
|||
u16 unk_26;
|
||||
u16 unk_28[8];
|
||||
s16 unk_38[8];
|
||||
u32 unk_48;
|
||||
uintptr_t unk_48;
|
||||
u32 unk_4C;
|
||||
u32 attr;
|
||||
u32 motion_attr;
|
||||
|
|
@ -140,8 +141,8 @@ struct model_data {
|
|||
}; // sizeof 0x124
|
||||
typedef struct camera_data {
|
||||
float fov;
|
||||
float near;
|
||||
float far;
|
||||
float nnear;
|
||||
float ffar;
|
||||
float aspect;
|
||||
float aspect_dupe;
|
||||
Vec pos;
|
||||
|
|
@ -283,6 +284,9 @@ void Hu3DLLightStaticSet(s16, s16, s32);
|
|||
s32 Hu3DModelLightInfoSet(s16, s16);
|
||||
s16 Hu3DLightSet(ModelData *, Mtx *, Mtx *, float);
|
||||
void lightSet(LightData *arg0, s16 arg1, Mtx *arg2, Mtx *arg3, float arg8);
|
||||
#ifndef __MWERKS__
|
||||
void Hu3DReflectMapSet(AnimData* arg0);
|
||||
#endif
|
||||
void Hu3DReflectNoSet(s16 arg0);
|
||||
void Hu3DFogSet(float, float, u8, u8, u8);
|
||||
void Hu3DFogClear(void);
|
||||
|
|
@ -297,23 +301,23 @@ void Hu3DProjectionPosSet(s16, Vec *, Vec *, Vec *);
|
|||
void Hu3DProjectionTPLvlSet(s16, float);
|
||||
void Hu3DMipMapSet(char *, s16, s32, float);
|
||||
|
||||
extern ModelData Hu3DData[0x200];
|
||||
extern CameraData Hu3DCamera[0x10];
|
||||
SHARED_SYM extern ModelData Hu3DData[0x200];
|
||||
SHARED_SYM extern CameraData Hu3DCamera[0x10];
|
||||
extern AnimData *reflectAnim[5];
|
||||
extern AnimData *hiliteAnim[4];
|
||||
SHARED_SYM extern AnimData *hiliteAnim[4];
|
||||
extern ThreeDProjectionStruct Hu3DProjection[4];
|
||||
extern ShadowData Hu3DShadowData;
|
||||
extern Mtx Hu3DCameraMtx;
|
||||
extern Mtx Hu3DCameraMtxXPose;
|
||||
extern LightData Hu3DGlobalLight[0x8];
|
||||
SHARED_SYM extern ShadowData Hu3DShadowData;
|
||||
SHARED_SYM extern Mtx Hu3DCameraMtx;
|
||||
SHARED_SYM extern Mtx Hu3DCameraMtxXPose;
|
||||
SHARED_SYM extern LightData Hu3DGlobalLight[0x8];
|
||||
extern s16 reflectMapNo;
|
||||
extern AnimData *toonAnim;
|
||||
extern s16 Hu3DShadowCamBit;
|
||||
extern s32 Hu3DShadowF;
|
||||
extern s32 shadowModelDrawF;
|
||||
extern s16 Hu3DCameraNo;
|
||||
SHARED_SYM extern s16 Hu3DShadowCamBit;
|
||||
SHARED_SYM extern s32 Hu3DShadowF;
|
||||
SHARED_SYM extern s32 shadowModelDrawF;
|
||||
SHARED_SYM extern s16 Hu3DCameraNo;
|
||||
extern s16 Hu3DCameraBit;
|
||||
extern s16 Hu3DPauseF;
|
||||
extern GXColor BGColor;
|
||||
SHARED_SYM extern GXColor BGColor;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
|
||||
#include "dolphin.h"
|
||||
#include "game/hsfformat.h"
|
||||
#include "version.h"
|
||||
|
||||
#define Hu3DMotionCreateFile(data_id) (Hu3DMotionCreate(HuDataSelHeapReadNum((data_id), MEMORY_DEFAULT_NUM, HEAP_DATA)))
|
||||
|
||||
|
|
@ -10,9 +11,9 @@
|
|||
|
||||
|
||||
typedef struct motion_data {
|
||||
s16 unk_00;
|
||||
s16 unk_02;
|
||||
HsfData *unk_04;
|
||||
s16 attr;
|
||||
s16 modelId;
|
||||
HsfData *hsfData;
|
||||
} MotionData;
|
||||
|
||||
typedef struct {
|
||||
|
|
@ -76,6 +77,6 @@ s16 Hu3DJointMotion(s16 arg0, void *arg1);
|
|||
void JointModel_Motion(s16 arg0, s16 arg1);
|
||||
void Hu3DMotionCalc(s16 arg0);
|
||||
|
||||
extern MotionData Hu3DMotion[256];
|
||||
SHARED_SYM extern MotionData Hu3DMotion[256];
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -2,8 +2,9 @@
|
|||
#define _GAME_INIT_H
|
||||
|
||||
#include "dolphin.h"
|
||||
#include "version.h"
|
||||
|
||||
extern GXRenderModeObj *RenderMode;
|
||||
SHARED_SYM extern GXRenderModeObj *RenderMode;
|
||||
extern OSHeapHandle currentHeapHandle;
|
||||
|
||||
extern void *DemoFrameBuffer1;
|
||||
|
|
@ -11,7 +12,7 @@ extern void *DemoFrameBuffer2;
|
|||
extern void *DemoCurrentBuffer;
|
||||
extern u32 minimumVcount;
|
||||
extern float minimumVcountf;
|
||||
extern u32 worstVcount;
|
||||
SHARED_SYM extern u32 worstVcount;
|
||||
|
||||
void HuSysInit(GXRenderModeObj *mode);
|
||||
void HuSysBeforeRender();
|
||||
|
|
|
|||
|
|
@ -16,4 +16,4 @@ typedef struct jump_buf {
|
|||
s32 gcsetjmp(jmp_buf *jump);
|
||||
s32 gclongjmp(jmp_buf *jump, s32 status);
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
@ -16,11 +16,11 @@ void CharRotInv(Mtx arg0, Mtx arg1, Vec *arg2, omObjData *arg3);
|
|||
|
||||
extern Mtx MapMT;
|
||||
extern Mtx MapMTR;
|
||||
extern float AddX;
|
||||
extern float AddZ;
|
||||
extern s32 nMap;
|
||||
extern s32 nChar;
|
||||
SHARED_SYM extern float AddX;
|
||||
SHARED_SYM extern float AddZ;
|
||||
SHARED_SYM extern s32 nMap;
|
||||
SHARED_SYM extern s32 nChar;
|
||||
extern s32 HitFaceCount;
|
||||
extern omObjData *MapObject[16];
|
||||
SHARED_SYM extern omObjData *MapObject[16];
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -19,23 +19,23 @@ void *HuMemInit(void *ptr, s32 size);
|
|||
void HuMemDCFlushAll();
|
||||
void HuMemDCFlush(HeapID heap);
|
||||
void *HuMemDirectMalloc(HeapID heap, s32 size);
|
||||
void *HuMemDirectMallocNum(HeapID heap, s32 size, u32 num);
|
||||
void *HuMemDirectMallocNum(HeapID heap, s32 size, uintptr_t num);
|
||||
void HuMemDirectFree(void *ptr);
|
||||
void HuMemDirectFreeNum(HeapID heap, u32 num);
|
||||
void HuMemDirectFreeNum(HeapID heap, uintptr_t num);
|
||||
s32 HuMemUsedMallocSizeGet(HeapID heap);
|
||||
s32 HuMemUsedMallocBlockGet(HeapID heap);
|
||||
u32 HuMemHeapSizeGet(HeapID heap);
|
||||
void *HuMemHeapPtrGet(HeapID heap);
|
||||
|
||||
void *HuMemHeapInit(void *ptr, s32 size);
|
||||
void *HuMemMemoryAlloc(void *heap_ptr, s32 size, u32 retaddr);
|
||||
void *HuMemMemoryAllocNum(void *heap_ptr, s32 size, u32 num, u32 retaddr);
|
||||
void HuMemMemoryFree(void *ptr, u32 retaddr);
|
||||
void HuMemMemoryFreeNum(void *heap_ptr, u32 num, u32 retaddr);
|
||||
void *HuMemMemoryAlloc(void *heap_ptr, s32 size, uintptr_t retaddr);
|
||||
void *HuMemMemoryAllocNum(void *heap_ptr, s32 size, uintptr_t num, uintptr_t retaddr);
|
||||
void HuMemMemoryFree(void *ptr, uintptr_t retaddr);
|
||||
void HuMemMemoryFreeNum(void *heap_ptr, uintptr_t num, uintptr_t retaddr);
|
||||
s32 HuMemUsedMemorySizeGet(void *heap_ptr);
|
||||
s32 HuMemUsedMemoryBlockGet(void *heap_ptr);
|
||||
s32 HuMemMemorySizeGet(void *ptr);
|
||||
s32 HuMemMemoryAllocSizeGet(s32 size);
|
||||
void HuMemHeapDump(void *heap_ptr, s16 status);
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -117,6 +117,6 @@ s32 MGSeqUpdateRecord(SeqWork *work);
|
|||
s32 MGSeqInitFlip(SeqWork *work, va_list params);
|
||||
s32 MGSeqUpdateFlip(SeqWork *work);
|
||||
|
||||
extern OverlayID mgSeqOvlPrev;
|
||||
SHARED_SYM extern OverlayID mgSeqOvlPrev;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -165,6 +165,7 @@ s32 msmSysDelGroupAll(void);
|
|||
s32 msmSysGetSampSize(BOOL baseGrp);
|
||||
s32 msmSysDelGroupBase(s32 grpNum);
|
||||
s32 msmSysSetAux(s32 auxA, s32 auxB);
|
||||
void msmSysRegularProc(void);
|
||||
|
||||
s32 msmSeSetParam(int seNo, MSM_SEPARAM *param);
|
||||
int msmSePlay(int seId, MSM_SEPARAM *param);
|
||||
|
|
@ -185,6 +186,7 @@ int msmMusPlay(int musId, MSM_MUSPARAM *musParam);
|
|||
s32 msmMusStop(int musNo, s32 speed);
|
||||
void msmMusPauseAll(BOOL pause, s32 speed);
|
||||
s32 msmMusPause(int musNo, BOOL pause, s32 speed);
|
||||
void msmMusFdoutEnd(void);
|
||||
s32 msmMusGetMidiCtrl(int musNo, s32 channel, s32 ctrl);
|
||||
void msmMusStopAll(BOOL checkGrp, s32 speed);
|
||||
s32 msmMusGetStatus(int musNo);
|
||||
|
|
|
|||
|
|
@ -5,6 +5,10 @@
|
|||
#include "game/process.h"
|
||||
#include "game/dvd.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <windows.h>
|
||||
#endif
|
||||
|
||||
#define OM_DLL_MAX 20
|
||||
|
||||
#define OVL_DEFINE(name, path) name,
|
||||
|
|
@ -60,9 +64,14 @@ typedef struct om_obj_data {
|
|||
|
||||
typedef struct om_dll_data {
|
||||
char *name;
|
||||
#if _WIN32
|
||||
HMODULE hModule;
|
||||
#else
|
||||
OSModuleHeader *module;
|
||||
void *bss;
|
||||
s32 ret;
|
||||
#endif
|
||||
|
||||
} omDllData;
|
||||
|
||||
void omMasterInit(s32 prio, FileListEntry *ovl_list, s32 ovl_count, OverlayID start_ovl);
|
||||
|
|
@ -112,26 +121,26 @@ void omSysPauseCtrl(s16 flag);
|
|||
extern omObjData *omDBGSysKeyObj;
|
||||
extern Process *omwatchproc;
|
||||
extern OverlayID omnextovl;
|
||||
extern OverlayID omcurovl;
|
||||
SHARED_SYM extern OverlayID omcurovl;
|
||||
extern s32 omcurdll;
|
||||
extern s32 omovlhisidx;
|
||||
extern s32 omovlevtno;
|
||||
SHARED_SYM extern s32 omovlhisidx;
|
||||
SHARED_SYM extern s32 omovlevtno;
|
||||
extern s32 omnextovlevtno;
|
||||
extern u32 omovlstat;
|
||||
SHARED_SYM extern u32 omovlstat;
|
||||
extern char omUPauseFlag;
|
||||
extern s16 omSysExitReq;
|
||||
SHARED_SYM extern s16 omSysExitReq;
|
||||
extern s16 omdispinfo;
|
||||
extern u8 omSysPauseEnableFlag;
|
||||
extern OverlayID omprevovl;
|
||||
|
||||
extern omDllData *omDLLinfoTbl[OM_DLL_MAX];
|
||||
|
||||
extern Vec CRot;
|
||||
extern Vec Center;
|
||||
extern float CZoom;
|
||||
extern Vec CRotM[16];
|
||||
extern Vec CenterM[16];
|
||||
extern float CZoomM[16];
|
||||
extern s16 omDBGMenuButton;
|
||||
SHARED_SYM extern Vec CRot;
|
||||
SHARED_SYM extern Vec Center;
|
||||
SHARED_SYM extern float CZoom;
|
||||
SHARED_SYM extern Vec CRotM[16];
|
||||
SHARED_SYM extern Vec CenterM[16];
|
||||
SHARED_SYM extern float CZoomM[16];
|
||||
SHARED_SYM extern s16 omDBGMenuButton;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
#include "dolphin.h"
|
||||
#include "game/process.h"
|
||||
#include "game/gamework_data.h"
|
||||
#include "version.h"
|
||||
|
||||
typedef struct mg_info {
|
||||
u16 ovl;
|
||||
|
|
@ -22,20 +23,20 @@ void omGameSysInit(Process *objman);
|
|||
void omVibrate(s16 player_cfg_index, s16 duration, s16 off, s16 on);
|
||||
|
||||
|
||||
extern s16 mgTypeCurr;
|
||||
extern s16 mgBattleStar[4];
|
||||
extern s16 mgBattleStarMax;
|
||||
extern u8 lbl_801D3E94;
|
||||
extern u32 mgRecordExtra;
|
||||
extern s32 mgQuitExtraF;
|
||||
extern s32 mgPracticeEnableF;
|
||||
extern s32 mgInstExitEnableF;
|
||||
extern u8 mgBoardHostEnableF;
|
||||
SHARED_SYM extern s16 mgTypeCurr;
|
||||
SHARED_SYM extern s16 mgBattleStar[4];
|
||||
SHARED_SYM extern s16 mgBattleStarMax;
|
||||
SHARED_SYM extern u8 lbl_801D3E94;
|
||||
SHARED_SYM extern u32 mgRecordExtra;
|
||||
SHARED_SYM extern s32 mgQuitExtraF;
|
||||
SHARED_SYM extern s32 mgPracticeEnableF;
|
||||
SHARED_SYM extern s32 mgInstExitEnableF;
|
||||
SHARED_SYM extern u8 mgBoardHostEnableF;
|
||||
|
||||
extern s16 mgTicTacToeGrid[3][3];
|
||||
extern u8 mgIndexList[256];
|
||||
extern GameStat mgGameStatBackup;
|
||||
SHARED_SYM extern s16 mgTicTacToeGrid[3][3];
|
||||
SHARED_SYM extern u8 mgIndexList[256];
|
||||
SHARED_SYM extern GameStat mgGameStatBackup;
|
||||
|
||||
extern MgInfo mgInfoTbl[];
|
||||
SHARED_SYM extern MgInfo mgInfoTbl[];
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -2,23 +2,24 @@
|
|||
#define _GAME_PAD_H
|
||||
|
||||
#include "dolphin.h"
|
||||
#include "version.h"
|
||||
|
||||
#define PAD_BUTTON_DIR (PAD_BUTTON_LEFT | PAD_BUTTON_RIGHT | PAD_BUTTON_UP | PAD_BUTTON_DOWN)
|
||||
|
||||
#define PAD_BUTTON_TRIGGER_L 0x4000
|
||||
#define PAD_BUTTON_TRIGGER_R 0x2000
|
||||
|
||||
extern u16 HuPadBtn[4];
|
||||
extern u16 HuPadBtnDown[4];
|
||||
extern u16 HuPadBtnRep[4];
|
||||
extern s8 HuPadStkX[4];
|
||||
extern s8 HuPadStkY[4];
|
||||
extern s8 HuPadSubStkX[4];
|
||||
extern s8 HuPadSubStkY[4];
|
||||
extern u8 HuPadTrigL[4];
|
||||
extern u8 HuPadTrigR[4];
|
||||
extern u8 HuPadDStk[4];
|
||||
extern u8 HuPadDStkRep[4];
|
||||
SHARED_SYM extern u16 HuPadBtn[4];
|
||||
SHARED_SYM extern u16 HuPadBtnDown[4];
|
||||
SHARED_SYM extern u16 HuPadBtnRep[4];
|
||||
SHARED_SYM extern s8 HuPadStkX[4];
|
||||
SHARED_SYM extern s8 HuPadStkY[4];
|
||||
SHARED_SYM extern s8 HuPadSubStkX[4];
|
||||
SHARED_SYM extern s8 HuPadSubStkY[4];
|
||||
SHARED_SYM extern u8 HuPadTrigL[4];
|
||||
SHARED_SYM extern u8 HuPadTrigR[4];
|
||||
SHARED_SYM extern u8 HuPadDStk[4];
|
||||
SHARED_SYM extern u8 HuPadDStkRep[4];
|
||||
extern s8 HuPadErr[4];
|
||||
extern u16 _PadBtn[4];
|
||||
extern u16 _PadBtnDown[4];
|
||||
|
|
@ -32,4 +33,4 @@ void HuPadRumbleAllStop(void);
|
|||
s16 HuPadStatGet(s16 pad);
|
||||
u32 HuPadRumbleGet(void);
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
#define _GAME_PRINTFUNC_H
|
||||
|
||||
#include "dolphin.h"
|
||||
#include "version.h"
|
||||
|
||||
#define FONT_COLOR_BLACK 0
|
||||
#define FONT_COLOR_DARK_BLUE 1
|
||||
|
|
@ -29,7 +30,7 @@ void pfDrawFonts(void);
|
|||
extern BOOL saftyFrameF;
|
||||
extern u16 strlinecnt;
|
||||
extern u16 empstrline;
|
||||
extern int fontcolor;
|
||||
SHARED_SYM extern int fontcolor;
|
||||
extern u32 procfunc;
|
||||
|
||||
#endif
|
||||
|
|
@ -1,9 +1,15 @@
|
|||
#ifndef _GAME_PROCESS_H
|
||||
#define _GAME_PROCESS_H
|
||||
|
||||
#include "game/jmp.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
#ifdef TARGET_PC
|
||||
#include <stdio.h>
|
||||
#include "libco.h"
|
||||
#else
|
||||
#include "game/jmp.h"
|
||||
#endif
|
||||
|
||||
#define PROCESS_STAT_PAUSE 0x1
|
||||
#define PROCESS_STAT_UPAUSE 0x2
|
||||
#define PROCESS_STAT_PAUSE_EN 0x4
|
||||
|
|
@ -21,8 +27,12 @@ typedef struct process {
|
|||
u16 stat;
|
||||
u16 prio;
|
||||
s32 sleep_time;
|
||||
u32 base_sp;
|
||||
#ifdef TARGET_PC
|
||||
cothread_t thread;
|
||||
#else
|
||||
uintptr_t base_sp;
|
||||
jmp_buf jump;
|
||||
#endif
|
||||
void (*dtor)(void);
|
||||
void *user_data;
|
||||
} Process;
|
||||
|
|
@ -50,4 +60,4 @@ void HuPrcResetStat(Process *process, u16 value);
|
|||
void HuPrcAllPause(s32 flag);
|
||||
void HuPrcAllUPause(s32 flag);
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -24,13 +24,13 @@ typedef union save_buf_all {
|
|||
u8 ATTRIBUTE_ALIGN(32) buf[SAVE_BUF_SIZE];
|
||||
} SaveBufAll;
|
||||
|
||||
extern char *SaveFileNameTbl[];
|
||||
extern CARDFileInfo curFileInfo;
|
||||
extern SaveBufAll saveBuf;
|
||||
SHARED_SYM extern char *SaveFileNameTbl[];
|
||||
SHARED_SYM extern CARDFileInfo curFileInfo;
|
||||
SHARED_SYM extern SaveBufAll saveBuf;
|
||||
extern u64 SLSerialNo;
|
||||
extern s32 saveExecF;
|
||||
SHARED_SYM extern s32 saveExecF;
|
||||
extern u8 curBoxNo;
|
||||
extern s16 curSlotNo;
|
||||
SHARED_SYM extern s16 curSlotNo;
|
||||
|
||||
s32 SLFileOpen(char *fileName);
|
||||
s32 SLFileCreate(char *fileName, u32 size, void *addr);
|
||||
|
|
|
|||
|
|
@ -113,7 +113,7 @@ void HuSprGrpCenterSet(s16 group, float x, float y);
|
|||
void HuSprGrpZRotSet(s16 group, float z_rot);
|
||||
void HuSprGrpScaleSet(s16 group, float x, float y);
|
||||
void HuSprGrpTPLvlSet(s16 group, float tp_lvl);
|
||||
#ifndef HUSPR_USE_OLD_DEFS
|
||||
#if !defined(HUSPR_USE_OLD_DEFS) || !defined(__MWERKS__)
|
||||
void HuSprGrpDrawNoSet(s16 group, s32 draw_no);
|
||||
#endif
|
||||
void HuSprDrawNoSet(s16 group, s16 member, s32 draw_no);
|
||||
|
|
@ -127,7 +127,7 @@ void AnimDebug(AnimData *anim);
|
|||
|
||||
void HuSprDispInit(void);
|
||||
void HuSprDisp(HuSprite *sprite);
|
||||
#ifndef HUSPR_USE_OLD_DEFS
|
||||
#if !defined(HUSPR_USE_OLD_DEFS) || !defined(__MWERKS__)
|
||||
void HuSprTexLoad(AnimData *anim, s16 bmp, s16 slot, GXTexWrapMode wrap_s, GXTexWrapMode wrap_t, GXTexFilter filter);
|
||||
#endif
|
||||
void HuSprExecLayerSet(s16 draw_no, s16 layer);
|
||||
|
|
|
|||
9
include/game/sreset.h
Normal file
9
include/game/sreset.h
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
#ifndef _GAME_SRESET_H
|
||||
#define _GAME_SRESET_H
|
||||
|
||||
#include "dolphin.h"
|
||||
|
||||
s32 HuSoftResetButtonCheck(void);
|
||||
void HuDvdErrDispInit(GXRenderModeObj *rmode, void *xfb1, void *xfb2);
|
||||
|
||||
#endif
|
||||
|
|
@ -3,6 +3,7 @@
|
|||
|
||||
#include "game/animdata.h"
|
||||
#include "dolphin.h"
|
||||
#include "version.h"
|
||||
|
||||
#define MAKE_MESSID(bank, mess) (((bank) << 16)+(mess))
|
||||
#define MAKE_MESSID_PTR(ptr) ((u32)(ptr))
|
||||
|
|
@ -75,8 +76,8 @@ typedef struct {
|
|||
/* 0x160 */ u8 ATTRIBUTE_ALIGN(32) mess_pal[10][3];
|
||||
} WindowData; // Size 0x180
|
||||
|
||||
extern WindowData winData[32];
|
||||
extern void *messDataPtr;
|
||||
SHARED_SYM extern WindowData winData[32];
|
||||
SHARED_SYM extern void *messDataPtr;
|
||||
|
||||
void HuWindowInit(void);
|
||||
void HuWinInit(s32 mess_data_no);
|
||||
|
|
@ -139,6 +140,4 @@ void HuWinExCleanup(s16 window);
|
|||
void HuWinExAnimPopIn(s16 window, s16 portrait);
|
||||
void *MessData_MesPtrGet(void *data, u32 index);
|
||||
|
||||
extern void *messDataPtr;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
#define _GAME_WIPE_H
|
||||
|
||||
#include "dolphin.h"
|
||||
#include "version.h"
|
||||
|
||||
#define WIPE_TYPE_PREV -1
|
||||
#define WIPE_TYPE_NORMAL 0
|
||||
|
|
@ -37,7 +38,7 @@ void WipeCreate(s16 mode, s16 type, s16 duration);
|
|||
void WipeColorSet(u8 r, u8 g, u8 b);
|
||||
u8 WipeStatGet(void);
|
||||
|
||||
extern WipeState wipeData;
|
||||
SHARED_SYM extern WipeState wipeData;
|
||||
extern BOOL wipeFadeInF;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,108 +1,108 @@
|
|||
#include "version.h"
|
||||
|
||||
OVL_DEFINE(OVL__MINI, "dll/_minigameDLL.rel")
|
||||
OVL_DEFINE(OVL_BOOT, "dll/bootdll.rel")
|
||||
OVL_DEFINE(OVL_E3SETUP, "dll/e3setupDLL.rel")
|
||||
OVL_DEFINE(OVL_INST, "dll/instdll.rel")
|
||||
OVL_DEFINE(OVL_M300, "dll/m300dll.rel")
|
||||
OVL_DEFINE(OVL_M302, "dll/m302dll.rel")
|
||||
OVL_DEFINE(OVL_M303, "dll/m303dll.rel")
|
||||
OVL_DEFINE(OVL_M330, "dll/m330dll.rel")
|
||||
OVL_DEFINE(OVL_M333, "dll/m333dll.rel")
|
||||
OVL_DEFINE(OVL_M401, "dll/m401dll.rel")
|
||||
OVL_DEFINE(OVL_M402, "dll/m402dll.rel")
|
||||
OVL_DEFINE(OVL_M403, "dll/m403dll.rel")
|
||||
OVL_DEFINE(OVL_M404, "dll/m404dll.rel")
|
||||
OVL_DEFINE(OVL_M405, "dll/m405dll.rel")
|
||||
OVL_DEFINE(OVL_M406, "dll/m406dll.rel")
|
||||
OVL_DEFINE(OVL_M407, "dll/m407dll.rel")
|
||||
OVL_DEFINE(OVL_M408, "dll/m408dll.rel")
|
||||
OVL_DEFINE(OVL_M409, "dll/m409dll.rel")
|
||||
OVL_DEFINE(OVL_M410, "dll/m410dll.rel")
|
||||
OVL_DEFINE(OVL_M411, "dll/m411dll.rel")
|
||||
OVL_DEFINE(OVL_M412, "dll/m412dll.rel")
|
||||
OVL_DEFINE(OVL_M413, "dll/m413dll.rel")
|
||||
OVL_DEFINE(OVL_M414, "dll/m414dll.rel")
|
||||
OVL_DEFINE(OVL_M415, "dll/m415dll.rel")
|
||||
OVL_DEFINE(OVL_M416, "dll/m416dll.rel")
|
||||
OVL_DEFINE(OVL_M417, "dll/m417dll.rel")
|
||||
OVL_DEFINE(OVL_M418, "dll/m418dll.rel")
|
||||
OVL_DEFINE(OVL_M419, "dll/m419dll.rel")
|
||||
OVL_DEFINE(OVL_M420, "dll/m420dll.rel")
|
||||
OVL_DEFINE(OVL_M421, "dll/m421dll.rel")
|
||||
OVL_DEFINE(OVL_M422, "dll/m422dll.rel")
|
||||
OVL_DEFINE(OVL_M423, "dll/m423dll.rel")
|
||||
OVL_DEFINE(OVL_M424, "dll/m424dll.rel")
|
||||
OVL_DEFINE(OVL_M425, "dll/m425dll.rel")
|
||||
OVL_DEFINE(OVL_M426, "dll/m426dll.rel")
|
||||
OVL_DEFINE(OVL_M427, "dll/m427dll.rel")
|
||||
OVL_DEFINE(OVL_M428, "dll/m428dll.rel")
|
||||
OVL_DEFINE(OVL_M429, "dll/m429dll.rel")
|
||||
OVL_DEFINE(OVL_M430, "dll/m430dll.rel")
|
||||
OVL_DEFINE(OVL_M431, "dll/m431dll.rel")
|
||||
OVL_DEFINE(OVL_M432, "dll/m432dll.rel")
|
||||
OVL_DEFINE(OVL_M433, "dll/m433dll.rel")
|
||||
OVL_DEFINE(OVL_M434, "dll/m434dll.rel")
|
||||
OVL_DEFINE(OVL_M435, "dll/m435dll.rel")
|
||||
OVL_DEFINE(OVL_M436, "dll/m436dll.rel")
|
||||
OVL_DEFINE(OVL_M437, "dll/m437dll.rel")
|
||||
OVL_DEFINE(OVL_M438, "dll/m438dll.rel")
|
||||
OVL_DEFINE(OVL_M439, "dll/m439dll.rel")
|
||||
OVL_DEFINE(OVL_M440, "dll/m440dll.rel")
|
||||
OVL_DEFINE(OVL_M441, "dll/m441dll.rel")
|
||||
OVL_DEFINE(OVL_M442, "dll/m442dll.rel")
|
||||
OVL_DEFINE(OVL_M443, "dll/m443dll.rel")
|
||||
OVL_DEFINE(OVL_M444, "dll/m444dll.rel")
|
||||
OVL_DEFINE(OVL_M445, "dll/m445dll.rel")
|
||||
OVL_DEFINE(OVL_M446, "dll/m446dll.rel")
|
||||
OVL_DEFINE(OVL_M447, "dll/m447dll.rel")
|
||||
OVL_DEFINE(OVL_M448, "dll/m448dll.rel")
|
||||
OVL_DEFINE(OVL_M449, "dll/m449dll.rel")
|
||||
OVL_DEFINE(OVL_M450, "dll/m450dll.rel")
|
||||
OVL_DEFINE(OVL_M451, "dll/m451dll.rel")
|
||||
OVL_DEFINE(OVL_M453, "dll/m453dll.rel")
|
||||
OVL_DEFINE(OVL_M455, "dll/m455dll.rel")
|
||||
OVL_DEFINE(OVL_M456, "dll/m456dll.rel")
|
||||
OVL_DEFINE(OVL_M457, "dll/m457dll.rel")
|
||||
OVL_DEFINE(OVL_M458, "dll/m458dll.rel")
|
||||
OVL_DEFINE(OVL_M459, "dll/m459dll.rel")
|
||||
OVL_DEFINE(OVL_M460, "dll/m460dll.rel")
|
||||
OVL_DEFINE(OVL_M461, "dll/m461dll.rel")
|
||||
OVL_DEFINE(OVL_M462, "dll/m462dll.rel")
|
||||
OVL_DEFINE(OVL_M463, "dll/m463dll.rel")
|
||||
OVL_DEFINE(OVL_MENT, "dll/mentdll.rel")
|
||||
OVL_DEFINE(OVL__MINI, "_minigameDLL")
|
||||
OVL_DEFINE(OVL_BOOT, "bootdll")
|
||||
OVL_DEFINE(OVL_E3SETUP, "e3setupDLL")
|
||||
OVL_DEFINE(OVL_INST, "instdll")
|
||||
OVL_DEFINE(OVL_M300, "m300dll")
|
||||
OVL_DEFINE(OVL_M302, "m302dll")
|
||||
OVL_DEFINE(OVL_M303, "m303dll")
|
||||
OVL_DEFINE(OVL_M330, "m330dll")
|
||||
OVL_DEFINE(OVL_M333, "m333dll")
|
||||
OVL_DEFINE(OVL_M401, "m401dll")
|
||||
OVL_DEFINE(OVL_M402, "m402dll")
|
||||
OVL_DEFINE(OVL_M403, "m403dll")
|
||||
OVL_DEFINE(OVL_M404, "m404dll")
|
||||
OVL_DEFINE(OVL_M405, "m405dll")
|
||||
OVL_DEFINE(OVL_M406, "m406dll")
|
||||
OVL_DEFINE(OVL_M407, "m407dll")
|
||||
OVL_DEFINE(OVL_M408, "m408dll")
|
||||
OVL_DEFINE(OVL_M409, "m409dll")
|
||||
OVL_DEFINE(OVL_M410, "m410dll")
|
||||
OVL_DEFINE(OVL_M411, "m411dll")
|
||||
OVL_DEFINE(OVL_M412, "m412dll")
|
||||
OVL_DEFINE(OVL_M413, "m413dll")
|
||||
OVL_DEFINE(OVL_M414, "m414dll")
|
||||
OVL_DEFINE(OVL_M415, "m415dll")
|
||||
OVL_DEFINE(OVL_M416, "m416dll")
|
||||
OVL_DEFINE(OVL_M417, "m417dll")
|
||||
OVL_DEFINE(OVL_M418, "m418dll")
|
||||
OVL_DEFINE(OVL_M419, "m419dll")
|
||||
OVL_DEFINE(OVL_M420, "m420dll")
|
||||
OVL_DEFINE(OVL_M421, "m421dll")
|
||||
OVL_DEFINE(OVL_M422, "m422dll")
|
||||
OVL_DEFINE(OVL_M423, "m423dll")
|
||||
OVL_DEFINE(OVL_M424, "m424dll")
|
||||
OVL_DEFINE(OVL_M425, "m425dll")
|
||||
OVL_DEFINE(OVL_M426, "m426dll")
|
||||
OVL_DEFINE(OVL_M427, "m427dll")
|
||||
OVL_DEFINE(OVL_M428, "m428dll")
|
||||
OVL_DEFINE(OVL_M429, "m429dll")
|
||||
OVL_DEFINE(OVL_M430, "m430dll")
|
||||
OVL_DEFINE(OVL_M431, "m431dll")
|
||||
OVL_DEFINE(OVL_M432, "m432dll")
|
||||
OVL_DEFINE(OVL_M433, "m433dll")
|
||||
OVL_DEFINE(OVL_M434, "m434dll")
|
||||
OVL_DEFINE(OVL_M435, "m435dll")
|
||||
OVL_DEFINE(OVL_M436, "m436dll")
|
||||
OVL_DEFINE(OVL_M437, "m437dll")
|
||||
OVL_DEFINE(OVL_M438, "m438dll")
|
||||
OVL_DEFINE(OVL_M439, "m439dll")
|
||||
OVL_DEFINE(OVL_M440, "m440dll")
|
||||
OVL_DEFINE(OVL_M441, "m441dll")
|
||||
OVL_DEFINE(OVL_M442, "m442dll")
|
||||
OVL_DEFINE(OVL_M443, "m443dll")
|
||||
OVL_DEFINE(OVL_M444, "m444dll")
|
||||
OVL_DEFINE(OVL_M445, "m445dll")
|
||||
OVL_DEFINE(OVL_M446, "m446dll")
|
||||
OVL_DEFINE(OVL_M447, "m447dll")
|
||||
OVL_DEFINE(OVL_M448, "m448dll")
|
||||
OVL_DEFINE(OVL_M449, "m449dll")
|
||||
OVL_DEFINE(OVL_M450, "m450dll")
|
||||
OVL_DEFINE(OVL_M451, "m451dll")
|
||||
OVL_DEFINE(OVL_M453, "m453dll")
|
||||
OVL_DEFINE(OVL_M455, "m455dll")
|
||||
OVL_DEFINE(OVL_M456, "m456dll")
|
||||
OVL_DEFINE(OVL_M457, "m457dll")
|
||||
OVL_DEFINE(OVL_M458, "m458dll")
|
||||
OVL_DEFINE(OVL_M459, "m459dll")
|
||||
OVL_DEFINE(OVL_M460, "m460dll")
|
||||
OVL_DEFINE(OVL_M461, "m461dll")
|
||||
OVL_DEFINE(OVL_M462, "m462dll")
|
||||
OVL_DEFINE(OVL_M463, "m463dll")
|
||||
OVL_DEFINE(OVL_MENT, "mentdll")
|
||||
#if VERSION_JP
|
||||
OVL_DEFINE(OVL_MGMODE, "dll/mgmodedll.rel")
|
||||
OVL_DEFINE(OVL_MODELTEST, "dll/modeltestdll.rel")
|
||||
OVL_DEFINE(OVL_MODESEL, "dll/modeseldll.rel")
|
||||
OVL_DEFINE(OVL_MOVIE, "dll/moviedll.rel")
|
||||
OVL_DEFINE(OVL_MGMODE, "mgmodedll")
|
||||
OVL_DEFINE(OVL_MODELTEST, "modeltestdll")
|
||||
OVL_DEFINE(OVL_MODESEL, "modeseldll")
|
||||
OVL_DEFINE(OVL_MOVIE, "moviedll")
|
||||
#else
|
||||
OVL_DEFINE(OVL_MESS, "dll/messdll.rel")
|
||||
OVL_DEFINE(OVL_MGMODE, "dll/mgmodedll.rel")
|
||||
OVL_DEFINE(OVL_MODELTEST, "dll/modeltestdll.rel")
|
||||
OVL_DEFINE(OVL_MODESEL, "dll/modeseldll.rel")
|
||||
OVL_DEFINE(OVL_MESS, "messdll")
|
||||
OVL_DEFINE(OVL_MGMODE, "mgmodedll")
|
||||
OVL_DEFINE(OVL_MODELTEST, "modeltestdll")
|
||||
OVL_DEFINE(OVL_MODESEL, "modeseldll")
|
||||
#endif
|
||||
OVL_DEFINE(OVL_MPEX, "dll/mpexdll.rel")
|
||||
OVL_DEFINE(OVL_MSETUP, "dll/msetupdll.rel")
|
||||
OVL_DEFINE(OVL_MSTORY2, "dll/mstory2dll.rel")
|
||||
OVL_DEFINE(OVL_MSTORY3, "dll/mstory3dll.rel")
|
||||
OVL_DEFINE(OVL_MSTORY4, "dll/mstory4dll.rel")
|
||||
OVL_DEFINE(OVL_MSTORY, "dll/mstorydll.rel")
|
||||
OVL_DEFINE(OVL_NIS, "dll/nisdll.rel")
|
||||
OVL_DEFINE(OVL_OPTION, "dll/option.rel")
|
||||
OVL_DEFINE(OVL_PRESENT, "dll/present.rel")
|
||||
OVL_DEFINE(OVL_RESULT, "dll/resultdll.rel")
|
||||
OVL_DEFINE(OVL_SAF, "dll/safdll.rel")
|
||||
OVL_DEFINE(OVL_SELMENU, "dll/selmenuDLL.rel")
|
||||
OVL_DEFINE(OVL_STAFF, "dll/staffdll.rel")
|
||||
OVL_DEFINE(OVL_SUBCHRSEL, "dll/subchrseldll.rel")
|
||||
OVL_DEFINE(OVL_W01, "dll/w01dll.rel")
|
||||
OVL_DEFINE(OVL_W02, "dll/w02dll.rel")
|
||||
OVL_DEFINE(OVL_W03, "dll/w03dll.rel")
|
||||
OVL_DEFINE(OVL_W04, "dll/w04dll.rel")
|
||||
OVL_DEFINE(OVL_W05, "dll/w05dll.rel")
|
||||
OVL_DEFINE(OVL_W06, "dll/w06dll.rel")
|
||||
OVL_DEFINE(OVL_W10, "dll/w10dll.rel")
|
||||
OVL_DEFINE(OVL_W20, "dll/w20dll.rel")
|
||||
OVL_DEFINE(OVL_W21, "dll/w21dll.rel")
|
||||
OVL_DEFINE(OVL_ZTAR, "dll/ztardll.rel")
|
||||
OVL_DEFINE(OVL_MPEX, "mpexdll")
|
||||
OVL_DEFINE(OVL_MSETUP, "msetupdll")
|
||||
OVL_DEFINE(OVL_MSTORY2, "mstory2dll")
|
||||
OVL_DEFINE(OVL_MSTORY3, "mstory3dll")
|
||||
OVL_DEFINE(OVL_MSTORY4, "mstory4dll")
|
||||
OVL_DEFINE(OVL_MSTORY, "mstorydll")
|
||||
OVL_DEFINE(OVL_NIS, "nisdll")
|
||||
OVL_DEFINE(OVL_OPTION, "option")
|
||||
OVL_DEFINE(OVL_PRESENT, "present")
|
||||
OVL_DEFINE(OVL_RESULT, "resultdll")
|
||||
OVL_DEFINE(OVL_SAF, "safdll")
|
||||
OVL_DEFINE(OVL_SELMENU, "selmenuDLL")
|
||||
OVL_DEFINE(OVL_STAFF, "staffdll")
|
||||
OVL_DEFINE(OVL_SUBCHRSEL, "subchrseldll")
|
||||
OVL_DEFINE(OVL_W01, "w01dll")
|
||||
OVL_DEFINE(OVL_W02, "w02dll")
|
||||
OVL_DEFINE(OVL_W03, "w03dll")
|
||||
OVL_DEFINE(OVL_W04, "w04dll")
|
||||
OVL_DEFINE(OVL_W05, "w05dll")
|
||||
OVL_DEFINE(OVL_W06, "w06dll")
|
||||
OVL_DEFINE(OVL_W10, "w10dll")
|
||||
OVL_DEFINE(OVL_W20, "w20dll")
|
||||
OVL_DEFINE(OVL_W21, "w21dll")
|
||||
OVL_DEFINE(OVL_ZTAR, "ztardll")
|
||||
|
|
|
|||
352
include/port/byteswap.h
Normal file
352
include/port/byteswap.h
Normal file
|
|
@ -0,0 +1,352 @@
|
|||
#ifndef _SRC_BYTESWAP_H_
|
||||
#define _SRC_BYTESWAP_H_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include "game/animdata.h"
|
||||
#include "game/hsfformat.h"
|
||||
|
||||
typedef struct AnimData32b {
|
||||
s16 bankNum;
|
||||
s16 patNum;
|
||||
s16 bmpNum;
|
||||
s16 useNum;
|
||||
|
||||
u32 bank;
|
||||
u32 pat;
|
||||
u32 bmp;
|
||||
} AnimData32b;
|
||||
|
||||
typedef struct AnimBankData32b {
|
||||
s16 timeNum;
|
||||
s16 unk;
|
||||
u32 frame;
|
||||
} AnimBankData32b;
|
||||
|
||||
typedef struct AnimPatData32b {
|
||||
s16 layerNum;
|
||||
s16 centerX;
|
||||
s16 centerY;
|
||||
s16 sizeX;
|
||||
s16 sizeY;
|
||||
u32 layer;
|
||||
} AnimPatData32b;
|
||||
|
||||
typedef struct AnimBmpData32b {
|
||||
u8 pixSize;
|
||||
u8 dataFmt;
|
||||
s16 palNum;
|
||||
s16 sizeX;
|
||||
s16 sizeY;
|
||||
u32 dataSize;
|
||||
u32 palData;
|
||||
u32 data;
|
||||
} AnimBmpData32b;
|
||||
|
||||
typedef struct HsfCluster32b {
|
||||
u32 name[2];
|
||||
u32 targetName;
|
||||
u32 part;
|
||||
float index;
|
||||
float weight[32];
|
||||
u8 adjusted;
|
||||
u8 unk95;
|
||||
u16 type;
|
||||
u32 vertexCnt;
|
||||
u32 vertex;
|
||||
} HsfCluster32b;
|
||||
|
||||
typedef struct HsfAttribute32b {
|
||||
u32 name;
|
||||
u32 unk04;
|
||||
u8 unk8[4];
|
||||
float unk0C;
|
||||
u8 unk10[4];
|
||||
float unk14;
|
||||
u8 unk18[8];
|
||||
float unk20;
|
||||
u8 unk24[4];
|
||||
float unk28;
|
||||
float unk2C;
|
||||
float unk30;
|
||||
float unk34;
|
||||
u8 unk38[44];
|
||||
u32 wrap_s;
|
||||
u32 wrap_t;
|
||||
u8 unk6C[12];
|
||||
u32 unk78;
|
||||
u32 flag;
|
||||
u32 bitmap;
|
||||
} HsfAttribute32b;
|
||||
|
||||
typedef struct HsfMaterial32b {
|
||||
u32 name;
|
||||
u8 unk4[4];
|
||||
u16 pass;
|
||||
u8 vtxMode;
|
||||
u8 litColor[3];
|
||||
u8 color[3];
|
||||
u8 shadowColor[3];
|
||||
float hilite_scale;
|
||||
float unk18;
|
||||
float invAlpha;
|
||||
float unk20[2];
|
||||
float refAlpha;
|
||||
float unk2C;
|
||||
u32 flags;
|
||||
u32 numAttrs;
|
||||
u32 attrs;
|
||||
} HsfMaterial32b;
|
||||
|
||||
typedef struct HsfMapAttr32b {
|
||||
float minX;
|
||||
float minZ;
|
||||
float maxX;
|
||||
float maxZ;
|
||||
u32 data;
|
||||
u32 dataLen;
|
||||
} HsfMapAttr32b;
|
||||
|
||||
typedef struct HsfBuffer32b {
|
||||
u32 name;
|
||||
s32 count;
|
||||
u32 data;
|
||||
} HsfBuffer32b;
|
||||
|
||||
typedef struct HsfPalette32b {
|
||||
u32 name;
|
||||
s32 unk;
|
||||
u32 palSize;
|
||||
u32 data;
|
||||
} HsfPalette32b;
|
||||
|
||||
typedef struct HsfBitmap32b {
|
||||
u32 name;
|
||||
u32 maxLod;
|
||||
u8 dataFmt;
|
||||
u8 pixSize;
|
||||
s16 sizeX;
|
||||
s16 sizeY;
|
||||
s16 palSize;
|
||||
GXColor tint;
|
||||
u32 palData;
|
||||
u32 unk;
|
||||
u32 data;
|
||||
} HsfBitmap32b;
|
||||
|
||||
typedef struct HsfPart32b {
|
||||
u32 name;
|
||||
u32 count;
|
||||
u32 vertex;
|
||||
} HsfPart32b;
|
||||
|
||||
typedef struct HsfSkeleton32b {
|
||||
u32 name;
|
||||
HsfTransform transform;
|
||||
} HsfSkeleton32b;
|
||||
|
||||
typedef struct HsfShape32b {
|
||||
u32 name;
|
||||
union {
|
||||
u16 count16[2];
|
||||
u32 vertexCnt;
|
||||
};
|
||||
u32 vertex;
|
||||
} HsfShape32b;
|
||||
|
||||
typedef struct HsfCenvDual32b {
|
||||
u32 target1;
|
||||
u32 target2;
|
||||
u32 weightCnt;
|
||||
u32 weight;
|
||||
} HsfCenvDual32b;
|
||||
|
||||
typedef struct HsfCenvMulti32b {
|
||||
u32 weightCnt;
|
||||
u16 pos;
|
||||
u16 posCnt;
|
||||
u16 normal;
|
||||
u16 normalCnt;
|
||||
u32 weight;
|
||||
} HsfCenvMulti32b;
|
||||
|
||||
typedef struct HsfCenv32b {
|
||||
u32 name;
|
||||
u32 singleData;
|
||||
u32 dualData;
|
||||
u32 multiData;
|
||||
u32 singleCount;
|
||||
u32 dualCount;
|
||||
u32 multiCount;
|
||||
u32 vtxCount;
|
||||
u32 copyCount;
|
||||
} HsfCenv32b;
|
||||
|
||||
typedef struct HsfObjectData32b {
|
||||
u32 parent;
|
||||
u32 childrenCount;
|
||||
u32 children;
|
||||
HsfTransform base;
|
||||
HsfTransform curr;
|
||||
union {
|
||||
struct {
|
||||
HsfVector3f min;
|
||||
HsfVector3f max;
|
||||
float baseMorph;
|
||||
float morphWeight[33];
|
||||
} mesh;
|
||||
u32 replica;
|
||||
};
|
||||
|
||||
u32 face;
|
||||
u32 vertex;
|
||||
u32 normal;
|
||||
u32 color;
|
||||
u32 st;
|
||||
u32 material;
|
||||
u32 attribute;
|
||||
u8 unk120[2];
|
||||
u8 shapeType;
|
||||
u8 unk123;
|
||||
u32 vertexShapeCnt;
|
||||
u32 vertexShape;
|
||||
u32 clusterCnt;
|
||||
u32 cluster;
|
||||
u32 cenvCnt;
|
||||
u32 cenv;
|
||||
u32 vtxtop;
|
||||
u32 normtop;
|
||||
} HsfObjectData32b;
|
||||
|
||||
typedef struct HsfObject32b {
|
||||
u32 name;
|
||||
u32 type;
|
||||
u32 constData;
|
||||
u32 flags;
|
||||
HsfObjectData32b data;
|
||||
} HsfObject32b;
|
||||
|
||||
typedef struct HsfTrack32b {
|
||||
u8 type;
|
||||
u8 start;
|
||||
union {
|
||||
u16 target;
|
||||
s16 target_s16;
|
||||
};
|
||||
union {
|
||||
s32 unk04;
|
||||
struct {
|
||||
union {
|
||||
s16 param;
|
||||
u16 param_u16;
|
||||
};
|
||||
union {
|
||||
u16 channel;
|
||||
s16 channel_s16;
|
||||
};
|
||||
};
|
||||
};
|
||||
u16 curveType;
|
||||
u16 numKeyframes;
|
||||
union {
|
||||
float value;
|
||||
u32 data;
|
||||
};
|
||||
} HsfTrack32b;
|
||||
|
||||
typedef struct HsfMotion32b {
|
||||
u32 name;
|
||||
s32 numTracks;
|
||||
u32 track;
|
||||
float len;
|
||||
} HsfMotion32b;
|
||||
|
||||
typedef struct HsfBitmapKey32b {
|
||||
float time;
|
||||
u32 data;
|
||||
} HsfBitmapKey32b;
|
||||
|
||||
typedef struct HsfFace32b {
|
||||
s16 type;
|
||||
s16 mat;
|
||||
union {
|
||||
struct {
|
||||
s16 indices[3][4];
|
||||
u32 count;
|
||||
u32 data;
|
||||
} strip;
|
||||
s16 indices[4][4];
|
||||
};
|
||||
Vec nbt;
|
||||
} HsfFace32b;
|
||||
|
||||
typedef struct HsfMatrix32b {
|
||||
u32 base_idx;
|
||||
u32 count;
|
||||
u32 data;
|
||||
} HsfMatrix32b;
|
||||
|
||||
void byteswap_u16(u16 *src);
|
||||
void byteswap_s16(s16 *src);
|
||||
void byteswap_u32(u32 *src);
|
||||
void byteswap_s32(s32 *src);
|
||||
void byteswap_hsfvec3f(HsfVector3f *src);
|
||||
void byteswap_hsfvec2f(HsfVector2f *src);
|
||||
|
||||
void byteswap_animdata(void *src, AnimData *dest);
|
||||
void byteswap_animbankdata(AnimBankData32b *src, AnimBankData *dest);
|
||||
void byteswap_animpatdata(AnimPatData32b *src, AnimPatData *dest);
|
||||
void byteswap_animbmpdata(AnimBmpData32b *src, AnimBmpData *dest);
|
||||
void byteswap_animframedata(AnimFrameData *src);
|
||||
void byteswap_animlayerdata(AnimLayerData *src);
|
||||
|
||||
void byteswap_hsfheader(HsfHeader *src);
|
||||
void byteswap_hsfcluster(HsfCluster32b *src, HsfCluster *dest);
|
||||
void byteswap_hsfattribute(HsfAttribute32b *src, HsfAttribute *dest);
|
||||
void byteswap_hsfmaterial(HsfMaterial32b *src, HsfMaterial *dest);
|
||||
void byteswap_hsfscene(HsfScene *src);
|
||||
void byteswap_hsfbuffer(HsfBuffer32b *src, HsfBuffer *dest);
|
||||
void byteswap_hsfmatrix(HsfMatrix32b *src, HsfMatrix *dest);
|
||||
void byteswap_hsfpalette(HsfPalette32b *src, HsfPalette *dest);
|
||||
void byteswap_hsfpart(HsfPart32b *src, HsfPart *dest);
|
||||
void byteswap_hsfbitmap(HsfBitmap32b *src, HsfBitmap *dest);
|
||||
void byteswap_hsfmapattr(HsfMapAttr32b *src, HsfMapAttr *dest);
|
||||
void byteswap_hsfskeleton(HsfSkeleton32b *src, HsfSkeleton *dest);
|
||||
void byteswap_hsfshape(HsfShape32b *src, HsfShape *dest);
|
||||
void byteswap_hsfcenv_single(HsfCenvSingle *src);
|
||||
void byteswap_hsfcenv(HsfCenv32b *src, HsfCenv *dest);
|
||||
void byteswap_hsfobject(HsfObject32b *src, HsfObject *dest);
|
||||
void byteswap_hsfbitmapkey(HsfBitmapKey32b *src, HsfBitmapKey *dest);
|
||||
void byteswap_hsftrack(HsfTrack32b *src, HsfTrack *dest);
|
||||
void byteswap_hsfmotion(HsfMotion32b *src, HsfMotion *dest);
|
||||
void byteswap_hsfface(HsfFace32b *src, HsfFace *dest);
|
||||
void byteswap_hsfcluster(HsfCluster32b *src, HsfCluster *dest);
|
||||
void byteswap_hsfattribute(HsfAttribute32b *src, HsfAttribute *dest);
|
||||
void byteswap_hsfmaterial(HsfMaterial32b *src, HsfMaterial *dest);
|
||||
void byteswap_hsfscene(HsfScene *src);
|
||||
void byteswap_hsfbuffer(HsfBuffer32b *src, HsfBuffer *dest);
|
||||
void byteswap_hsfpalette(HsfPalette32b *src, HsfPalette *dest);
|
||||
void byteswap_hsfpart(HsfPart32b *src, HsfPart *dest);
|
||||
void byteswap_hsfbitmap(HsfBitmap32b *src, HsfBitmap *dest);
|
||||
void byteswap_hsfmapattr(HsfMapAttr32b *src, HsfMapAttr *dest);
|
||||
void byteswap_hsfskeleton(HsfSkeleton32b *src, HsfSkeleton *dest);
|
||||
void byteswap_hsfshape(HsfShape32b *src, HsfShape *dest);
|
||||
void byteswap_hsfcenv_single(HsfCenvSingle *src);
|
||||
void byteswap_hsfcenv_dual_weight(HsfCenvDualWeight *src);
|
||||
void byteswap_hsfcenv_dual(HsfCenvDual32b *src, HsfCenvDual *dest);
|
||||
void byteswap_hsfcenv_multi_weight(HsfCenvMultiWeight *src);
|
||||
void byteswap_hsfcenv_multi(HsfCenvMulti32b *src, HsfCenvMulti *dest);
|
||||
void byteswap_hsfcenv(HsfCenv32b *src, HsfCenv *dest);
|
||||
void byteswap_hsfobject(HsfObject32b *src, HsfObject *dest);
|
||||
void byteswap_hsfbitmapkey(HsfBitmapKey32b *src, HsfBitmapKey *dest);
|
||||
void byteswap_hsftrack(HsfTrack32b *src, HsfTrack *dest);
|
||||
void byteswap_hsfmotion(HsfMotion32b *src, HsfMotion *dest);
|
||||
void byteswap_hsfface(HsfFace32b *src, HsfFace *dest);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
18
include/port/imgui.h
Normal file
18
include/port/imgui.h
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
#ifndef _SRC_IMGUI_H_
|
||||
#define _SRC_IMGUI_H_
|
||||
|
||||
#include <aurora/aurora.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
void imgui_main(const AuroraInfo* info);
|
||||
void frame_limiter();
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
@ -1,8 +1,6 @@
|
|||
#ifndef _TYPES_H_
|
||||
#define _TYPES_H_
|
||||
|
||||
#define ARRAY_COUNT(arr) (s32)(sizeof(arr) / sizeof(arr[0]))
|
||||
|
||||
#include "dolphin/types.h"
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -21,4 +21,15 @@
|
|||
#define REFRESH_RATE 60
|
||||
#endif
|
||||
|
||||
#if _WIN32
|
||||
#ifdef TARGET_DOL
|
||||
#define SHARED_SYM __declspec(dllexport)
|
||||
#else
|
||||
#define SHARED_SYM __declspec(dllimport)
|
||||
#endif
|
||||
|
||||
#else
|
||||
#define SHARED_SYM
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,8 +1,6 @@
|
|||
#ifndef _MATH_H
|
||||
#define _MATH_H
|
||||
|
||||
#define M_PI 3.141592653589793
|
||||
|
||||
#ifndef _MATH_INLINE
|
||||
#define _MATH_INLINE static inline
|
||||
#endif
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue