mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-07-04 11:19:58 -04:00
Compare commits
164 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| a5de0c276a | |||
| 277538bb81 | |||
| 5418b1831d | |||
| 2d4e69466b | |||
| 427dcfab82 | |||
| f5642f3073 | |||
| cc9c15de54 | |||
| 1fd8a2ca3c | |||
| 0c9c8795ce | |||
| 9eb9acfa11 | |||
| facbf35343 | |||
| 7a34830dc7 | |||
| e4557efb23 | |||
| 42e12eb5ab | |||
| 16cc37ca10 | |||
| 44cb2c84ba | |||
| 8e9d4d624a | |||
| db87b91954 | |||
| ad53af5c78 | |||
| a6e5160c71 | |||
| 38a0a7be0b | |||
| 02fdde3768 | |||
| 33e13d508b | |||
| afc3376aec | |||
| b07fb50128 | |||
| d0894853d7 | |||
| cacb768725 | |||
| 00707024bb | |||
| 7c5ed6a0e1 | |||
| 131a09f317 | |||
| a58f9c7b43 | |||
| 7290649bb8 | |||
| 34e1e740ab | |||
| a58f64ed80 | |||
| 28a37f6b4f | |||
| 285691cd19 | |||
| 93e33ecf1a | |||
| e26fab71d6 | |||
| 824389f871 | |||
| aa42265041 | |||
| 8b7ed4b5da | |||
| f33746f373 | |||
| 18c1d11335 | |||
| 710f252d53 | |||
| 2a92a67b87 | |||
| 0d05f9b75b | |||
| e27cce0e3c | |||
| 511721f4d5 | |||
| b6f0e104bd | |||
| 08e0f4a2ee | |||
| 7a900471bf | |||
| d9d9966f8f | |||
| 8705e75b9d | |||
| 1b42c4ecac | |||
| 24ca190029 | |||
| eefa69b53d | |||
| da3ac9f546 | |||
| 7f306fe1ec | |||
| 358de64570 | |||
| e484a10018 | |||
| 0936115483 | |||
| b00b7f8f1b | |||
| 08c4442fdf | |||
| 74f20c38e0 | |||
| b7d32918bd | |||
| e99b604dd2 | |||
| 2376e0102e | |||
| 5a9bd6f8dc | |||
| 62a26a639d | |||
| 1a247c2977 | |||
| ef122efccd | |||
| deadde352c | |||
| 460b96c709 | |||
| f8ba14ea8f | |||
| bd9b81f700 | |||
| b531936a1f | |||
| 21692d5a78 | |||
| 7af51e53bd | |||
| bd90c3fc69 | |||
| 37abcaf616 | |||
| b26f3f7f51 | |||
| 66aca3b69d | |||
| bd09eea0f3 | |||
| 531313120f | |||
| 81caa89e12 | |||
| bc3cdcc955 | |||
| bf0dc85468 | |||
| 656346a900 | |||
| 5269eadfaf | |||
| fd26670b0e | |||
| c83cc3b971 | |||
| 8c713d4535 | |||
| 183e7669c2 | |||
| f38514db79 | |||
| 3792912ad1 | |||
| e5c032f6e6 | |||
| d9795f4098 | |||
| 87d56be232 | |||
| be2924b509 | |||
| be3e6b80eb | |||
| 10c310f7b1 | |||
| 5f0c44eb84 | |||
| b88a5e4ac3 | |||
| 030ef0f3bf | |||
| c3c8d459e8 | |||
| 21e0491d43 | |||
| 62c19c0f64 | |||
| 477192f3c2 | |||
| 71961dae85 | |||
| 6592d95199 | |||
| c10e41f02e | |||
| e70fef0650 | |||
| e7e04b7c15 | |||
| 42d9dd23c0 | |||
| 5d68762590 | |||
| db39a9c7f3 | |||
| 23a5e2c48d | |||
| 496ddf63bd | |||
| eab481661d | |||
| a9c8f44a86 | |||
| af6ca3c80c | |||
| 9973a28154 | |||
| 358d218e8f | |||
| 5b9e9106ef | |||
| 0692fa5423 | |||
| 40f49a8615 | |||
| fb9ffb444a | |||
| 9823ca7c4a | |||
| 32069d936c | |||
| 3f018204b6 | |||
| 012b54b325 | |||
| 42d412a06e | |||
| 37e5b7409d | |||
| cfc0fbc342 | |||
| 3e84c65657 | |||
| 08cbaff57b | |||
| d85718f802 | |||
| 925bb069d9 | |||
| b2871054a6 | |||
| 5bead49902 | |||
| 4175d9c7f4 | |||
| 0d6b47ac73 | |||
| 1fb5d1ee2a | |||
| c042de8a55 | |||
| e25a1f3ef6 | |||
| b7f9bc91b4 | |||
| 3281c64a55 | |||
| fb08cfcc6b | |||
| 99fb2b89ce | |||
| 53573eb795 | |||
| 975ab1dc54 | |||
| 9d10a48329 | |||
| 52a067e412 | |||
| 5dcbca392d | |||
| ba906150d4 | |||
| e5c7dfdedd | |||
| 02a4e213e3 | |||
| 394627cd47 | |||
| e7081f770a | |||
| 8356eff4ce | |||
| 3597cb1bd6 | |||
| 507616015e | |||
| db20632130 | |||
| 22d906a248 |
@@ -0,0 +1,116 @@
|
|||||||
|
name: Bug Report
|
||||||
|
description: Report an issue with Dusklight
|
||||||
|
type: Bug
|
||||||
|
body:
|
||||||
|
- type: checkboxes
|
||||||
|
id: official-build-certification
|
||||||
|
attributes:
|
||||||
|
label: Mods and Forks
|
||||||
|
description: Certify that this issue exists on the official builds of Dusklight
|
||||||
|
options:
|
||||||
|
- label: The bug occurs on an **official release** of Dusklight, without any forks or third-party patches installed
|
||||||
|
required: true
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: input
|
||||||
|
id: dusklight-version
|
||||||
|
attributes:
|
||||||
|
label: Dusklight Version
|
||||||
|
placeholder: ex. 1.3.1
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
id: bug-description
|
||||||
|
attributes:
|
||||||
|
label: Bug Description
|
||||||
|
placeholder: Describe the bug you are encountering
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
id: repro-steps
|
||||||
|
attributes:
|
||||||
|
label: Steps to Reproduce
|
||||||
|
placeholder: |
|
||||||
|
1. Load save
|
||||||
|
2. Go to Hyrule Field
|
||||||
|
3. See bug
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
id: expected-behavior
|
||||||
|
attributes:
|
||||||
|
label: Expected Behavior
|
||||||
|
placeholder: Describe what should be happening
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
id: current-behavior
|
||||||
|
attributes:
|
||||||
|
label: Current Behavior
|
||||||
|
placeholder: Describe what is happening instead
|
||||||
|
|
||||||
|
- type: dropdown
|
||||||
|
id: system-os-architecture
|
||||||
|
attributes:
|
||||||
|
label: OS / Architecture
|
||||||
|
description: The operating system and architecture you are running Dusklight on
|
||||||
|
options:
|
||||||
|
- Windows x86-64
|
||||||
|
- Windows ARM64
|
||||||
|
- MacOS ARM64
|
||||||
|
- MacOS x86-64
|
||||||
|
- Linux ARM64
|
||||||
|
- Linux x84-64
|
||||||
|
- Android ARM64
|
||||||
|
- iOS ARM64
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: dropdown
|
||||||
|
id: game-region
|
||||||
|
attributes:
|
||||||
|
label: Game Region
|
||||||
|
description: The game region you are playing on
|
||||||
|
options:
|
||||||
|
- NTSC-U (North America)
|
||||||
|
- PAL (Europe)
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: input
|
||||||
|
id: game-language
|
||||||
|
attributes:
|
||||||
|
label: Game Language
|
||||||
|
description: The language you are playing the game in
|
||||||
|
placeholder: ex. English, Spanish, etc.
|
||||||
|
|
||||||
|
- type: dropdown
|
||||||
|
attributes:
|
||||||
|
label: Graphics Backend
|
||||||
|
options:
|
||||||
|
- Vulkan
|
||||||
|
- D3D12
|
||||||
|
- Metal
|
||||||
|
- D3D11
|
||||||
|
- OpenGL ES
|
||||||
|
- Unsure / Default
|
||||||
|
default: 5
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
id: texture-packs-mods
|
||||||
|
attributes:
|
||||||
|
label: Texture Packs and Mods
|
||||||
|
placeholder: List any texture packs or mods you had installed
|
||||||
|
|
||||||
|
- type: upload
|
||||||
|
id: logs-upload
|
||||||
|
attributes:
|
||||||
|
label: Logs and Other Files
|
||||||
|
description: Include any relevant logs, config files, or saves to reproduce the bug
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
id: additional-context
|
||||||
|
attributes:
|
||||||
|
label: Additional Context
|
||||||
|
placeholder: Any other information that might be helpful
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
name: Feature Request
|
||||||
|
description: Request a new Dusklight feature. Not all requests can/will be included, but we will take these ideas into consideration.
|
||||||
|
type: Feature
|
||||||
|
body:
|
||||||
|
- type: textarea
|
||||||
|
id: feature-description
|
||||||
|
attributes:
|
||||||
|
label: Feature Description
|
||||||
|
placeholder: Describe the feature you are requesting
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: input
|
||||||
|
id: feature-platform
|
||||||
|
attributes:
|
||||||
|
label: Platform
|
||||||
|
description: If applicable, list the platforms this feature applies to. If it is for all platforms, feel free to leave this field blank.
|
||||||
|
placeholder: ex. Mac, Android, Steam Deck, etc.
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
id: feature-related-info
|
||||||
|
attributes:
|
||||||
|
label: Additional Information
|
||||||
|
placeholder: Any other information that might be helpful (related features, existing implementations, open pull requests or issues, etc.)
|
||||||
@@ -5,7 +5,12 @@ on:
|
|||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '*.md'
|
- '*.md'
|
||||||
- '*LICENSE'
|
- '*LICENSE'
|
||||||
|
- 'docs/**'
|
||||||
pull_request:
|
pull_request:
|
||||||
|
paths-ignore:
|
||||||
|
- '*.md'
|
||||||
|
- '*LICENSE'
|
||||||
|
- 'docs/**'
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && format('pr-{0}', github.event.pull_request.number) || format('run-{0}', github.run_id) }}
|
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && format('pr-{0}', github.event.pull_request.number) || format('run-{0}', github.run_id) }}
|
||||||
@@ -47,7 +52,7 @@ jobs:
|
|||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get -y install ninja-build clang lld openssl libcurl4-openssl-dev \
|
sudo apt-get -y install ninja-build clang lld mold openssl libcurl4-openssl-dev \
|
||||||
zlib1g-dev libglu1-mesa-dev libdbus-1-dev libvulkan-dev libxi-dev libxrandr-dev libasound2-dev \
|
zlib1g-dev libglu1-mesa-dev libdbus-1-dev libvulkan-dev libxi-dev libxrandr-dev libasound2-dev \
|
||||||
libpulse-dev libudev-dev libpng-dev libncurses5-dev libx11-xcb-dev libfreetype-dev \
|
libpulse-dev libudev-dev libpng-dev libncurses5-dev libx11-xcb-dev libfreetype-dev \
|
||||||
libxinerama-dev libxcursor-dev python3-markupsafe libgtk-3-dev libssl-dev \
|
libxinerama-dev libxcursor-dev python3-markupsafe libgtk-3-dev libssl-dev \
|
||||||
|
|||||||
@@ -53,3 +53,5 @@ compile_commands.json
|
|||||||
pipeline_cache.bin
|
pipeline_cache.bin
|
||||||
|
|
||||||
extract
|
extract
|
||||||
|
|
||||||
|
*.dusk
|
||||||
|
|||||||
Vendored
+2
-2
@@ -6,12 +6,12 @@
|
|||||||
"type": "cppvsdbg",
|
"type": "cppvsdbg",
|
||||||
"request": "launch",
|
"request": "launch",
|
||||||
"program": "${command:cmake.launchTargetPath}",
|
"program": "${command:cmake.launchTargetPath}",
|
||||||
"args": ["-l", "1", "--dvd", "${workspaceRoot}/orig/GZ2E01/GZ2E01.iso", "--console"],
|
"args": ["-l", "1", "--dvd", "${workspaceRoot}/orig/GZ2E01/GZ2E01.iso", "--console", "--mods", "${workspaceRoot}/mods"],
|
||||||
"MIMode": "gdb",
|
"MIMode": "gdb",
|
||||||
"miDebuggerPath": "gdb",
|
"miDebuggerPath": "gdb",
|
||||||
"symbolSearchPath": "${command:cmake.launchTargetPath}",
|
"symbolSearchPath": "${command:cmake.launchTargetPath}",
|
||||||
"console": "integratedTerminal",
|
"console": "integratedTerminal",
|
||||||
"cwd":"${workspaceRoot}"
|
"cwd":"${workspaceRoot}",
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
+203
-38
@@ -21,26 +21,26 @@ else ()
|
|||||||
find_package(Git)
|
find_package(Git)
|
||||||
if (GIT_FOUND)
|
if (GIT_FOUND)
|
||||||
# make sure version information gets re-run when the current Git HEAD changes
|
# make sure version information gets re-run when the current Git HEAD changes
|
||||||
execute_process(WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} rev-parse --git-path HEAD
|
execute_process(WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} rev-parse --git-path HEAD
|
||||||
OUTPUT_VARIABLE dusk_git_head_filename
|
OUTPUT_VARIABLE dusk_git_head_filename
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS "${dusk_git_head_filename}")
|
set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS "${dusk_git_head_filename}")
|
||||||
|
|
||||||
execute_process(WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} rev-parse --symbolic-full-name HEAD
|
execute_process(WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} rev-parse --symbolic-full-name HEAD
|
||||||
OUTPUT_VARIABLE dusk_git_head_symbolic
|
OUTPUT_VARIABLE dusk_git_head_symbolic
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
execute_process(WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
execute_process(WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||||
COMMAND ${GIT_EXECUTABLE} rev-parse --git-path ${dusk_git_head_symbolic}
|
COMMAND ${GIT_EXECUTABLE} rev-parse --git-path ${dusk_git_head_symbolic}
|
||||||
OUTPUT_VARIABLE dusk_git_head_symbolic_filename
|
OUTPUT_VARIABLE dusk_git_head_symbolic_filename
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS "${dusk_git_head_symbolic_filename}")
|
set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS "${dusk_git_head_symbolic_filename}")
|
||||||
|
|
||||||
# defines DUSK_WC_REVISION
|
# defines DUSK_WC_REVISION
|
||||||
execute_process(WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} rev-parse HEAD
|
execute_process(WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} rev-parse HEAD
|
||||||
OUTPUT_VARIABLE DUSK_WC_REVISION
|
OUTPUT_VARIABLE DUSK_WC_REVISION
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
# defines DUSK_WC_DESCRIBE
|
# defines DUSK_WC_DESCRIBE
|
||||||
execute_process(WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} describe --tags --long --dirty --match "v*"
|
execute_process(WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} describe --tags --long --dirty --match "v*"
|
||||||
OUTPUT_VARIABLE DUSK_WC_DESCRIBE
|
OUTPUT_VARIABLE DUSK_WC_DESCRIBE
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
|
|
||||||
@@ -49,11 +49,11 @@ if (GIT_FOUND)
|
|||||||
string(REGEX REPLACE "-0$" "" DUSK_WC_DESCRIBE "${DUSK_WC_DESCRIBE}")
|
string(REGEX REPLACE "-0$" "" DUSK_WC_DESCRIBE "${DUSK_WC_DESCRIBE}")
|
||||||
|
|
||||||
# defines DUSK_WC_BRANCH
|
# defines DUSK_WC_BRANCH
|
||||||
execute_process(WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} rev-parse --abbrev-ref HEAD
|
execute_process(WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} rev-parse --abbrev-ref HEAD
|
||||||
OUTPUT_VARIABLE DUSK_WC_BRANCH
|
OUTPUT_VARIABLE DUSK_WC_BRANCH
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
# defines DUSK_WC_DATE
|
# defines DUSK_WC_DATE
|
||||||
execute_process(WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} log -1 --format=%ad
|
execute_process(WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} COMMAND ${GIT_EXECUTABLE} log -1 --format=%ad
|
||||||
OUTPUT_VARIABLE DUSK_WC_DATE
|
OUTPUT_VARIABLE DUSK_WC_DATE
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||||
else ()
|
else ()
|
||||||
@@ -126,6 +126,33 @@ set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
|
|||||||
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
|
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
|
||||||
set_property(GLOBAL PROPERTY PREDEFINED_TARGETS_FOLDER "_cmake")
|
set_property(GLOBAL PROPERTY PREDEFINED_TARGETS_FOLDER "_cmake")
|
||||||
|
|
||||||
|
option(ENABLE_ASAN "Enable AddressSanitizer" OFF)
|
||||||
|
if (ENABLE_ASAN)
|
||||||
|
if (CMAKE_C_COMPILER_FRONTEND_VARIANT STREQUAL "MSVC" AND
|
||||||
|
CMAKE_CXX_COMPILER_FRONTEND_VARIANT STREQUAL "MSVC")
|
||||||
|
add_compile_options($<$<COMPILE_LANGUAGE:C,CXX>:/fsanitize=address>)
|
||||||
|
add_link_options(/fsanitize=address /INCREMENTAL:NO)
|
||||||
|
set(CMAKE_MSVC_DEBUG_INFORMATION_FORMAT "ProgramDatabase")
|
||||||
|
foreach (_lang C CXX)
|
||||||
|
foreach (_rtc_flag /RTC1 /RTCc /RTCs /RTCu)
|
||||||
|
string(REPLACE "${_rtc_flag}" "" CMAKE_${_lang}_FLAGS_DEBUG "${CMAKE_${_lang}_FLAGS_DEBUG}")
|
||||||
|
endforeach ()
|
||||||
|
endforeach ()
|
||||||
|
elseif (CMAKE_C_COMPILER_FRONTEND_VARIANT STREQUAL "GNU" AND
|
||||||
|
CMAKE_CXX_COMPILER_FRONTEND_VARIANT STREQUAL "GNU")
|
||||||
|
add_compile_options(
|
||||||
|
$<$<COMPILE_LANGUAGE:C,CXX,OBJC,OBJCXX>:-fsanitize=address>
|
||||||
|
$<$<COMPILE_LANGUAGE:C,CXX,OBJC,OBJCXX>:-fno-omit-frame-pointer>
|
||||||
|
)
|
||||||
|
add_link_options(-fsanitize=address)
|
||||||
|
else ()
|
||||||
|
message(FATAL_ERROR "ENABLE_ASAN requires GNU-like or MSVC-like C/C++ compiler frontends")
|
||||||
|
endif ()
|
||||||
|
|
||||||
|
add_compile_definitions(NDEBUG_SANITIZER) # Avoids absl issue with SwissTable debug code
|
||||||
|
message(STATUS "dusklight: Enabled AddressSanitizer")
|
||||||
|
endif ()
|
||||||
|
|
||||||
if (CMAKE_SYSTEM_NAME STREQUAL Linux)
|
if (CMAKE_SYSTEM_NAME STREQUAL Linux)
|
||||||
set(DAWN_USE_WAYLAND ON CACHE BOOL "Enable support for Wayland surface" FORCE)
|
set(DAWN_USE_WAYLAND ON CACHE BOOL "Enable support for Wayland surface" FORCE)
|
||||||
endif ()
|
endif ()
|
||||||
@@ -137,11 +164,19 @@ target_compile_definitions(aurora_mtx PRIVATE MTX_USE_PS=1)
|
|||||||
|
|
||||||
add_subdirectory(libs/freeverb)
|
add_subdirectory(libs/freeverb)
|
||||||
|
|
||||||
|
if (CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||||
|
set(DUSK_GFX_DEBUG_GROUPS_DEFAULT ON)
|
||||||
|
else ()
|
||||||
|
set(DUSK_GFX_DEBUG_GROUPS_DEFAULT OFF)
|
||||||
|
endif ()
|
||||||
|
|
||||||
option(DUSK_BUILD_WARNINGS "Enable compiler warnings (off by default)")
|
option(DUSK_BUILD_WARNINGS "Enable compiler warnings (off by default)")
|
||||||
option(DUSK_SELECTED_OPT "If on, selected parts of the project will be compiled with optimizations on Debug, intending to make the game run at 30 FPS. Note for MSVC: you will need to remove '/RTC1' from your debug flags in CMake.")
|
option(DUSK_SELECTED_OPT "If on, selected parts of the project will be compiled with optimizations on Debug, intending to make the game run at 30 FPS. Note for MSVC: you will need to remove '/RTC1' from your debug flags in CMake.")
|
||||||
option(DUSK_MOVIE_SUPPORT "If on, compile against libjpeg-turbo to enable THP file decoding" ON)
|
option(DUSK_MOVIE_SUPPORT "If on, compile against libjpeg-turbo to enable THP file decoding" ON)
|
||||||
option(DUSK_ENABLE_UPDATE_CHECKER "Enable update checking support" ON)
|
option(DUSK_ENABLE_UPDATE_CHECKER "Enable update checking support" ON)
|
||||||
option(DUSK_ENABLE_SENTRY_NATIVE "Enable sentry-native crash reporting support" OFF)
|
option(DUSK_ENABLE_SENTRY_NATIVE "Enable sentry-native crash reporting support" OFF)
|
||||||
|
option(DUSK_PACKAGE_INSTALL "Install Dusklight with a Linux-native file structure" OFF)
|
||||||
|
option(DUSK_GFX_DEBUG_GROUPS "Report debug groups to the native graphics API" ${DUSK_GFX_DEBUG_GROUPS_DEFAULT})
|
||||||
set(DUSK_SENTRY_DSN "" CACHE STRING "Sentry DSN")
|
set(DUSK_SENTRY_DSN "" CACHE STRING "Sentry DSN")
|
||||||
set(DUSK_SENTRY_ENVIRONMENT "development" CACHE STRING "Sentry environment")
|
set(DUSK_SENTRY_ENVIRONMENT "development" CACHE STRING "Sentry environment")
|
||||||
|
|
||||||
@@ -176,7 +211,7 @@ if (DUSK_MOVIE_SUPPORT)
|
|||||||
-DWITH_JAVA=OFF
|
-DWITH_JAVA=OFF
|
||||||
)
|
)
|
||||||
if (CMAKE_TOOLCHAIN_FILE)
|
if (CMAKE_TOOLCHAIN_FILE)
|
||||||
get_filename_component(_jpeg_toolchain_file "${CMAKE_TOOLCHAIN_FILE}" ABSOLUTE BASE_DIR "${CMAKE_SOURCE_DIR}")
|
get_filename_component(_jpeg_toolchain_file "${CMAKE_TOOLCHAIN_FILE}" ABSOLUTE BASE_DIR "${CMAKE_CURRENT_SOURCE_DIR}")
|
||||||
list(APPEND _jpeg_cmake_args -DCMAKE_TOOLCHAIN_FILE=${_jpeg_toolchain_file})
|
list(APPEND _jpeg_cmake_args -DCMAKE_TOOLCHAIN_FILE=${_jpeg_toolchain_file})
|
||||||
endif ()
|
endif ()
|
||||||
set(_jpeg_passthrough_vars
|
set(_jpeg_passthrough_vars
|
||||||
@@ -189,6 +224,8 @@ if (DUSK_MOVIE_SUPPORT)
|
|||||||
CMAKE_MSVC_RUNTIME_LIBRARY
|
CMAKE_MSVC_RUNTIME_LIBRARY
|
||||||
CMAKE_MSVC_DEBUG_INFORMATION_FORMAT
|
CMAKE_MSVC_DEBUG_INFORMATION_FORMAT
|
||||||
CMAKE_OSX_ARCHITECTURES
|
CMAKE_OSX_ARCHITECTURES
|
||||||
|
CMAKE_OSX_DEPLOYMENT_TARGET
|
||||||
|
CMAKE_OSX_SYSROOT
|
||||||
DEPLOYMENT_TARGET
|
DEPLOYMENT_TARGET
|
||||||
ENABLE_ARC
|
ENABLE_ARC
|
||||||
ENABLE_BITCODE
|
ENABLE_BITCODE
|
||||||
@@ -219,10 +256,9 @@ if (CMAKE_SYSTEM_NAME STREQUAL Linux)
|
|||||||
# -Wno-multichar: Multi-character constants ('ABCD') are implementation-defined but all compilers
|
# -Wno-multichar: Multi-character constants ('ABCD') are implementation-defined but all compilers
|
||||||
# (CW, GCC, Clang, MSVC) encode them identically in big-endian order.
|
# (CW, GCC, Clang, MSVC) encode them identically in big-endian order.
|
||||||
# For >4-char literals (which GCC/Clang truncate to int), use the MULTI_CHAR() macro.
|
# For >4-char literals (which GCC/Clang truncate to int), use the MULTI_CHAR() macro.
|
||||||
# -Wwrite-strings: Game code relies on implicit const char* -> char* conversions
|
|
||||||
# -Wdeprecated-declarations: JSystem uses std::iterator, deprecated in C++17
|
# -Wdeprecated-declarations: JSystem uses std::iterator, deprecated in C++17
|
||||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-multichar -Wno-write-strings")
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-multichar")
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-multichar -Wno-write-strings -Wno-trigraphs -Wno-deprecated-declarations")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-multichar -Wno-trigraphs -Wno-deprecated-declarations")
|
||||||
set(CMAKE_INSTALL_RPATH "$ORIGIN")
|
set(CMAKE_INSTALL_RPATH "$ORIGIN")
|
||||||
set(CMAKE_BUILD_RPATH "$ORIGIN")
|
set(CMAKE_BUILD_RPATH "$ORIGIN")
|
||||||
elseif (APPLE)
|
elseif (APPLE)
|
||||||
@@ -232,7 +268,6 @@ elseif (APPLE)
|
|||||||
elseif (MSVC)
|
elseif (MSVC)
|
||||||
add_compile_options(
|
add_compile_options(
|
||||||
$<$<COMPILE_LANGUAGE:C,CXX>:/bigobj>
|
$<$<COMPILE_LANGUAGE:C,CXX>:/bigobj>
|
||||||
$<$<COMPILE_LANGUAGE:C,CXX>:/Zc:strictStrings->
|
|
||||||
$<$<COMPILE_LANGUAGE:C,CXX>:/MP>
|
$<$<COMPILE_LANGUAGE:C,CXX>:/MP>
|
||||||
$<$<COMPILE_LANGUAGE:C,CXX>:/FS>
|
$<$<COMPILE_LANGUAGE:C,CXX>:/FS>
|
||||||
)
|
)
|
||||||
@@ -249,7 +284,6 @@ elseif (MSVC)
|
|||||||
add_compile_options($<$<COMPILE_LANGUAGE:C,CXX>:/utf-8>)
|
add_compile_options($<$<COMPILE_LANGUAGE:C,CXX>:/utf-8>)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
|
||||||
include(FetchContent)
|
include(FetchContent)
|
||||||
|
|
||||||
# Declare all dependencies first so CMake can download them in parallel
|
# Declare all dependencies first so CMake can download them in parallel
|
||||||
@@ -257,15 +291,43 @@ message(STATUS "dusklight: Fetching cxxopts")
|
|||||||
FetchContent_Declare(cxxopts
|
FetchContent_Declare(cxxopts
|
||||||
URL https://github.com/jarro2783/cxxopts/archive/refs/tags/v3.3.1.tar.gz
|
URL https://github.com/jarro2783/cxxopts/archive/refs/tags/v3.3.1.tar.gz
|
||||||
URL_HASH SHA256=3bfc70542c521d4b55a46429d808178916a579b28d048bd8c727ee76c39e2072
|
URL_HASH SHA256=3bfc70542c521d4b55a46429d808178916a579b28d048bd8c727ee76c39e2072
|
||||||
DOWNLOAD_EXTRACT_TIMESTAMP TRUE
|
DOWNLOAD_EXTRACT_TIMESTAMP FALSE
|
||||||
|
EXCLUDE_FROM_ALL
|
||||||
)
|
)
|
||||||
message(STATUS "dusklight: Fetching nlohmann/json")
|
message(STATUS "dusklight: Fetching nlohmann/json")
|
||||||
FetchContent_Declare(json
|
FetchContent_Declare(json
|
||||||
URL https://github.com/nlohmann/json/releases/download/v3.12.0/json.tar.xz
|
URL https://github.com/nlohmann/json/releases/download/v3.12.0/json.tar.xz
|
||||||
URL_HASH SHA256=42f6e95cad6ec532fd372391373363b62a14af6d771056dbfc86160e6dfff7aa
|
URL_HASH SHA256=42f6e95cad6ec532fd372391373363b62a14af6d771056dbfc86160e6dfff7aa
|
||||||
DOWNLOAD_EXTRACT_TIMESTAMP TRUE
|
DOWNLOAD_EXTRACT_TIMESTAMP FALSE
|
||||||
|
EXCLUDE_FROM_ALL
|
||||||
)
|
)
|
||||||
FetchContent_MakeAvailable(cxxopts json)
|
|
||||||
|
message(STATUS "dusk: Fetching miniz")
|
||||||
|
FetchContent_Declare(miniz
|
||||||
|
URL https://github.com/richgel999/miniz/releases/download/3.0.2/miniz-3.0.2.zip
|
||||||
|
DOWNLOAD_EXTRACT_TIMESTAMP TRUE
|
||||||
|
EXCLUDE_FROM_ALL
|
||||||
|
)
|
||||||
|
|
||||||
|
message(STATUS "dusk: Fetching funchook")
|
||||||
|
# cmake/patch_funchook.cmake patches funchook's cmake/capstone.cmake.in to inject a
|
||||||
|
# PATCH_COMMAND into capstone's inner ExternalProject. That PATCH_COMMAND runs
|
||||||
|
# cmake/fix_capstone_policy.cmake after capstone is cloned, which removes the
|
||||||
|
# cmake_policy(SET CMP0048 OLD) line that CMake >= 3.27 rejects.
|
||||||
|
# This is incredibly scuffed and we should probably think of a better way to do this
|
||||||
|
set(CAPSTONE_FIX_SCRIPT "${CMAKE_CURRENT_SOURCE_DIR}/cmake/fix_capstone_policy.cmake")
|
||||||
|
FetchContent_Declare(funchook
|
||||||
|
GIT_REPOSITORY https://github.com/kubo/funchook.git
|
||||||
|
GIT_TAG v1.1.3
|
||||||
|
GIT_SHALLOW TRUE
|
||||||
|
GIT_PROGRESS TRUE
|
||||||
|
PATCH_COMMAND ${CMAKE_COMMAND} -DSOURCE_DIR=<SOURCE_DIR> -P ${CMAKE_CURRENT_SOURCE_DIR}/cmake/patch_funchook.cmake
|
||||||
|
EXCLUDE_FROM_ALL
|
||||||
|
)
|
||||||
|
set(FUNCHOOK_BUILD_TESTS OFF CACHE BOOL "" FORCE)
|
||||||
|
set(FUNCHOOK_BUILD_SHARED OFF CACHE BOOL "" FORCE)
|
||||||
|
set(FUNCHOOK_INSTALL OFF CACHE BOOL "" FORCE)
|
||||||
|
FetchContent_MakeAvailable(cxxopts json miniz funchook)
|
||||||
|
|
||||||
if (DUSK_ENABLE_SENTRY_NATIVE)
|
if (DUSK_ENABLE_SENTRY_NATIVE)
|
||||||
message(STATUS "dusklight: Fetching sentry-native")
|
message(STATUS "dusklight: Fetching sentry-native")
|
||||||
@@ -313,7 +375,7 @@ else ()
|
|||||||
string(TOLOWER CMAKE_SYSTEM_NAME PLATFORM_NAME)
|
string(TOLOWER CMAKE_SYSTEM_NAME PLATFORM_NAME)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
configure_file(${CMAKE_SOURCE_DIR}/version.h.in ${CMAKE_BINARY_DIR}/version.h)
|
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/version.h.in ${CMAKE_CURRENT_BINARY_DIR}/version.h)
|
||||||
|
|
||||||
include(files.cmake)
|
include(files.cmake)
|
||||||
|
|
||||||
@@ -338,15 +400,21 @@ set(GAME_INCLUDE_DIRS
|
|||||||
libs/JSystem/include
|
libs/JSystem/include
|
||||||
libs
|
libs
|
||||||
extern/aurora/include/dolphin
|
extern/aurora/include/dolphin
|
||||||
|
extern/aurora/include
|
||||||
extern
|
extern
|
||||||
${CMAKE_BINARY_DIR})
|
${CMAKE_CURRENT_BINARY_DIR}
|
||||||
|
${miniz_SOURCE_DIR})
|
||||||
|
|
||||||
|
# Interface target for mods and sub-projects to inherit game headers/defines
|
||||||
|
add_library(dusklight_game_headers INTERFACE)
|
||||||
|
target_include_directories(dusklight_game_headers INTERFACE ${GAME_INCLUDE_DIRS})
|
||||||
|
target_compile_definitions(dusklight_game_headers INTERFACE TARGET_PC=1)
|
||||||
|
target_link_libraries(dusklight_game_headers INTERFACE TracyClient)
|
||||||
|
|
||||||
find_package(Threads REQUIRED)
|
find_package(Threads REQUIRED)
|
||||||
set(GAME_LIBS aurora::core aurora::gx aurora::gd aurora::si aurora::vi aurora::pad aurora::mtx aurora::os aurora::dvd
|
set(GAME_LIBS aurora::core aurora::gx aurora::gd aurora::si aurora::vi aurora::pad aurora::mtx aurora::os aurora::dvd
|
||||||
aurora::card freeverb cxxopts::cxxopts absl::flat_hash_map nlohmann_json::nlohmann_json TracyClient fmt::fmt
|
aurora::card freeverb cxxopts::cxxopts absl::flat_hash_map nlohmann_json::nlohmann_json TracyClient fmt::fmt funchook-static
|
||||||
Threads::Threads)
|
Threads::Threads zstd::libzstd)
|
||||||
|
|
||||||
list(APPEND GAME_LIBS libzstd_static)
|
|
||||||
|
|
||||||
if (DUSK_ENABLE_SENTRY_NATIVE)
|
if (DUSK_ENABLE_SENTRY_NATIVE)
|
||||||
list(APPEND GAME_LIBS sentry)
|
list(APPEND GAME_LIBS sentry)
|
||||||
@@ -418,6 +486,26 @@ if(ANDROID)
|
|||||||
list(APPEND GAME_COMPILE_DEFS TARGET_ANDROID=1)
|
list(APPEND GAME_COMPILE_DEFS TARGET_ANDROID=1)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
set(DUSK_ENABLE_CODE_MODS_DEFAULT OFF)
|
||||||
|
option(DUSK_ENABLE_CODE_MODS "Enable code mods" ${DUSK_ENABLE_CODE_MODS_DEFAULT})
|
||||||
|
if (DUSK_ENABLE_CODE_MODS)
|
||||||
|
if (NOT ANDROID AND NOT IOS AND NOT TVOS)
|
||||||
|
list(APPEND GAME_COMPILE_DEFS DUSK_CODE_MODS=1)
|
||||||
|
else ()
|
||||||
|
message(FATAL_ERROR "Code mods not supported on the target platform!")
|
||||||
|
endif ()
|
||||||
|
endif ()
|
||||||
|
|
||||||
|
if (DUSK_PACKAGE_INSTALL)
|
||||||
|
include(GNUInstallDirs)
|
||||||
|
list(APPEND GAME_COMPILE_DEFS DUSK_ASSET_DIR="${CMAKE_INSTALL_FULL_DATADIR}/dusklight/")
|
||||||
|
endif ()
|
||||||
|
|
||||||
|
if (DUSK_GFX_DEBUG_GROUPS)
|
||||||
|
list(APPEND GAME_COMPILE_DEFS DUSK_GFX_DEBUG_GROUPS=1)
|
||||||
|
target_compile_definitions(aurora_gx PRIVATE AURORA_GFX_DEBUG_GROUPS)
|
||||||
|
endif ()
|
||||||
|
|
||||||
# game_debug is for game code files that we know work when compiled with DEBUG=1
|
# game_debug is for game code files that we know work when compiled with DEBUG=1
|
||||||
# Of course, if building a release build, this distinction is irrelevant
|
# Of course, if building a release build, this distinction is irrelevant
|
||||||
set(GAME_DEBUG_FILES
|
set(GAME_DEBUG_FILES
|
||||||
@@ -435,7 +523,6 @@ set_source_files_properties(
|
|||||||
COMPILE_DEFINITIONS "$<$<CONFIG:Debug>:DEBUG=1>;$<$<CONFIG:Debug>:PARTIAL_DEBUG=1>"
|
COMPILE_DEFINITIONS "$<$<CONFIG:Debug>:DEBUG=1>;$<$<CONFIG:Debug>:PARTIAL_DEBUG=1>"
|
||||||
)
|
)
|
||||||
|
|
||||||
# game_base is for all other game code files
|
|
||||||
set(GAME_BASE_FILES
|
set(GAME_BASE_FILES
|
||||||
${DOLZEL_FILES}
|
${DOLZEL_FILES}
|
||||||
${Z2AUDIOLIB_FILES}
|
${Z2AUDIOLIB_FILES}
|
||||||
@@ -452,6 +539,7 @@ set_source_files_properties(
|
|||||||
foreach(jsystem_lib IN LISTS JSYSTEM_LIBRARIES)
|
foreach(jsystem_lib IN LISTS JSYSTEM_LIBRARIES)
|
||||||
target_compile_definitions(${jsystem_lib} PRIVATE
|
target_compile_definitions(${jsystem_lib} PRIVATE
|
||||||
${GAME_COMPILE_DEFS}
|
${GAME_COMPILE_DEFS}
|
||||||
|
DUSK_BUILDING_GAME=1
|
||||||
$<$<CONFIG:Debug>:DEBUG=1>
|
$<$<CONFIG:Debug>:DEBUG=1>
|
||||||
$<$<CONFIG:Debug>:PARTIAL_DEBUG=1>
|
$<$<CONFIG:Debug>:PARTIAL_DEBUG=1>
|
||||||
)
|
)
|
||||||
@@ -467,21 +555,61 @@ if (CMAKE_CXX_LINK_GROUP_USING_RESCAN_SUPPORTED OR CMAKE_LINK_GROUP_USING_RESCAN
|
|||||||
set(JSYSTEM_LINK_LIBRARIES "$<LINK_GROUP:RESCAN,${JSYSTEM_LIBRARIES}>")
|
set(JSYSTEM_LINK_LIBRARIES "$<LINK_GROUP:RESCAN,${JSYSTEM_LIBRARIES}>")
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
set(DUSK_FILES src/dusk/main.cpp ${GAME_BASE_FILES} ${GAME_DEBUG_FILES})
|
set(DUSK_FILES src/dusk/main.cpp ${GAME_BASE_FILES} ${GAME_DEBUG_FILES} ${miniz_SOURCE_DIR}/miniz.c)
|
||||||
if(ANDROID)
|
if(ANDROID)
|
||||||
add_library(dusklight SHARED ${DUSK_FILES})
|
add_library(dusklight SHARED ${DUSK_FILES})
|
||||||
set_target_properties(dusklight PROPERTIES OUTPUT_NAME main)
|
set_target_properties(dusklight PROPERTIES OUTPUT_NAME main)
|
||||||
|
set(DUSK_MAIN_TARGET dusklight)
|
||||||
|
elseif(WIN32)
|
||||||
|
add_library(dusklight_game SHARED ${DUSK_FILES})
|
||||||
|
set_target_properties(dusklight_game PROPERTIES
|
||||||
|
WINDOWS_EXPORT_ALL_SYMBOLS ${DUSK_ENABLE_CODE_MODS}
|
||||||
|
OUTPUT_NAME dusklight
|
||||||
|
PDB_NAME dusklight_game)
|
||||||
|
|
||||||
|
# rmlui_core uses its own PCH which creates a duplicate PCH marker symbol when linked
|
||||||
|
# Disabling rmlui's PCH removes the conflicting marker and lets the link succeed
|
||||||
|
if (MSVC AND TARGET rmlui_core AND DUSK_ENABLE_CODE_MODS)
|
||||||
|
set_target_properties(rmlui_core PROPERTIES DISABLE_PRECOMPILE_HEADERS ON)
|
||||||
|
endif ()
|
||||||
|
|
||||||
|
add_executable(dusklight WIN32 src/dusk/launcher_win32.cpp)
|
||||||
|
target_link_libraries(dusklight PRIVATE dusklight_game)
|
||||||
|
target_include_directories(dusklight PRIVATE include)
|
||||||
|
set(DUSK_MAIN_TARGET dusklight_game)
|
||||||
else ()
|
else ()
|
||||||
add_executable(dusklight ${DUSK_FILES})
|
add_executable(dusklight ${DUSK_FILES})
|
||||||
|
set(DUSK_MAIN_TARGET dusklight)
|
||||||
|
endif ()
|
||||||
|
if (ENABLE_ASAN)
|
||||||
|
target_sources(${DUSK_MAIN_TARGET} PRIVATE src/dusk/asan_options.c)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
target_compile_definitions(dusklight PRIVATE ${GAME_COMPILE_DEFS})
|
if (WIN32 AND TARGET imgui)
|
||||||
target_include_directories(dusklight PRIVATE ${GAME_INCLUDE_DIRS})
|
target_compile_definitions(imgui PRIVATE "IMGUI_API=__declspec(dllexport)")
|
||||||
target_link_libraries(dusklight PRIVATE aurora::main ${GAME_LIBS} ${JSYSTEM_LINK_LIBRARIES})
|
target_sources(${DUSK_MAIN_TARGET} PRIVATE $<TARGET_OBJECTS:imgui>)
|
||||||
target_precompile_headers(dusklight PRIVATE "$<$<COMPILE_LANGUAGE:CXX>:${CMAKE_SOURCE_DIR}/include/dusk_pch.hpp>")
|
endif ()
|
||||||
|
|
||||||
|
target_compile_definitions(${DUSK_MAIN_TARGET} PRIVATE ${GAME_COMPILE_DEFS} DUSK_BUILDING_GAME=1)
|
||||||
|
target_include_directories(${DUSK_MAIN_TARGET} PRIVATE ${GAME_INCLUDE_DIRS})
|
||||||
|
target_link_libraries(${DUSK_MAIN_TARGET} PRIVATE aurora::main ${GAME_LIBS} ${JSYSTEM_LINK_LIBRARIES})
|
||||||
|
target_precompile_headers(${DUSK_MAIN_TARGET} PRIVATE "$<$<COMPILE_LANGUAGE:CXX>:${CMAKE_CURRENT_LIST_DIR}/include/dusk_pch.hpp>")
|
||||||
|
|
||||||
|
if(WIN32)
|
||||||
|
target_link_libraries(${DUSK_MAIN_TARGET} PRIVATE Psapi)
|
||||||
|
endif()
|
||||||
|
if(CMAKE_SYSTEM_NAME STREQUAL Linux)
|
||||||
|
target_link_libraries(${DUSK_MAIN_TARGET} PRIVATE dl)
|
||||||
|
endif()
|
||||||
|
if(APPLE)
|
||||||
|
target_link_options(${DUSK_MAIN_TARGET} PRIVATE -Wl,-export_dynamic)
|
||||||
|
elseif(UNIX AND NOT ANDROID)
|
||||||
|
target_link_options(${DUSK_MAIN_TARGET} PRIVATE -rdynamic)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (TARGET crashpad_handler)
|
if (TARGET crashpad_handler)
|
||||||
add_dependencies(dusklight crashpad_handler)
|
add_dependencies(${DUSK_MAIN_TARGET} crashpad_handler)
|
||||||
add_custom_command(TARGET dusklight POST_BUILD
|
add_custom_command(TARGET ${DUSK_MAIN_TARGET} POST_BUILD
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||||
"$<TARGET_FILE:crashpad_handler>"
|
"$<TARGET_FILE:crashpad_handler>"
|
||||||
"$<TARGET_FILE_DIR:dusklight>"
|
"$<TARGET_FILE_DIR:dusklight>"
|
||||||
@@ -492,7 +620,7 @@ endif ()
|
|||||||
if (ANDROID)
|
if (ANDROID)
|
||||||
# SDLActivity loads SDL_main via dlsym on Android. Since aurora::main is a static
|
# SDLActivity loads SDL_main via dlsym on Android. Since aurora::main is a static
|
||||||
# archive, force an undefined reference so the linker keeps the SDL_main object.
|
# archive, force an undefined reference so the linker keeps the SDL_main object.
|
||||||
target_link_options(dusklight PRIVATE "-Wl,-u,SDL_main")
|
target_link_options(${DUSK_MAIN_TARGET} PRIVATE "-Wl,-u,SDL_main")
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
if (CMAKE_SYSTEM_NAME STREQUAL Linux)
|
if (CMAKE_SYSTEM_NAME STREQUAL Linux)
|
||||||
@@ -502,7 +630,7 @@ endif ()
|
|||||||
if (NOT APPLE)
|
if (NOT APPLE)
|
||||||
add_custom_command(TARGET dusklight POST_BUILD
|
add_custom_command(TARGET dusklight POST_BUILD
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy_directory
|
COMMAND ${CMAKE_COMMAND} -E copy_directory
|
||||||
"${CMAKE_SOURCE_DIR}/res"
|
"${CMAKE_CURRENT_SOURCE_DIR}/res"
|
||||||
"$<TARGET_FILE_DIR:dusklight>/res"
|
"$<TARGET_FILE_DIR:dusklight>/res"
|
||||||
COMMENT "Copying resources"
|
COMMENT "Copying resources"
|
||||||
)
|
)
|
||||||
@@ -530,13 +658,13 @@ if (WIN32)
|
|||||||
configure_file(${DUSK_WINDOWS_RESOURCE_DIR}/dusklight.rc.in ${DUSK_WINDOWS_RC} @ONLY)
|
configure_file(${DUSK_WINDOWS_RESOURCE_DIR}/dusklight.rc.in ${DUSK_WINDOWS_RC} @ONLY)
|
||||||
|
|
||||||
target_sources(dusklight PRIVATE ${DUSK_WINDOWS_ICON_ICO} ${DUSK_WINDOWS_RC})
|
target_sources(dusklight PRIVATE ${DUSK_WINDOWS_ICON_ICO} ${DUSK_WINDOWS_RC})
|
||||||
set_target_properties(dusklight PROPERTIES WIN32_EXECUTABLE TRUE)
|
|
||||||
|
|
||||||
if (MSVC)
|
if (MSVC)
|
||||||
target_link_options(dusklight PRIVATE /MANIFEST:NO)
|
target_link_options(dusklight PRIVATE /MANIFEST:NO)
|
||||||
endif ()
|
endif ()
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
include(cmake/DuskModSDK.cmake)
|
||||||
|
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
if (IOS)
|
if (IOS)
|
||||||
set(DUSK_RESOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios)
|
set(DUSK_RESOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/platforms/ios)
|
||||||
@@ -544,6 +672,7 @@ if (APPLE)
|
|||||||
set(DUSK_RESOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/platforms/tvos)
|
set(DUSK_RESOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/platforms/tvos)
|
||||||
else ()
|
else ()
|
||||||
set(DUSK_RESOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/platforms/macos)
|
set(DUSK_RESOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/platforms/macos)
|
||||||
|
set(DUSK_ENTITLEMENTS ${DUSK_RESOURCE_DIR}/Dusk.entitlements)
|
||||||
endif ()
|
endif ()
|
||||||
set(DUSK_INFO_PLIST ${DUSK_RESOURCE_DIR}/Info.plist.in)
|
set(DUSK_INFO_PLIST ${DUSK_RESOURCE_DIR}/Info.plist.in)
|
||||||
file(GLOB_RECURSE DUSK_RESOURCE_FILES
|
file(GLOB_RECURSE DUSK_RESOURCE_FILES
|
||||||
@@ -574,6 +703,8 @@ if (APPLE)
|
|||||||
OUTPUT_NAME Dusklight
|
OUTPUT_NAME Dusklight
|
||||||
XCODE_ATTRIBUTE_CODE_SIGNING_ALLOWED "YES"
|
XCODE_ATTRIBUTE_CODE_SIGNING_ALLOWED "YES"
|
||||||
XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED "YES"
|
XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED "YES"
|
||||||
|
XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS ${DUSK_ENTITLEMENTS}
|
||||||
|
XCODE_ATTRIBUTE_ENABLE_HARDENED_RUNTIME "YES"
|
||||||
)
|
)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
@@ -593,7 +724,11 @@ if (IOS)
|
|||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
include(extern/aurora/cmake/AuroraCopyRuntimeDLLs.cmake)
|
include(extern/aurora/cmake/AuroraCopyRuntimeDLLs.cmake)
|
||||||
aurora_copy_runtime_dlls(dusklight)
|
if(WIN32)
|
||||||
|
aurora_copy_runtime_dlls(dusklight dusklight_game)
|
||||||
|
else()
|
||||||
|
aurora_copy_runtime_dlls(dusklight)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (DUSK_SELECTED_OPT)
|
if (DUSK_SELECTED_OPT)
|
||||||
if (CMAKE_CXX_COMPILER_FRONTEND_VARIANT STREQUAL "MSVC")
|
if (CMAKE_CXX_COMPILER_FRONTEND_VARIANT STREQUAL "MSVC")
|
||||||
@@ -632,16 +767,42 @@ function(get_target_prefix target result_var)
|
|||||||
endif ()
|
endif ()
|
||||||
endfunction()
|
endfunction()
|
||||||
list(APPEND BINARY_TARGETS dusklight)
|
list(APPEND BINARY_TARGETS dusklight)
|
||||||
|
if(WIN32)
|
||||||
|
list(APPEND BINARY_TARGETS dusklight_game)
|
||||||
|
endif()
|
||||||
set(EXTRA_TARGETS "")
|
set(EXTRA_TARGETS "")
|
||||||
if (TARGET crashpad_handler)
|
if (TARGET crashpad_handler)
|
||||||
list(APPEND EXTRA_TARGETS crashpad_handler)
|
list(APPEND EXTRA_TARGETS crashpad_handler)
|
||||||
endif ()
|
endif ()
|
||||||
install(TARGETS ${BINARY_TARGETS} ${EXTRA_TARGETS} DESTINATION ${CMAKE_INSTALL_PREFIX})
|
if (WIN32)
|
||||||
|
# Install the launcher and game DLL, but skip the DLL import library.
|
||||||
|
if (DUSK_PACKAGE_INSTALL)
|
||||||
|
install(TARGETS ${BINARY_TARGETS} ${EXTRA_TARGETS}
|
||||||
|
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||||
|
LIBRARY DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||||
|
BUNDLE DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||||
|
)
|
||||||
|
else ()
|
||||||
|
install(TARGETS ${BINARY_TARGETS} ${EXTRA_TARGETS}
|
||||||
|
RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}
|
||||||
|
LIBRARY DESTINATION ${CMAKE_INSTALL_PREFIX}
|
||||||
|
BUNDLE DESTINATION ${CMAKE_INSTALL_PREFIX}
|
||||||
|
)
|
||||||
|
endif ()
|
||||||
|
elseif (DUSK_PACKAGE_INSTALL)
|
||||||
|
install(TARGETS ${BINARY_TARGETS} ${EXTRA_TARGETS} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||||
|
else ()
|
||||||
|
install(TARGETS ${BINARY_TARGETS} ${EXTRA_TARGETS} DESTINATION ${CMAKE_INSTALL_PREFIX})
|
||||||
|
endif ()
|
||||||
aurora_install_runtime_dlls(dusklight ${CMAKE_INSTALL_PREFIX})
|
aurora_install_runtime_dlls(dusklight ${CMAKE_INSTALL_PREFIX})
|
||||||
if (NOT APPLE)
|
if (NOT APPLE)
|
||||||
install(DIRECTORY ${CMAKE_SOURCE_DIR}/res DESTINATION ${CMAKE_INSTALL_PREFIX})
|
if (DUSK_PACKAGE_INSTALL)
|
||||||
|
install(DIRECTORY ${CMAKE_SOURCE_DIR}/res DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/dusklight)
|
||||||
|
else()
|
||||||
|
install(DIRECTORY ${CMAKE_SOURCE_DIR}/res DESTINATION ${CMAKE_INSTALL_PREFIX})
|
||||||
|
endif()
|
||||||
endif ()
|
endif ()
|
||||||
if (CMAKE_BUILD_TYPE STREQUAL Debug OR CMAKE_BUILD_TYPE STREQUAL RelWithDebInfo)
|
if (CMAKE_BUILD_TYPE STREQUAL Debug OR CMAKE_BUILD_TYPE STREQUAL RelWithDebInfo AND NOT DUSK_PACKAGE_INSTALL)
|
||||||
set(DEBUG_FILES_LIST "")
|
set(DEBUG_FILES_LIST "")
|
||||||
foreach (target IN LISTS BINARY_TARGETS EXTRA_TARGETS)
|
foreach (target IN LISTS BINARY_TARGETS EXTRA_TARGETS)
|
||||||
get_target_output_name(${target} output_name)
|
get_target_output_name(${target} output_name)
|
||||||
@@ -690,3 +851,7 @@ foreach (target IN LISTS BINARY_TARGETS)
|
|||||||
endif ()
|
endif ()
|
||||||
endforeach ()
|
endforeach ()
|
||||||
endforeach ()
|
endforeach ()
|
||||||
|
|
||||||
|
if (DUSK_ENABLE_CODE_MODS)
|
||||||
|
add_subdirectory(tools/mod_test)
|
||||||
|
endif ()
|
||||||
|
|||||||
+116
-21
@@ -19,7 +19,19 @@
|
|||||||
"hidden": true,
|
"hidden": true,
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
|
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
|
||||||
"CMAKE_MSVC_RUNTIME_LIBRARY": "MultiThreaded"
|
"CMAKE_MSVC_RUNTIME_LIBRARY": "MultiThreadedDLL"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "release",
|
||||||
|
"hidden": true,
|
||||||
|
"cacheVariables": {
|
||||||
|
"CMAKE_BUILD_TYPE": "Release",
|
||||||
|
"CMAKE_MSVC_RUNTIME_LIBRARY": "MultiThreadedDLL",
|
||||||
|
"CMAKE_INTERPROCEDURAL_OPTIMIZATION": {
|
||||||
|
"type": "BOOL",
|
||||||
|
"value": true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -40,12 +52,26 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "asan",
|
||||||
|
"hidden": true,
|
||||||
|
"cacheVariables": {
|
||||||
|
"ENABLE_ASAN": {
|
||||||
|
"type": "BOOL",
|
||||||
|
"value": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "linux-default",
|
"name": "linux-default",
|
||||||
"displayName": "Linux (default)",
|
"displayName": "Linux (default)",
|
||||||
"generator": "Ninja",
|
"generator": "Ninja",
|
||||||
"binaryDir": "${sourceDir}/build/${presetName}",
|
"binaryDir": "${sourceDir}/build/${presetName}",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
|
"BUILD_SHARED_LIBS": {
|
||||||
|
"type": "BOOL",
|
||||||
|
"value": false
|
||||||
|
},
|
||||||
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/install"
|
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/install"
|
||||||
},
|
},
|
||||||
"vendor": {
|
"vendor": {
|
||||||
@@ -67,6 +93,15 @@
|
|||||||
"linux-default"
|
"linux-default"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "linux-default-debug-asan",
|
||||||
|
"displayName": "Linux (default) Debug ASan",
|
||||||
|
"inherits": [
|
||||||
|
"debug",
|
||||||
|
"linux-default",
|
||||||
|
"asan"
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "linux-default-relwithdebinfo",
|
"name": "linux-default-relwithdebinfo",
|
||||||
"displayName": "Linux (default) RelWithDebInfo",
|
"displayName": "Linux (default) RelWithDebInfo",
|
||||||
@@ -94,6 +129,15 @@
|
|||||||
"linux-clang"
|
"linux-clang"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "linux-clang-debug-asan",
|
||||||
|
"displayName": "Linux (Clang) Debug ASan",
|
||||||
|
"inherits": [
|
||||||
|
"debug",
|
||||||
|
"linux-clang",
|
||||||
|
"asan"
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "linux-clang-relwithdebinfo",
|
"name": "linux-clang-relwithdebinfo",
|
||||||
"displayName": "Linux (Clang) RelWithDebInfo",
|
"displayName": "Linux (Clang) RelWithDebInfo",
|
||||||
@@ -114,7 +158,11 @@
|
|||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"CMAKE_C_COMPILER": "cl",
|
"CMAKE_C_COMPILER": "cl",
|
||||||
"CMAKE_CXX_COMPILER": "cl",
|
"CMAKE_CXX_COMPILER": "cl",
|
||||||
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/install"
|
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/install",
|
||||||
|
"CMAKE_DISABLE_FIND_PACKAGE_PkgConfig": {
|
||||||
|
"type": "BOOL",
|
||||||
|
"value": true
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"vendor": {
|
"vendor": {
|
||||||
"microsoft.com/VisualStudioSettings/CMake/1.0": {
|
"microsoft.com/VisualStudioSettings/CMake/1.0": {
|
||||||
@@ -132,6 +180,15 @@
|
|||||||
"windows-msvc"
|
"windows-msvc"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "windows-msvc-debug-asan",
|
||||||
|
"displayName": "Windows (MSVC) Debug ASan",
|
||||||
|
"inherits": [
|
||||||
|
"debug",
|
||||||
|
"windows-msvc",
|
||||||
|
"asan"
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "windows-msvc-relwithdebinfo",
|
"name": "windows-msvc-relwithdebinfo",
|
||||||
"displayName": "Windows (MSVC) RelWithDebInfo",
|
"displayName": "Windows (MSVC) RelWithDebInfo",
|
||||||
@@ -201,6 +258,10 @@
|
|||||||
"generator": "Ninja",
|
"generator": "Ninja",
|
||||||
"binaryDir": "${sourceDir}/build/${presetName}",
|
"binaryDir": "${sourceDir}/build/${presetName}",
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
|
"BUILD_SHARED_LIBS": {
|
||||||
|
"type": "BOOL",
|
||||||
|
"value": false
|
||||||
|
},
|
||||||
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/install"
|
"CMAKE_INSTALL_PREFIX": "${sourceDir}/build/install"
|
||||||
},
|
},
|
||||||
"vendor": {
|
"vendor": {
|
||||||
@@ -219,6 +280,15 @@
|
|||||||
"macos-default"
|
"macos-default"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "macos-default-debug-asan",
|
||||||
|
"displayName": "macOS (default) Debug ASan",
|
||||||
|
"inherits": [
|
||||||
|
"debug",
|
||||||
|
"macos-default",
|
||||||
|
"asan"
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "macos-default-relwithdebinfo",
|
"name": "macos-default-relwithdebinfo",
|
||||||
"displayName": "macOS (default) RelWithDebInfo",
|
"displayName": "macOS (default) RelWithDebInfo",
|
||||||
@@ -284,24 +354,21 @@
|
|||||||
"type": "BOOL",
|
"type": "BOOL",
|
||||||
"value": false
|
"value": false
|
||||||
},
|
},
|
||||||
|
"ENABLE_ARC": {
|
||||||
|
"type": "BOOL",
|
||||||
|
"value": false
|
||||||
|
},
|
||||||
"Rust_CARGO_TARGET": "aarch64-apple-tvos",
|
"Rust_CARGO_TARGET": "aarch64-apple-tvos",
|
||||||
"Rust_TOOLCHAIN": "nightly",
|
"Rust_TOOLCHAIN": "nightly",
|
||||||
"BUILD_SHARED_LIBS": {
|
"BUILD_SHARED_LIBS": {
|
||||||
"type": "BOOL",
|
"type": "BOOL",
|
||||||
"value": false
|
"value": false
|
||||||
},
|
},
|
||||||
"CMAKE_DISABLE_FIND_PACKAGE_BZip2": {
|
"CMAKE_DISABLE_FIND_PACKAGE_PkgConfig": {
|
||||||
"type": "BOOL",
|
"type": "BOOL",
|
||||||
"value": true
|
"value": true
|
||||||
},
|
},
|
||||||
"CMAKE_DISABLE_FIND_PACKAGE_LibLZMA": {
|
"CMAKE_IGNORE_PREFIX_PATH": "/opt/homebrew"
|
||||||
"type": "BOOL",
|
|
||||||
"value": true
|
|
||||||
},
|
|
||||||
"CMAKE_DISABLE_FIND_PACKAGE_zstd": {
|
|
||||||
"type": "BOOL",
|
|
||||||
"value": true
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"vendor": {
|
"vendor": {
|
||||||
"microsoft.com/VisualStudioSettings/CMake/1.0": {
|
"microsoft.com/VisualStudioSettings/CMake/1.0": {
|
||||||
@@ -327,8 +394,14 @@
|
|||||||
"type": "BOOL",
|
"type": "BOOL",
|
||||||
"value": false
|
"value": false
|
||||||
},
|
},
|
||||||
"AURORA_SDL3_VERSION": "3.4.8",
|
"CMAKE_DISABLE_FIND_PACKAGE_PkgConfig": {
|
||||||
"AURORA_SDL3_REF": "refs/tags/release-3.4.8"
|
"type": "BOOL",
|
||||||
|
"value": true
|
||||||
|
},
|
||||||
|
"CMAKE_DISABLE_FIND_PACKAGE_zstd": {
|
||||||
|
"type": "BOOL",
|
||||||
|
"value": true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -356,7 +429,8 @@
|
|||||||
"hidden": true,
|
"hidden": true,
|
||||||
"inherits": [
|
"inherits": [
|
||||||
"android-base",
|
"android-base",
|
||||||
"ci"
|
"ci",
|
||||||
|
"release"
|
||||||
],
|
],
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"DUSK_ENABLE_SENTRY_NATIVE": {
|
"DUSK_ENABLE_SENTRY_NATIVE": {
|
||||||
@@ -384,7 +458,8 @@
|
|||||||
"ci"
|
"ci"
|
||||||
],
|
],
|
||||||
"cacheVariables": {
|
"cacheVariables": {
|
||||||
"AURORA_SDL3_PROVIDER": "vendor"
|
"AURORA_SDL3_PROVIDER": "vendor",
|
||||||
|
"CMAKE_LINKER_TYPE": "MOLD"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -413,12 +488,8 @@
|
|||||||
"type": "BOOL",
|
"type": "BOOL",
|
||||||
"value": true
|
"value": true
|
||||||
},
|
},
|
||||||
"CMAKE_OSX_DEPLOYMENT_TARGET": "11.0",
|
"CMAKE_OSX_DEPLOYMENT_TARGET": "12.0",
|
||||||
"CMAKE_IGNORE_PREFIX_PATH": "/opt/homebrew",
|
"CMAKE_IGNORE_PREFIX_PATH": "/opt/homebrew"
|
||||||
"BUILD_SHARED_LIBS": {
|
|
||||||
"type": "BOOL",
|
|
||||||
"value": false
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -508,6 +579,12 @@
|
|||||||
"description": "Linux (default) debug build",
|
"description": "Linux (default) debug build",
|
||||||
"displayName": "Linux (default) Debug"
|
"displayName": "Linux (default) Debug"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "linux-default-debug-asan",
|
||||||
|
"configurePreset": "linux-default-debug-asan",
|
||||||
|
"description": "Linux (default) debug build with AddressSanitizer",
|
||||||
|
"displayName": "Linux (default) Debug ASan"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "linux-default-relwithdebinfo",
|
"name": "linux-default-relwithdebinfo",
|
||||||
"configurePreset": "linux-default-relwithdebinfo",
|
"configurePreset": "linux-default-relwithdebinfo",
|
||||||
@@ -520,6 +597,12 @@
|
|||||||
"description": "Linux (Clang) debug build",
|
"description": "Linux (Clang) debug build",
|
||||||
"displayName": "Linux (Clang) Debug"
|
"displayName": "Linux (Clang) Debug"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "linux-clang-debug-asan",
|
||||||
|
"configurePreset": "linux-clang-debug-asan",
|
||||||
|
"description": "Linux (Clang) debug build with AddressSanitizer",
|
||||||
|
"displayName": "Linux (Clang) Debug ASan"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "linux-clang-relwithdebinfo",
|
"name": "linux-clang-relwithdebinfo",
|
||||||
"configurePreset": "linux-clang-relwithdebinfo",
|
"configurePreset": "linux-clang-relwithdebinfo",
|
||||||
@@ -532,6 +615,12 @@
|
|||||||
"description": "macOS debug build",
|
"description": "macOS debug build",
|
||||||
"displayName": "macOS Debug"
|
"displayName": "macOS Debug"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "macos-default-debug-asan",
|
||||||
|
"configurePreset": "macos-default-debug-asan",
|
||||||
|
"description": "macOS debug build with AddressSanitizer",
|
||||||
|
"displayName": "macOS Debug ASan"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "macos-default-relwithdebinfo",
|
"name": "macos-default-relwithdebinfo",
|
||||||
"configurePreset": "macos-default-relwithdebinfo",
|
"configurePreset": "macos-default-relwithdebinfo",
|
||||||
@@ -589,6 +678,12 @@
|
|||||||
"description": "Windows (MSVC) debug build",
|
"description": "Windows (MSVC) debug build",
|
||||||
"displayName": "Windows (MSVC) Debug"
|
"displayName": "Windows (MSVC) Debug"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "windows-msvc-debug-asan",
|
||||||
|
"configurePreset": "windows-msvc-debug-asan",
|
||||||
|
"description": "Windows (MSVC) debug build with AddressSanitizer",
|
||||||
|
"displayName": "Windows (MSVC) Debug ASan"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "windows-msvc-relwithdebinfo",
|
"name": "windows-msvc-relwithdebinfo",
|
||||||
"configurePreset": "windows-msvc-relwithdebinfo",
|
"configurePreset": "windows-msvc-relwithdebinfo",
|
||||||
|
|||||||
@@ -0,0 +1,49 @@
|
|||||||
|
# add_dusk_mod(<target> SOURCES <file>... MOD_JSON <mod.json> [RES_DIR <res>])
|
||||||
|
set(DUSK_MODS_OUTPUT_DIR "${CMAKE_SOURCE_DIR}/mods" CACHE PATH "Directory to write .dusk packages into")
|
||||||
|
|
||||||
|
function(add_dusk_mod target_name)
|
||||||
|
cmake_parse_arguments(ARG "" "MOD_JSON;RES_DIR" "SOURCES" ${ARGN})
|
||||||
|
if(NOT ARG_MOD_JSON)
|
||||||
|
message(FATAL_ERROR "add_dusk_mod: MOD_JSON is required")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
add_library(${target_name} SHARED ${ARG_SOURCES})
|
||||||
|
set_target_properties(${target_name} PROPERTIES PREFIX "" WINDOWS_EXPORT_ALL_SYMBOLS ON)
|
||||||
|
target_compile_features(${target_name} PRIVATE cxx_std_20)
|
||||||
|
target_link_libraries(${target_name} PRIVATE dusklight_game_headers)
|
||||||
|
|
||||||
|
if(APPLE)
|
||||||
|
target_link_options(${target_name} PRIVATE -undefined dynamic_lookup)
|
||||||
|
elseif(UNIX)
|
||||||
|
target_link_options(${target_name} PRIVATE -Wl,--allow-shlib-undefined)
|
||||||
|
elseif(WIN32)
|
||||||
|
target_link_libraries(${target_name} PRIVATE dusklight_game)
|
||||||
|
if(MSVC)
|
||||||
|
target_link_options(${target_name} PRIVATE /INCREMENTAL:NO)
|
||||||
|
set_target_properties(${target_name} PROPERTIES MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>DLL")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
|
||||||
|
set(_stage "${CMAKE_CURRENT_BINARY_DIR}/${target_name}_stage")
|
||||||
|
set(_out "${DUSK_MODS_OUTPUT_DIR}/${target_name}.dusk")
|
||||||
|
file(MAKE_DIRECTORY "${_stage}") # must exist before POST_BUILD on Windows
|
||||||
|
|
||||||
|
set(_zip_args "$<TARGET_FILE_NAME:${target_name}>" mod.json)
|
||||||
|
set(_extra_cmds "")
|
||||||
|
if(ARG_RES_DIR)
|
||||||
|
list(APPEND _zip_args res)
|
||||||
|
set(_extra_cmds COMMAND ${CMAKE_COMMAND} -E copy_directory
|
||||||
|
"${CMAKE_CURRENT_SOURCE_DIR}/${ARG_RES_DIR}" "${_stage}/res")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
add_custom_command(TARGET ${target_name} POST_BUILD
|
||||||
|
COMMAND ${CMAKE_COMMAND} -E make_directory "${_stage}" "${DUSK_MODS_OUTPUT_DIR}"
|
||||||
|
COMMAND ${CMAKE_COMMAND} -E copy_if_different "$<TARGET_FILE:${target_name}>" "${_stage}/$<TARGET_FILE_NAME:${target_name}>"
|
||||||
|
COMMAND ${CMAKE_COMMAND} -E copy_if_different "${CMAKE_CURRENT_SOURCE_DIR}/${ARG_MOD_JSON}" "${_stage}/mod.json"
|
||||||
|
${_extra_cmds}
|
||||||
|
COMMAND ${CMAKE_COMMAND} -E tar cvf "${_out}" --format=zip ${_zip_args}
|
||||||
|
WORKING_DIRECTORY "${_stage}"
|
||||||
|
COMMENT "Packaging ${target_name} -> ${_out}"
|
||||||
|
)
|
||||||
|
endfunction()
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
# Patches capstone's CMakeLists.txt for compatibility with CMake >= 4.0:
|
||||||
|
# - Bumps cmake_minimum_required to 3.10 (CMake >= 4.0 dropped < 3.5 support; < 3.10 warns)
|
||||||
|
# - Removes cmake_policy(SET CMP0048 OLD) (rejected by CMake >= 3.27)
|
||||||
|
file(READ "${DIR}/CMakeLists.txt" _content)
|
||||||
|
string(REGEX REPLACE
|
||||||
|
"cmake_minimum_required[ \t]*\\([ \t]*VERSION[ \t]+[0-9]+\\.[0-9]+(\\.[0-9]+)?[ \t]*\\)"
|
||||||
|
"cmake_minimum_required(VERSION 3.10)"
|
||||||
|
_content "${_content}")
|
||||||
|
string(REGEX REPLACE
|
||||||
|
"cmake_policy[ \t]*\\([ \t]*SET[ \t]+CMP0048[ \t]+OLD[ \t]*\\)"
|
||||||
|
"# cmake_policy(SET CMP0048 OLD)"
|
||||||
|
_content "${_content}")
|
||||||
|
file(WRITE "${DIR}/CMakeLists.txt" "${_content}")
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
file(READ "${SOURCE_DIR}/cmake/capstone.cmake.in" _content)
|
||||||
|
|
||||||
|
# Insert PATCH_COMMAND before CONFIGURE_COMMAND in the ExternalProject_Add.
|
||||||
|
# Bracket args prevent cmake from substituting ${...} while writing this file.
|
||||||
|
string(REPLACE
|
||||||
|
" CONFIGURE_COMMAND \"\""
|
||||||
|
[=[ PATCH_COMMAND "${CMAKE_COMMAND}" -DDIR=${CMAKE_CURRENT_BINARY_DIR}/capstone-src -P "${CAPSTONE_FIX_SCRIPT}"
|
||||||
|
CONFIGURE_COMMAND ""]=]
|
||||||
|
_content "${_content}")
|
||||||
|
|
||||||
|
file(WRITE "${SOURCE_DIR}/cmake/capstone.cmake.in" "${_content}")
|
||||||
@@ -180,6 +180,7 @@ cmake --build --preset macos-default-relwithdebinfo
|
|||||||
Alternate presets available:
|
Alternate presets available:
|
||||||
|
|
||||||
* `macos-default-debug`: Clang, Debug
|
* `macos-default-debug`: Clang, Debug
|
||||||
|
* `macos-default-debug-asan`: Clang, Debug, AddressSanitizer
|
||||||
|
|
||||||
**ninja (Linux)**
|
**ninja (Linux)**
|
||||||
|
|
||||||
@@ -191,8 +192,10 @@ cmake --build --preset linux-default-relwithdebinfo
|
|||||||
Alternate presets available:
|
Alternate presets available:
|
||||||
|
|
||||||
* `linux-default-debug`: GCC, Debug
|
* `linux-default-debug`: GCC, Debug
|
||||||
|
* `linux-default-debug-asan`: GCC, Debug, AddressSanitizer
|
||||||
* `linux-clang-relwithdebinfo`: Clang, RelWithDebInfo
|
* `linux-clang-relwithdebinfo`: Clang, RelWithDebInfo
|
||||||
* `linux-clang-debug`: Clang, Debug
|
* `linux-clang-debug`: Clang, Debug
|
||||||
|
* `linux-clang-debug-asan`: Clang, Debug, AddressSanitizer
|
||||||
|
|
||||||
**ninja (Windows)**
|
**ninja (Windows)**
|
||||||
|
|
||||||
@@ -204,6 +207,7 @@ cmake --build --preset windows-msvc-relwithdebinfo
|
|||||||
Alternate presets available:
|
Alternate presets available:
|
||||||
|
|
||||||
* `windows-msvc-debug`: MSVC, Debug
|
* `windows-msvc-debug`: MSVC, Debug
|
||||||
|
* `windows-msvc-debug-asan`: MSVC, Debug, AddressSanitizer
|
||||||
* `windows-clang-relwithdebinfo`: Clang-cl, RelWithDebInfo
|
* `windows-clang-relwithdebinfo`: Clang-cl, RelWithDebInfo
|
||||||
* `windows-clang-debug`: Clang-cl, Debug
|
* `windows-clang-debug`: Clang-cl, Debug
|
||||||
|
|
||||||
|
|||||||
+351
@@ -0,0 +1,351 @@
|
|||||||
|
# Dusk Mod API
|
||||||
|
|
||||||
|
Mods are shared libraries packaged into a `.dusk` zip archive. The loader scans the `mods/` directory at startup, extracts each library, and calls your exports each frame.
|
||||||
|
|
||||||
|
## Table of Contents
|
||||||
|
|
||||||
|
1. [Getting Started](#getting-started)
|
||||||
|
2. [mod.json](#modjson)
|
||||||
|
3. [Required Exports](#required-exports)
|
||||||
|
4. [DuskModAPI Reference](#duskmodapi-reference)
|
||||||
|
5. [Logging](#logging)
|
||||||
|
6. [Loading Resources](#loading-resources)
|
||||||
|
7. [ImGui Integration](#imgui-integration)
|
||||||
|
8. [Hooking Game Functions](#hooking-game-functions)
|
||||||
|
- [Pre-hooks](#pre-hooks)
|
||||||
|
- [Post-hooks](#post-hooks)
|
||||||
|
- [Replace hooks](#replace-hooks)
|
||||||
|
- [Reading and writing arguments](#reading-and-writing-arguments)
|
||||||
|
9. [Inter-Mod Communication](#inter-mod-communication)
|
||||||
|
10. [Full Example](#full-example)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Getting Started
|
||||||
|
|
||||||
|
Fork the [mod template](../tools/mod_template/), it is a self-contained CMake project that references dusk as a subdirectory.
|
||||||
|
|
||||||
|
```
|
||||||
|
my_mod/
|
||||||
|
├── CMakeLists.txt
|
||||||
|
├── mod.json
|
||||||
|
├── src/mod.cpp
|
||||||
|
└── res/ (optional bundled resources)
|
||||||
|
```
|
||||||
|
|
||||||
|
**CMakeLists.txt:**
|
||||||
|
|
||||||
|
```cmake
|
||||||
|
cmake_minimum_required(VERSION 3.25)
|
||||||
|
project(my_mod CXX)
|
||||||
|
|
||||||
|
set(DUSK_DIR "${CMAKE_CURRENT_SOURCE_DIR}/dusk" CACHE PATH "Path to dusk source root")
|
||||||
|
add_subdirectory("${DUSK_DIR}" dusk EXCLUDE_FROM_ALL)
|
||||||
|
|
||||||
|
add_dusk_mod(my_mod
|
||||||
|
SOURCES src/mod.cpp
|
||||||
|
MOD_JSON mod.json
|
||||||
|
RES_DIR res # optional
|
||||||
|
)
|
||||||
|
```
|
||||||
|
|
||||||
|
After building, `my_mod.dusk` is placed in `mods/` next to the project root (`DUSK_MODS_OUTPUT_DIR` cache variable). Copy it to the game's `mods/` folder and launch.
|
||||||
|
|
||||||
|
- Windows: `%APPDATA%\TwilitRealm\Dusk\mods`
|
||||||
|
- Linux: `~/.local/share/TwilitRealm/Dusk/mods`
|
||||||
|
- macOS: `~/Library/Application Support/TwilitRealm/Dusk/mods`
|
||||||
|
|
||||||
|
The `.dusk` archive is a standard zip containing `mod.json`, the compiled library, and an optional `res/` tree. `add_dusk_mod()` creates it automatically.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## mod.json
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"name": "My Mod",
|
||||||
|
"version": "1.0.0",
|
||||||
|
"author": "Your Name",
|
||||||
|
"description": "A short description shown in the mod manager."
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
All fields are optional but recommended. `name` falls back to the filename, `version` to `"?"`.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Required Exports
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
#include "dusk/mod_api.h"
|
||||||
|
|
||||||
|
DUSK_REQUIRE_API_VERSION // declares mod_api_version; loader rejects the mod if the engine is older
|
||||||
|
|
||||||
|
extern "C" {
|
||||||
|
|
||||||
|
void mod_init (DuskModAPI* api); // required, called once at startup
|
||||||
|
void mod_tick (DuskModAPI* api); // required, called every frame
|
||||||
|
void mod_cleanup(DuskModAPI* api); // optional, called on shutdown
|
||||||
|
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
`DUSK_REQUIRE_API_VERSION` is optional but recommended. When present, the loader will refuse to initialize the mod if its API version doesn't exactly match the engine's.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## DuskModAPI Reference
|
||||||
|
|
||||||
|
The `api` pointer is valid for the lifetime of the mod. When using `hook.hpp`, call `dusk::init(api)` once and `dusk::g_api` is set for you.
|
||||||
|
|
||||||
|
| Field | Description |
|
||||||
|
|-------|-------------|
|
||||||
|
| `api_version` | ABI version, check against `DUSK_MOD_API_VERSION` if needed |
|
||||||
|
| `mod_dir` | Absolute path to the extracted mod cache directory |
|
||||||
|
| `log_info` / `log_warn` / `log_error` | `printf`-style logging, prefixed with the mod name |
|
||||||
|
| `load_resource` / `free_resource` | Load files from the `res/` tree in the `.dusk` archive |
|
||||||
|
| `register_tab_content` | Add a panel to the mod manager's per-mod tab |
|
||||||
|
| `register_menu_item` | Add an item to the quick-access menu |
|
||||||
|
| `hook_dispatch_pre` / `hook_dispatch_post` | Called by the trampoline, do not call directly |
|
||||||
|
| `service_publish` | Register a named pointer in the global service registry |
|
||||||
|
| `service_get` | Look up a named pointer registered by another mod |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Logging
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
api->log_info("Player health: %d", hp);
|
||||||
|
api->log_warn("Something looks wrong");
|
||||||
|
api->log_error("Fatal: %s", msg);
|
||||||
|
```
|
||||||
|
|
||||||
|
Output appears in the dusk console as `[My Mod] ...`
|
||||||
|
|
||||||
|
The format string is `printf`-compatible.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Loading Resources
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
size_t size = 0;
|
||||||
|
void* data = api->load_resource("config.txt", &size);
|
||||||
|
if (data) {
|
||||||
|
std::string text(static_cast<char*>(data), size);
|
||||||
|
api->free_resource(data);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
- Path is relative to `res/`, pass `"config.txt"` not `"res/config.txt"`
|
||||||
|
- Always call `free_resource`, the buffer is owned by miniz
|
||||||
|
- For writable storage, write files under `api->mod_dir`
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## ImGui Integration
|
||||||
|
|
||||||
|
**Tab content:** shown in the mod's panel in the Mods window, called every frame while visible:
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
static void DrawPanel(void* userdata) {
|
||||||
|
ImGui::Text("Hello!");
|
||||||
|
}
|
||||||
|
api->register_tab_content(DrawPanel, nullptr);
|
||||||
|
```
|
||||||
|
|
||||||
|
Pass a pointer through `userdata` if your callback needs state:
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
api->register_tab_content(DrawPanel, &g_state);
|
||||||
|
```
|
||||||
|
|
||||||
|
**Menu items:** added to the quick-access menu. Use `ImGui::MenuItem`, `ImGui::Separator`, etc.:
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
static void DrawMenuEntry(void*) {
|
||||||
|
if (ImGui::MenuItem("Reset rotation")) { ... }
|
||||||
|
}
|
||||||
|
api->register_menu_item(DrawMenuEntry, nullptr);
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Hooking Game Functions
|
||||||
|
|
||||||
|
Call `dusk::init(api)` first.
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
#include "dusk/hook.hpp"
|
||||||
|
|
||||||
|
extern "C" void mod_init(DuskModAPI* api) {
|
||||||
|
dusk::init(api);
|
||||||
|
dusk::hookAddPre<&ClassName::Method>(callback);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
The trampoline is installed once per address. Multiple mods can register pre/post callbacks for the same function independently.
|
||||||
|
|
||||||
|
### Pre-hooks
|
||||||
|
|
||||||
|
Run before the original. Return `0` to let it proceed, non-zero to cancel it. Post-hooks still run either way.
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
static int32_t on_posMove_pre(void* args) {
|
||||||
|
daAlink_c* link = dusk::arg<daAlink_c*>(args, 0); // this
|
||||||
|
if (link->shape_angle.y > 10000)
|
||||||
|
return 1; // cancel
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
dusk::hookAddPre<&daAlink_c::posMove>(on_posMove_pre);
|
||||||
|
```
|
||||||
|
|
||||||
|
### Post-hooks
|
||||||
|
|
||||||
|
Run after the original (or replace-hook).
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
static void on_posMove_post(void* args) {
|
||||||
|
daAlink_c* link = dusk::arg<daAlink_c*>(args, 0);
|
||||||
|
dusk::g_api->log_info("New Y angle: %d", (int)link->shape_angle.y);
|
||||||
|
}
|
||||||
|
dusk::hookAddPost<&daAlink_c::posMove>(on_posMove_post);
|
||||||
|
```
|
||||||
|
|
||||||
|
### Replace hooks
|
||||||
|
|
||||||
|
Completely substitutes the original. Only one replace-hook per function, a second install overwrites with a warning.
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
static void on_posMove_replace(void* args) {
|
||||||
|
daAlink_c* link = dusk::arg<daAlink_c*>(args, 0);
|
||||||
|
link->shape_angle.y += 100;
|
||||||
|
}
|
||||||
|
dusk::hookSetReplace<&daAlink_c::posMove>(on_posMove_replace);
|
||||||
|
```
|
||||||
|
|
||||||
|
To call the original from inside a replace-hook:
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
using Entry = dusk::HookEntry<&daAlink_c::posMove>;
|
||||||
|
|
||||||
|
static void on_posMove_replace(void* args) {
|
||||||
|
daAlink_c* link = dusk::arg<daAlink_c*>(args, 0);
|
||||||
|
link->shape_angle.y = 0;
|
||||||
|
Entry::g_orig(link);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### Reading and writing arguments
|
||||||
|
|
||||||
|
`args` is a `void*[N]` array. Index `0` is `this`, subsequent indices are parameters in declaration order.
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
T value = dusk::arg <T>(args, n); // copy
|
||||||
|
T& ref = dusk::argRef<T>(args, n); // reference (read/write)
|
||||||
|
```
|
||||||
|
|
||||||
|
**Example:** halve incoming damage
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
// void daEnemy_c::takeDamage(int amount, daActor_c* source)
|
||||||
|
static int32_t on_takeDamage_pre(void* args) {
|
||||||
|
dusk::argRef<int>(args, 1) /= 2;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
dusk::hookAddPre<&daEnemy_c::takeDamage>(on_takeDamage_pre);
|
||||||
|
```
|
||||||
|
|
||||||
|
For reference parameters (e.g. `const cXyz& pos`), use `argRef<cXyz>` to get a direct reference.
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Inter-Mod Communication
|
||||||
|
|
||||||
|
Mods can expose a public API to each other through a global service registry. The convention for names is `"mod_name/service_name"`.
|
||||||
|
|
||||||
|
**Mod A — publishing:**
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
struct MyModAPI {
|
||||||
|
void (*do_thing)(int value);
|
||||||
|
};
|
||||||
|
|
||||||
|
static void my_do_thing(int value) { ... }
|
||||||
|
static MyModAPI g_api = { my_do_thing };
|
||||||
|
|
||||||
|
extern "C" void mod_init(DuskModAPI* api) {
|
||||||
|
api->service_publish("my_mod/api", &g_api);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
**Mod B — consuming:**
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
#include "my_mod_api.h"
|
||||||
|
|
||||||
|
static MyModAPI* g_my_mod = nullptr;
|
||||||
|
|
||||||
|
extern "C" void mod_init(DuskModAPI* api) {
|
||||||
|
g_my_mod = static_cast<MyModAPI*>(api->service_get("my_mod/api"));
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Full Example
|
||||||
|
|
||||||
|
```cpp
|
||||||
|
#include "d/actor/d_a_alink.h"
|
||||||
|
#include "dusk/hook.hpp"
|
||||||
|
#include "dusk/mod_api.h"
|
||||||
|
#include "imgui.h"
|
||||||
|
#include "m_Do/m_Do_controller_pad.h"
|
||||||
|
|
||||||
|
static int g_ticks = 0;
|
||||||
|
|
||||||
|
static int32_t on_posMove_pre(void* args) {
|
||||||
|
daAlink_c* link = dusk::arg<daAlink_c*>(args, 0);
|
||||||
|
if (mDoCPd_c::getHoldR(PAD_1)) {
|
||||||
|
link->shape_angle.y -= 2048;
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void DrawPanel(void*) {
|
||||||
|
daAlink_c* link = daAlink_getAlinkActorClass();
|
||||||
|
ImGui::Text("Ticks: %d", g_ticks);
|
||||||
|
if (link) {
|
||||||
|
ImGui::Text("Y angle: %d", (int)link->shape_angle.y);
|
||||||
|
if (ImGui::Button("Reset rotation")) {
|
||||||
|
link->shape_angle.y = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void DrawMenuEntry(void*) {
|
||||||
|
daAlink_c* link = daAlink_getAlinkActorClass();
|
||||||
|
if (ImGui::MenuItem("Reset rotation", nullptr, false, link != nullptr)) {
|
||||||
|
link->shape_angle.y = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
extern "C" {
|
||||||
|
|
||||||
|
void mod_init(DuskModAPI* api) {
|
||||||
|
dusk::init(api);
|
||||||
|
dusk::hookAddPre<&daAlink_c::posMove>(on_posMove_pre);
|
||||||
|
api->register_tab_content(DrawPanel, nullptr);
|
||||||
|
api->register_menu_item(DrawMenuEntry, nullptr);
|
||||||
|
}
|
||||||
|
|
||||||
|
void mod_tick(DuskModAPI* api) {
|
||||||
|
++g_ticks;
|
||||||
|
}
|
||||||
|
|
||||||
|
void mod_cleanup(DuskModAPI* api) {
|
||||||
|
api->log_info("Unloaded after %d ticks.", g_ticks);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
Vendored
+1
-1
Submodule extern/aurora updated: cb2c340d6c...e145b9ec20
+30
@@ -1418,7 +1418,11 @@ set(DUSK_FILES
|
|||||||
include/dusk/scope_guard.hpp
|
include/dusk/scope_guard.hpp
|
||||||
src/dusk/dvd_asset.cpp
|
src/dusk/dvd_asset.cpp
|
||||||
src/d/actor/d_a_alink_dusk.cpp
|
src/d/actor/d_a_alink_dusk.cpp
|
||||||
|
src/dusk/android_frame_rate.hpp
|
||||||
|
src/dusk/android_frame_rate.cpp
|
||||||
src/dusk/asserts.cpp
|
src/dusk/asserts.cpp
|
||||||
|
src/dusk/batch.cpp
|
||||||
|
src/dusk/batch.hpp
|
||||||
src/dusk/config.cpp
|
src/dusk/config.cpp
|
||||||
src/dusk/crash_handler.cpp
|
src/dusk/crash_handler.cpp
|
||||||
src/dusk/crash_reporting.cpp
|
src/dusk/crash_reporting.cpp
|
||||||
@@ -1432,6 +1436,9 @@ set(DUSK_FILES
|
|||||||
src/dusk/game_clock.cpp
|
src/dusk/game_clock.cpp
|
||||||
src/dusk/globals.cpp
|
src/dusk/globals.cpp
|
||||||
src/dusk/gyro.cpp
|
src/dusk/gyro.cpp
|
||||||
|
include/dusk/menu_pointer.h
|
||||||
|
src/dusk/menu_pointer.cpp
|
||||||
|
src/dusk/mouse.cpp
|
||||||
src/dusk/gamepad_color.cpp
|
src/dusk/gamepad_color.cpp
|
||||||
src/dusk/autosave.cpp
|
src/dusk/autosave.cpp
|
||||||
src/dusk/http/http.hpp
|
src/dusk/http/http.hpp
|
||||||
@@ -1442,6 +1449,9 @@ set(DUSK_FILES
|
|||||||
src/dusk/speedrun.cpp
|
src/dusk/speedrun.cpp
|
||||||
src/dusk/string.cpp
|
src/dusk/string.cpp
|
||||||
src/dusk/stubs.cpp
|
src/dusk/stubs.cpp
|
||||||
|
include/dusk/texture_replacements.hpp
|
||||||
|
src/dusk/texture_replacements.cpp
|
||||||
|
src/dusk/touch_camera.cpp
|
||||||
src/dusk/update_check.cpp
|
src/dusk/update_check.cpp
|
||||||
src/dusk/update_check.hpp
|
src/dusk/update_check.hpp
|
||||||
#src/dusk/m_Do_ext_dusk.cpp
|
#src/dusk/m_Do_ext_dusk.cpp
|
||||||
@@ -1471,6 +1481,7 @@ set(DUSK_FILES
|
|||||||
src/dusk/ui/button.hpp
|
src/dusk/ui/button.hpp
|
||||||
src/dusk/ui/component.cpp
|
src/dusk/ui/component.cpp
|
||||||
src/dusk/ui/component.hpp
|
src/dusk/ui/component.hpp
|
||||||
|
src/dusk/ui/controls.hpp
|
||||||
src/dusk/ui/controller_config.cpp
|
src/dusk/ui/controller_config.cpp
|
||||||
src/dusk/ui/controller_config.hpp
|
src/dusk/ui/controller_config.hpp
|
||||||
src/dusk/ui/document.cpp
|
src/dusk/ui/document.cpp
|
||||||
@@ -1483,6 +1494,8 @@ set(DUSK_FILES
|
|||||||
src/dusk/ui/graphics_tuner.hpp
|
src/dusk/ui/graphics_tuner.hpp
|
||||||
src/dusk/ui/input.cpp
|
src/dusk/ui/input.cpp
|
||||||
src/dusk/ui/input.hpp
|
src/dusk/ui/input.hpp
|
||||||
|
src/dusk/ui/icon_provider.cpp
|
||||||
|
src/dusk/ui/icon_provider.hpp
|
||||||
src/dusk/ui/modal.cpp
|
src/dusk/ui/modal.cpp
|
||||||
src/dusk/ui/modal.hpp
|
src/dusk/ui/modal.hpp
|
||||||
src/dusk/ui/nav_types.hpp
|
src/dusk/ui/nav_types.hpp
|
||||||
@@ -1494,6 +1507,8 @@ set(DUSK_FILES
|
|||||||
src/dusk/ui/pane.hpp
|
src/dusk/ui/pane.hpp
|
||||||
src/dusk/ui/menu_bar.cpp
|
src/dusk/ui/menu_bar.cpp
|
||||||
src/dusk/ui/menu_bar.hpp
|
src/dusk/ui/menu_bar.hpp
|
||||||
|
src/dusk/ui/mods_window.cpp
|
||||||
|
src/dusk/ui/mods_window.hpp
|
||||||
src/dusk/ui/prelaunch.cpp
|
src/dusk/ui/prelaunch.cpp
|
||||||
src/dusk/ui/prelaunch.hpp
|
src/dusk/ui/prelaunch.hpp
|
||||||
src/dusk/ui/preset.cpp
|
src/dusk/ui/preset.cpp
|
||||||
@@ -1508,6 +1523,12 @@ set(DUSK_FILES
|
|||||||
src/dusk/ui/string_button.hpp
|
src/dusk/ui/string_button.hpp
|
||||||
src/dusk/ui/tab_bar.cpp
|
src/dusk/ui/tab_bar.cpp
|
||||||
src/dusk/ui/tab_bar.hpp
|
src/dusk/ui/tab_bar.hpp
|
||||||
|
src/dusk/ui/touch_controls_common.cpp
|
||||||
|
src/dusk/ui/touch_controls_common.hpp
|
||||||
|
src/dusk/ui/touch_controls.cpp
|
||||||
|
src/dusk/ui/touch_controls.hpp
|
||||||
|
src/dusk/ui/touch_controls_editor.cpp
|
||||||
|
src/dusk/ui/touch_controls_editor.hpp
|
||||||
src/dusk/ui/ui.cpp
|
src/dusk/ui/ui.cpp
|
||||||
src/dusk/ui/ui.hpp
|
src/dusk/ui/ui.hpp
|
||||||
src/dusk/ui/warp.cpp
|
src/dusk/ui/warp.cpp
|
||||||
@@ -1522,6 +1543,15 @@ set(DUSK_FILES
|
|||||||
src/dusk/OSReport.cpp
|
src/dusk/OSReport.cpp
|
||||||
src/dusk/OSThread.cpp
|
src/dusk/OSThread.cpp
|
||||||
src/dusk/OSMutex.cpp
|
src/dusk/OSMutex.cpp
|
||||||
|
src/dusk/hook_system.cpp
|
||||||
|
src/dusk/modding/mod_loader.cpp
|
||||||
|
src/dusk/modding/mod_loader_api.cpp
|
||||||
|
src/dusk/modding/mod_loader_overlay.cpp
|
||||||
|
src/dusk/modding/native_module.cpp
|
||||||
|
src/dusk/modding/native_module.hpp
|
||||||
|
src/dusk/modding/bundle_disk.cpp
|
||||||
|
src/dusk/modding/bundle_zip.cpp
|
||||||
|
src/dusk/gx_helper.cpp
|
||||||
src/dusk/discord.cpp
|
src/dusk/discord.cpp
|
||||||
src/dusk/discord.hpp
|
src/dusk/discord.hpp
|
||||||
src/dusk/discord_presence.cpp
|
src/dusk/discord_presence.cpp
|
||||||
|
|||||||
@@ -0,0 +1,32 @@
|
|||||||
|
From f69d29614644f9963f5cb3f828b58575d60a1c5a Mon Sep 17 00:00:00 2001
|
||||||
|
From: Joshua Trees <gh@jtrees.io>
|
||||||
|
Date: Thu, 4 Jun 2026 01:04:04 +0100
|
||||||
|
Subject: [PATCH] fix cmake paths
|
||||||
|
|
||||||
|
---
|
||||||
|
cmake/nodConfig.cmake.in | 6 +++---
|
||||||
|
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/cmake/nodConfig.cmake.in b/cmake/nodConfig.cmake.in
|
||||||
|
index 0969382..2a24a88 100644
|
||||||
|
--- a/cmake/nodConfig.cmake.in
|
||||||
|
+++ b/cmake/nodConfig.cmake.in
|
||||||
|
@@ -1,12 +1,12 @@
|
||||||
|
@PACKAGE_INIT@
|
||||||
|
|
||||||
|
-set(_nod_libdir "${PACKAGE_PREFIX_DIR}/@CMAKE_INSTALL_LIBDIR@")
|
||||||
|
-set(_nod_incdir "${PACKAGE_PREFIX_DIR}/@CMAKE_INSTALL_INCLUDEDIR@")
|
||||||
|
+set(_nod_libdir "@CMAKE_INSTALL_FULL_LIBDIR@")
|
||||||
|
+set(_nod_incdir "@CMAKE_INSTALL_FULL_INCLUDEDIR@")
|
||||||
|
|
||||||
|
if (NOT TARGET nod::nod_shared AND NOT TARGET nod::nod_static)
|
||||||
|
# Shared library
|
||||||
|
if (WIN32)
|
||||||
|
- set(_nod_dll "${PACKAGE_PREFIX_DIR}/@CMAKE_INSTALL_BINDIR@/${CMAKE_SHARED_LIBRARY_PREFIX}nod${CMAKE_SHARED_LIBRARY_SUFFIX}")
|
||||||
|
+ set(_nod_dll "@CMAKE_INSTALL_FULL_BINDIR@/${CMAKE_SHARED_LIBRARY_PREFIX}nod${CMAKE_SHARED_LIBRARY_SUFFIX}")
|
||||||
|
set(_nod_implib "${_nod_libdir}/${CMAKE_IMPORT_LIBRARY_PREFIX}nod${CMAKE_IMPORT_LIBRARY_SUFFIX}")
|
||||||
|
if (EXISTS "${_nod_dll}")
|
||||||
|
add_library(nod::nod_shared SHARED IMPORTED)
|
||||||
|
--
|
||||||
|
2.53.0
|
||||||
|
|
||||||
@@ -16,37 +16,37 @@
|
|||||||
];
|
];
|
||||||
forAllSystems = lib.genAttrs supportedSystems;
|
forAllSystems = lib.genAttrs supportedSystems;
|
||||||
|
|
||||||
dawnVersion = "v20260423.175430";
|
dawnVersion = "v20260618.032059";
|
||||||
nodVersion = "v2.0.0-alpha.8";
|
nodVersion = "v2.0.0-alpha.10";
|
||||||
versionSuffix = "nix-" + (self.shortRev or self.dirtyShortRev or "dirty");
|
versionSuffix = "nix-" + (self.shortRev or self.dirtyShortRev or "dirty");
|
||||||
|
|
||||||
dawnInfo = {
|
dawnInfo = {
|
||||||
"x86_64-linux" = {
|
"x86_64-linux" = {
|
||||||
triple = "linux-x86_64";
|
triple = "linux-x86_64";
|
||||||
hash = "sha256-HXfKTLHtMPwupnFnaflCARtXVPuS/0PoCePXidjE5xs=";
|
hash = "sha256-GFSd573b+VQx/VmFdNQgWDd0V9ayQlcw0Zuopke12ak=";
|
||||||
};
|
};
|
||||||
"aarch64-linux" = {
|
"aarch64-linux" = {
|
||||||
triple = "linux-aarch64";
|
triple = "linux-aarch64";
|
||||||
hash = "sha256-34yyFpfqBZUwoFXQ41F0AwAU78FaNihOSY0oriwn6B0=";
|
hash = "sha256-ZaoP7BAjBMnfAv2/AMRi3FNH2ZtyqASCSFyU/oB2Mzg=";
|
||||||
};
|
};
|
||||||
"aarch64-darwin" = {
|
"aarch64-darwin" = {
|
||||||
triple = "darwin-arm64";
|
triple = "darwin-arm64";
|
||||||
hash = "sha256-eQnzrBp6gjiBek1VYQ9A5W13ClYWrDDKjIqv/7eNTR4=";
|
hash = "sha256-HT+qtlLaSHyoXPrUcXgcTGa877X5YfzbxRD4bJb7i1Y=";
|
||||||
};
|
};
|
||||||
"x86_64-darwin" = {
|
"x86_64-darwin" = {
|
||||||
triple = "darwin-x86_64";
|
triple = "darwin-x86_64";
|
||||||
hash = "sha256-QGWiGdxiI9kci3NPXH6QFFirxn16851zB/w3jqhIBJ4=";
|
hash = "sha256-cUNaCbA7rlKSukDVKGaVEVw0Zt1+mSbaHbmUCMvMVWc=";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
nodPrebuiltInfo = {
|
nodPrebuiltInfo = {
|
||||||
"x86_64-linux" = {
|
"x86_64-linux" = {
|
||||||
triple = "linux-x86_64";
|
triple = "linux-x86_64";
|
||||||
hash = "sha256-mUqvLsbsqaZ+HAjMmHYPYO+MgtanGRTw7Gzn5uXR5rE=";
|
hash = "sha256-FVQWECVA2gWdc+n5OQ/Tvwn8z0qdgjSd1WlFt5HKOec=";
|
||||||
};
|
};
|
||||||
"aarch64-darwin" = {
|
"aarch64-darwin" = {
|
||||||
triple = "macos-arm64";
|
triple = "macos-arm64";
|
||||||
hash = "sha256-UPy1ywCcv0K6VJOU3uUelJuUdBh3UNaPRlyP5LOBeDw=";
|
hash = "sha256-8ZEejxksVgShNKUVRCBYaLOp9x/qOC9pAeVrElQUGUk=";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -57,15 +57,25 @@
|
|||||||
inherit (pkgs.stdenv.hostPlatform) isDarwin;
|
inherit (pkgs.stdenv.hostPlatform) isDarwin;
|
||||||
hasNodPrebuilt = nodPrebuiltInfo ? ${system};
|
hasNodPrebuilt = nodPrebuiltInfo ? ${system};
|
||||||
|
|
||||||
aurora = pkgs.fetchFromGitHub {
|
aurora = builtins.pathExists "${self}/extern/aurora/CMakeLists.txt";
|
||||||
owner = "encounter";
|
needSubmodules = ''
|
||||||
repo = "aurora";
|
dusklight: The aurora submodule is not vendored. Add submodules=1 to build.
|
||||||
rev = "10006618ee493f248b8597e4dfa1d2871d76a1d9";
|
|
||||||
hash = "sha256-lY2xuVyB7aPJ9+2wwLRB3F5U/BuPSxdSpegdG+qNd9o=";
|
As a flake input:
|
||||||
};
|
|
||||||
|
dusklight.url = "git+https://github.com/TwilitRealm/dusklight?ref=main&submodules=1";
|
||||||
|
|
||||||
|
nix command:
|
||||||
|
|
||||||
|
nix run 'git+https://github.com/TwilitRealm/dusklight?submodules=1'
|
||||||
|
|
||||||
|
Local checkout:
|
||||||
|
|
||||||
|
nix run '.?submodules=1#dusklight'
|
||||||
|
'';
|
||||||
|
|
||||||
dawn = pkgs.fetchzip {
|
dawn = pkgs.fetchzip {
|
||||||
url = "https://github.com/encounter/dawn-build/releases/download/${dawnVersion}/dawn-${dawnInfo.${system}.triple}.tar.gz";
|
url = "https://github.com/encounter/dawn/releases/download/${dawnVersion}/dawn-${dawnInfo.${system}.triple}.tar.gz";
|
||||||
hash = dawnInfo.${system}.hash;
|
hash = dawnInfo.${system}.hash;
|
||||||
stripRoot = false;
|
stripRoot = false;
|
||||||
};
|
};
|
||||||
@@ -84,8 +94,9 @@
|
|||||||
owner = "encounter";
|
owner = "encounter";
|
||||||
repo = "nod";
|
repo = "nod";
|
||||||
rev = nodVersion;
|
rev = nodVersion;
|
||||||
hash = "sha256-+zrtVzjo0+X/6uMcNUn1+FaSR+jOhrcQSDNBFjw0NDs=";
|
hash = "sha256-r8qDlOVxv5iKiFjJQrcBuL9HVoOM3yEjRVnQIMqaICs=";
|
||||||
};
|
};
|
||||||
|
patches = [ ./fix-cmake-paths.patch ];
|
||||||
cargoDeps = pkgs.rustPlatform.importCargoLock {
|
cargoDeps = pkgs.rustPlatform.importCargoLock {
|
||||||
lockFile = "${finalAttrs.src}/Cargo.lock";
|
lockFile = "${finalAttrs.src}/Cargo.lock";
|
||||||
};
|
};
|
||||||
@@ -127,15 +138,15 @@
|
|||||||
NOD_PREBUILT = nod;
|
NOD_PREBUILT = nod;
|
||||||
CXXOPTS = pkgs.cxxopts.src;
|
CXXOPTS = pkgs.cxxopts.src;
|
||||||
JSON = pkgs.nlohmann_json.src;
|
JSON = pkgs.nlohmann_json.src;
|
||||||
XXHASH = pkgs.xxHash.src;
|
XXHASH = pkgs.xxhash.src;
|
||||||
ZSTD = pkgs.zstd.src;
|
ZSTD = pkgs.zstd.src;
|
||||||
FMT = pkgs.fetchzip {
|
FMT = pkgs.fetchzip {
|
||||||
url = "https://github.com/fmtlib/fmt/archive/refs/tags/11.1.4.tar.gz";
|
url = "https://github.com/fmtlib/fmt/archive/refs/tags/12.1.0.tar.gz";
|
||||||
hash = "sha256-sUbxlYi/Aupaox3JjWFqXIjcaQa0LFjclQAOleT+FRA=";
|
hash = "sha256-ZmI1Dv0ZabPlxa02OpERI47jp7zFfjpeWCy1WyuPYZ0=";
|
||||||
};
|
};
|
||||||
TRACY = pkgs.fetchzip {
|
TRACY = pkgs.fetchzip {
|
||||||
url = "https://github.com/wolfpld/tracy/archive/a64b9a20294d59421a2f57aeca3c6383d8c48169.tar.gz";
|
url = "https://github.com/wolfpld/tracy/archive/6789e7d6f9a65ec98926b602097a33a9676d2606.tar.gz";
|
||||||
hash = "sha256-hbNGOsGeyGSvCJ2No8RkwOib1lX2on3vNZSzyVkZdXw=";
|
hash = "sha256-Xxyd7G/mnXEPpN+ehmwl0AkAhS3CwObpJNDgcqbdUJg=";
|
||||||
};
|
};
|
||||||
IMGUI = pkgs.fetchFromGitHub {
|
IMGUI = pkgs.fetchFromGitHub {
|
||||||
owner = "ocornut";
|
owner = "ocornut";
|
||||||
@@ -153,119 +164,120 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
dusklight = pkgs.stdenv.mkDerivation {
|
dusklight =
|
||||||
pname = "dusklight";
|
if !aurora then
|
||||||
version = versionSuffix;
|
throw needSubmodules
|
||||||
src = ./.;
|
else
|
||||||
|
pkgs.stdenv.mkDerivation {
|
||||||
|
pname = "dusklight";
|
||||||
|
version = versionSuffix;
|
||||||
|
src = ./.;
|
||||||
|
|
||||||
postUnpack = ''
|
postUnpack = ''
|
||||||
chmod -R u+w "$sourceRoot"
|
chmod -R u+w "$sourceRoot"
|
||||||
rm -rf "$sourceRoot/extern/aurora"
|
substituteInPlace "$sourceRoot/extern/aurora/CMakeLists.txt" \
|
||||||
mkdir -p "$sourceRoot/extern"
|
--replace-warn "add_subdirectory(tests)" ""
|
||||||
cp -r ${aurora} "$sourceRoot/extern/aurora"
|
|
||||||
chmod -R u+w "$sourceRoot/extern/aurora"
|
|
||||||
substituteInPlace "$sourceRoot/extern/aurora/CMakeLists.txt" \
|
|
||||||
--replace-warn "add_subdirectory(tests)" ""
|
|
||||||
'';
|
|
||||||
|
|
||||||
nativeBuildInputs = [
|
|
||||||
pkgs.cmake
|
|
||||||
pkgs.ninja
|
|
||||||
pkgs.pkg-config
|
|
||||||
pkgs.python3
|
|
||||||
pkgs.python3Packages.markupsafe
|
|
||||||
]
|
|
||||||
++ lib.optionals (!isDarwin) [ pkgs.autoPatchelfHook ];
|
|
||||||
|
|
||||||
buildInputs = [
|
|
||||||
pkgs.sdl3
|
|
||||||
pkgs.freetype
|
|
||||||
pkgs.zstd
|
|
||||||
pkgs.cxxopts
|
|
||||||
pkgs.nlohmann_json
|
|
||||||
pkgs.xxHash
|
|
||||||
pkgs.abseil-cpp
|
|
||||||
pkgs.zlib
|
|
||||||
pkgs.libpng
|
|
||||||
pkgs.libjpeg_turbo
|
|
||||||
pkgs.curl
|
|
||||||
pkgs.openssl
|
|
||||||
]
|
|
||||||
++ lib.optionals isDarwin [
|
|
||||||
pkgs.apple-sdk_15
|
|
||||||
pkgs.libiconv
|
|
||||||
]
|
|
||||||
++ lib.optionals (!isDarwin) [
|
|
||||||
pkgs.libGL
|
|
||||||
pkgs.libGLU
|
|
||||||
pkgs.libglvnd
|
|
||||||
pkgs.vulkan-loader
|
|
||||||
pkgs.libX11
|
|
||||||
pkgs.libxcb
|
|
||||||
pkgs.libXcursor
|
|
||||||
pkgs.libxi
|
|
||||||
pkgs.libxrandr
|
|
||||||
pkgs.libxscrnsaver
|
|
||||||
pkgs.libxtst
|
|
||||||
pkgs.libxinerama
|
|
||||||
pkgs.libxkbcommon
|
|
||||||
pkgs.wayland
|
|
||||||
pkgs.libdecor
|
|
||||||
pkgs.alsa-lib
|
|
||||||
pkgs.libpulseaudio
|
|
||||||
pkgs.pipewire
|
|
||||||
pkgs.dbus
|
|
||||||
pkgs.udev
|
|
||||||
pkgs.libusb1
|
|
||||||
pkgs.libunwind
|
|
||||||
pkgs.gtk3
|
|
||||||
];
|
|
||||||
|
|
||||||
cmakeBuildType = "RelWithDebInfo";
|
|
||||||
ninjaFlags = [ "dusklight" ];
|
|
||||||
|
|
||||||
cmakeFlags = [
|
|
||||||
"-DDUSK_VERSION_OVERRIDE=${versionSuffix}"
|
|
||||||
"-DFETCHCONTENT_FULLY_DISCONNECTED=ON"
|
|
||||||
"-DAURORA_DAWN_PROVIDER=package"
|
|
||||||
"-DAURORA_DAWN_LINKAGE=static"
|
|
||||||
"-DAURORA_NOD_PROVIDER=package"
|
|
||||||
"-DAURORA_NOD_LINKAGE=static"
|
|
||||||
"-DAURORA_SDL3_PROVIDER=system"
|
|
||||||
]
|
|
||||||
++ lib.mapAttrsToList (key: src: "-DFETCHCONTENT_SOURCE_DIR_${key}=${src}") fetchContentDirs;
|
|
||||||
|
|
||||||
installPhase =
|
|
||||||
if isDarwin then
|
|
||||||
''
|
|
||||||
runHook preInstall
|
|
||||||
mkdir -p "$out/Applications"
|
|
||||||
cp -r Dusklight.app "$out/Applications/Dusklight.app"
|
|
||||||
runHook postInstall
|
|
||||||
''
|
|
||||||
else
|
|
||||||
''
|
|
||||||
runHook preInstall
|
|
||||||
install -Dm755 dusklight "$out/bin/dusklight"
|
|
||||||
cp -r "$src/res" "$out/bin/res"
|
|
||||||
install -Dm644 "$src/platforms/freedesktop/dev.twilitrealm.dusk.desktop" \
|
|
||||||
"$out/share/applications/dev.twilitrealm.dusk.desktop"
|
|
||||||
for size in 16 32 48 64 128 256 512 1024; do
|
|
||||||
install -Dm644 "$src/platforms/freedesktop/''${size}x''${size}/apps/dev.twilitrealm.dusk.png" \
|
|
||||||
"$out/share/icons/hicolor/''${size}x''${size}/apps/dev.twilitrealm.dusk.png"
|
|
||||||
done
|
|
||||||
runHook postInstall
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
dontStrip = true;
|
nativeBuildInputs = [
|
||||||
|
pkgs.cmake
|
||||||
|
pkgs.ninja
|
||||||
|
pkgs.pkg-config
|
||||||
|
pkgs.python3
|
||||||
|
pkgs.python3Packages.markupsafe
|
||||||
|
]
|
||||||
|
++ lib.optionals (!isDarwin) [ pkgs.autoPatchelfHook ];
|
||||||
|
|
||||||
meta = {
|
buildInputs = [
|
||||||
description = "Dusklight — native PC port of the Twilight Princess decompilation";
|
pkgs.sdl3
|
||||||
homepage = "https://github.com/zeldaret/tp";
|
pkgs.freetype
|
||||||
platforms = supportedSystems;
|
pkgs.zstd
|
||||||
mainProgram = "dusklight";
|
pkgs.cxxopts
|
||||||
};
|
pkgs.nlohmann_json
|
||||||
};
|
pkgs.xxhash
|
||||||
|
pkgs.abseil-cpp
|
||||||
|
pkgs.zlib
|
||||||
|
pkgs.libpng
|
||||||
|
pkgs.libjpeg_turbo
|
||||||
|
pkgs.curl
|
||||||
|
pkgs.openssl
|
||||||
|
]
|
||||||
|
++ lib.optionals isDarwin [
|
||||||
|
pkgs.apple-sdk_15
|
||||||
|
pkgs.libiconv
|
||||||
|
]
|
||||||
|
++ lib.optionals (!isDarwin) [
|
||||||
|
pkgs.libGL
|
||||||
|
pkgs.libGLU
|
||||||
|
pkgs.libglvnd
|
||||||
|
pkgs.vulkan-loader
|
||||||
|
pkgs.libX11
|
||||||
|
pkgs.libxcb
|
||||||
|
pkgs.libXcursor
|
||||||
|
pkgs.libxi
|
||||||
|
pkgs.libxrandr
|
||||||
|
pkgs.libxscrnsaver
|
||||||
|
pkgs.libxtst
|
||||||
|
pkgs.libxinerama
|
||||||
|
pkgs.libxkbcommon
|
||||||
|
pkgs.wayland
|
||||||
|
pkgs.libdecor
|
||||||
|
pkgs.alsa-lib
|
||||||
|
pkgs.libpulseaudio
|
||||||
|
pkgs.pipewire
|
||||||
|
pkgs.dbus
|
||||||
|
pkgs.udev
|
||||||
|
pkgs.libusb1
|
||||||
|
pkgs.libunwind
|
||||||
|
pkgs.gtk3
|
||||||
|
nod
|
||||||
|
];
|
||||||
|
|
||||||
|
cmakeBuildType = "RelWithDebInfo";
|
||||||
|
ninjaFlags = [ "dusklight" ];
|
||||||
|
|
||||||
|
cmakeFlags = [
|
||||||
|
"-DDUSK_VERSION_OVERRIDE=${versionSuffix}"
|
||||||
|
"-DFETCHCONTENT_FULLY_DISCONNECTED=ON"
|
||||||
|
"-DAURORA_DAWN_PROVIDER=package"
|
||||||
|
"-DAURORA_DAWN_LINKAGE=static"
|
||||||
|
"-DAURORA_NOD_PROVIDER=system"
|
||||||
|
"-DAURORA_SDL3_PROVIDER=system"
|
||||||
|
"-DBUILD_SHARED_LIBS=OFF"
|
||||||
|
]
|
||||||
|
++ lib.mapAttrsToList (key: src: "-DFETCHCONTENT_SOURCE_DIR_${key}=${src}") fetchContentDirs;
|
||||||
|
|
||||||
|
installPhase =
|
||||||
|
if isDarwin then
|
||||||
|
''
|
||||||
|
runHook preInstall
|
||||||
|
mkdir -p "$out/Applications"
|
||||||
|
cp -r Dusklight.app "$out/Applications/Dusklight.app"
|
||||||
|
runHook postInstall
|
||||||
|
''
|
||||||
|
else
|
||||||
|
''
|
||||||
|
runHook preInstall
|
||||||
|
install -Dm755 dusklight "$out/bin/dusklight"
|
||||||
|
cp -r "$src/res" "$out/bin/res"
|
||||||
|
install -Dm644 "$src/platforms/freedesktop/dev.twilitrealm.dusk.desktop" \
|
||||||
|
"$out/share/applications/dev.twilitrealm.dusk.desktop"
|
||||||
|
for size in 16 32 48 64 128 256 512 1024; do
|
||||||
|
install -Dm644 "$src/platforms/freedesktop/''${size}x''${size}/apps/dev.twilitrealm.dusk.png" \
|
||||||
|
"$out/share/icons/hicolor/''${size}x''${size}/apps/dev.twilitrealm.dusk.png"
|
||||||
|
done
|
||||||
|
runHook postInstall
|
||||||
|
'';
|
||||||
|
|
||||||
|
dontStrip = true;
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
description = "Dusklight — native PC port of the Twilight Princess decompilation";
|
||||||
|
homepage = "https://github.com/zeldaret/tp";
|
||||||
|
platforms = supportedSystems;
|
||||||
|
mainProgram = "dusklight";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
# Tooling common to every supported host (Linux and macOS).
|
# Tooling common to every supported host (Linux and macOS).
|
||||||
commonDevTools = [
|
commonDevTools = [
|
||||||
|
|||||||
@@ -98,7 +98,7 @@ T cLib_calcTimer(T* value) {
|
|||||||
void MtxInit(void);
|
void MtxInit(void);
|
||||||
void MtxTrans(f32, f32, f32, u8);
|
void MtxTrans(f32, f32, f32, u8);
|
||||||
void MtxScale(f32, f32, f32, u8);
|
void MtxScale(f32, f32, f32, u8);
|
||||||
void MtxPosition(cXyz*, cXyz*);
|
void MtxPosition(cXyz DUSK_CONST*, cXyz*);
|
||||||
void MtxPush(void);
|
void MtxPush(void);
|
||||||
void MtxPull(void);
|
void MtxPull(void);
|
||||||
|
|
||||||
|
|||||||
@@ -45,17 +45,17 @@ struct cXyz : Vec {
|
|||||||
~cXyz() = default;
|
~cXyz() = default;
|
||||||
cXyz(const cXyz& vec) = default;
|
cXyz(const cXyz& vec) = default;
|
||||||
#endif
|
#endif
|
||||||
cXyz(f32 x, f32 y, f32 z) {
|
DUSK_CONSTEXPR cXyz(f32 x, f32 y, f32 z) {
|
||||||
this->x = x;
|
this->x = x;
|
||||||
this->y = y;
|
this->y = y;
|
||||||
this->z = z;
|
this->z = z;
|
||||||
}
|
}
|
||||||
cXyz(const Vec& vec) {
|
DUSK_CONSTEXPR cXyz(const Vec& vec) {
|
||||||
this->x = vec.x;
|
this->x = vec.x;
|
||||||
this->y = vec.y;
|
this->y = vec.y;
|
||||||
this->z = vec.z;
|
this->z = vec.z;
|
||||||
}
|
}
|
||||||
cXyz& operator=(const Vec& vec) {
|
DUSK_CONSTEXPR cXyz& operator=(const Vec& vec) {
|
||||||
this->x = vec.x;
|
this->x = vec.x;
|
||||||
this->y = vec.y;
|
this->y = vec.y;
|
||||||
this->z = vec.z;
|
this->z = vec.z;
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ public:
|
|||||||
bool isResetting() { return mResettingFlag; }
|
bool isResetting() { return mResettingFlag; }
|
||||||
|
|
||||||
static Z2AudioMgr* getInterface() { return mAudioMgrPtr; }
|
static Z2AudioMgr* getInterface() { return mAudioMgrPtr; }
|
||||||
static Z2AudioMgr* mAudioMgrPtr;
|
static DUSK_GAME_DATA Z2AudioMgr* mAudioMgrPtr;
|
||||||
|
|
||||||
/* 0x0514 */ virtual bool startSound(JAISoundID soundID, JAISoundHandle* handle, const JGeometry::TVec3<f32>* posPtr);
|
/* 0x0514 */ virtual bool startSound(JAISoundID soundID, JAISoundHandle* handle, const JGeometry::TVec3<f32>* posPtr);
|
||||||
/* 0x0518 */ bool mResettingFlag;
|
/* 0x0518 */ bool mResettingFlag;
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ struct Z2StatusMgr : public JASGlobalInstance<Z2StatusMgr> {
|
|||||||
void menuIn();
|
void menuIn();
|
||||||
void menuOut();
|
void menuOut();
|
||||||
bool isMovieDemo();
|
bool isMovieDemo();
|
||||||
void setDemoName(char* demoName);
|
void setDemoName(DUSK_CONST char* demoName);
|
||||||
void processTime();
|
void processTime();
|
||||||
bool checkDayTime();
|
bool checkDayTime();
|
||||||
void setEventBit(void* eventBit);
|
void setEventBit(void* eventBit);
|
||||||
|
|||||||
@@ -88,6 +88,10 @@ public:
|
|||||||
/* 0x02C */ cXyz field_0x2c;
|
/* 0x02C */ cXyz field_0x2c;
|
||||||
/* 0x038 */ cXyz field_0x38[60];
|
/* 0x038 */ cXyz field_0x38[60];
|
||||||
/* 0x308 */ cXyz field_0x308[60];
|
/* 0x308 */ cXyz field_0x308[60];
|
||||||
|
#if TARGET_PC
|
||||||
|
TGXTexObj mBlurTexObj;
|
||||||
|
ResTIMG* mpCachedBlurTex = nullptr;
|
||||||
|
#endif
|
||||||
}; // Size = 0x5D8
|
}; // Size = 0x5D8
|
||||||
|
|
||||||
class dAlink_bottleWaterPcallBack_c : public JPAParticleCallBack {
|
class dAlink_bottleWaterPcallBack_c : public JPAParticleCallBack {
|
||||||
@@ -4545,13 +4549,14 @@ public:
|
|||||||
/* 0x03840 */ cXyz* mIronBallChainPos;
|
/* 0x03840 */ cXyz* mIronBallChainPos;
|
||||||
/* 0x03844 */ csXyz* mIronBallChainAngle;
|
/* 0x03844 */ csXyz* mIronBallChainAngle;
|
||||||
/* 0x03848 */ cXyz* field_0x3848;
|
/* 0x03848 */ cXyz* field_0x3848;
|
||||||
/* 0x0384C */ cXyz* field_0x384c;
|
/* 0x0384C */ cXyz DUSK_CONST* field_0x384c;
|
||||||
/* 0x03850 */ daAlink_procFunc mpProcFunc;
|
/* 0x03850 */ daAlink_procFunc mpProcFunc;
|
||||||
|
|
||||||
#if TARGET_PC
|
#if TARGET_PC
|
||||||
void handleWolfHowl();
|
void handleWolfHowl();
|
||||||
void handleQuickTransform();
|
void handleQuickTransform();
|
||||||
bool checkGyroAimContext();
|
bool checkAimContext();
|
||||||
|
bool checkAimInputContext();
|
||||||
|
|
||||||
void onIronBallChainInterpCallback();
|
void onIronBallChainInterpCallback();
|
||||||
|
|
||||||
@@ -4564,6 +4569,18 @@ public:
|
|||||||
cXyz mIBChainInterpCurrHandRoot;
|
cXyz mIBChainInterpCurrHandRoot;
|
||||||
bool mIBChainInterpPrevValid;
|
bool mIBChainInterpPrevValid;
|
||||||
bool mIBChainInterpCurrValid;
|
bool mIBChainInterpCurrValid;
|
||||||
|
|
||||||
|
cXyz mHsChainInterpPrevTop;
|
||||||
|
cXyz mHsChainInterpCurrTop;
|
||||||
|
cXyz mHsChainInterpPrevRoot;
|
||||||
|
cXyz mHsChainInterpCurrRoot;
|
||||||
|
cXyz mHsChainInterpPrevSubRoot;
|
||||||
|
cXyz mHsChainInterpCurrSubRoot;
|
||||||
|
cXyz mHsChainInterpPrevSubTop;
|
||||||
|
cXyz mHsChainInterpCurrSubTop;
|
||||||
|
bool mHsChainInterpPrevValid;
|
||||||
|
bool mHsChainInterpCurrValid;
|
||||||
|
|
||||||
bool mIsRollstab = false;
|
bool mIsRollstab = false;
|
||||||
#endif
|
#endif
|
||||||
}; // Size: 0x385C
|
}; // Size: 0x385C
|
||||||
|
|||||||
@@ -203,7 +203,7 @@ private:
|
|||||||
/* 0x0AAD */ bool mStayNo2Flag;
|
/* 0x0AAD */ bool mStayNo2Flag;
|
||||||
/* 0x0AAE */ u8 mBlendStatus;
|
/* 0x0AAE */ u8 mBlendStatus;
|
||||||
/* 0x0AB0 */ f32 mBlend;
|
/* 0x0AB0 */ f32 mBlend;
|
||||||
/* 0x0AB4 */ char* mArcName;
|
/* 0x0AB4 */ char DUSK_CONST* mArcName;
|
||||||
/* 0x0AB8 */ dBgS_AcchCir mAcchCir;
|
/* 0x0AB8 */ dBgS_AcchCir mAcchCir;
|
||||||
/* 0x0AF8 */ dBgS_ObjAcch mAcch;
|
/* 0x0AF8 */ dBgS_ObjAcch mAcch;
|
||||||
/* 0x0CD0 */ dBgS_AcchCir mAcchCirArr[16];
|
/* 0x0CD0 */ dBgS_AcchCir mAcchCirArr[16];
|
||||||
|
|||||||
@@ -23,10 +23,10 @@ public:
|
|||||||
/* 3 */ ACT_END,
|
/* 3 */ ACT_END,
|
||||||
};
|
};
|
||||||
|
|
||||||
char* getArcName();
|
DUSK_CONST char* getArcName();
|
||||||
char* getBmd();
|
DUSK_CONST char* getBmd();
|
||||||
char* getDzb();
|
DUSK_CONST char* getDzb();
|
||||||
char* getBmd2();
|
DUSK_CONST char* getBmd2();
|
||||||
J3DModelData* getDoorModelData();
|
J3DModelData* getDoorModelData();
|
||||||
int CreateHeap();
|
int CreateHeap();
|
||||||
void calcMtx();
|
void calcMtx();
|
||||||
|
|||||||
@@ -33,8 +33,8 @@ public:
|
|||||||
|
|
||||||
typedef int (daBdoorL1_c::*actionFunc)();
|
typedef int (daBdoorL1_c::*actionFunc)();
|
||||||
|
|
||||||
char* getDoorEventName();
|
DUSK_CONST char* getDoorEventName();
|
||||||
char* getDoorEventName2();
|
DUSK_CONST char* getDoorEventName2();
|
||||||
const char* getArcName();
|
const char* getArcName();
|
||||||
const char* getAnmArcName();
|
const char* getAnmArcName();
|
||||||
int getDoorType();
|
int getDoorType();
|
||||||
|
|||||||
@@ -14,11 +14,11 @@
|
|||||||
*/
|
*/
|
||||||
class daDbDoor00_c : public fopAc_ac_c {
|
class daDbDoor00_c : public fopAc_ac_c {
|
||||||
public:
|
public:
|
||||||
char* getAlwaysArcName();
|
DUSK_CONST char* getAlwaysArcName();
|
||||||
char* getDzb();
|
DUSK_CONST char* getDzb();
|
||||||
char* getDummyBmdName();
|
DUSK_CONST char* getDummyBmdName();
|
||||||
char* getBmdArcName();
|
DUSK_CONST char* getBmdArcName();
|
||||||
char* getBmdName();
|
DUSK_CONST char* getBmdName();
|
||||||
J3DModelData* getDoorModelData();
|
J3DModelData* getDoorModelData();
|
||||||
int CreateHeap();
|
int CreateHeap();
|
||||||
void calcMtx();
|
void calcMtx();
|
||||||
|
|||||||
@@ -29,11 +29,11 @@ public:
|
|||||||
|
|
||||||
typedef int (daKnob20_c::*actionFunc)();
|
typedef int (daKnob20_c::*actionFunc)();
|
||||||
|
|
||||||
char* getAlwaysArcName();
|
DUSK_CONST char* getAlwaysArcName();
|
||||||
char* getEvArcName();
|
DUSK_CONST char* getEvArcName();
|
||||||
char* getDzb();
|
DUSK_CONST char* getDzb();
|
||||||
char* getDummyBmd();
|
DUSK_CONST char* getDummyBmd();
|
||||||
char* getBmd();
|
DUSK_CONST char* getBmd();
|
||||||
J3DModelData* getDoorModelData();
|
J3DModelData* getDoorModelData();
|
||||||
int CreateHeap();
|
int CreateHeap();
|
||||||
void calcMtx();
|
void calcMtx();
|
||||||
|
|||||||
@@ -54,15 +54,15 @@ public:
|
|||||||
|
|
||||||
typedef int (daMBdoorL1_c::*actionFunc)();
|
typedef int (daMBdoorL1_c::*actionFunc)();
|
||||||
|
|
||||||
char* getAnmArcName();
|
DUSK_CONST char* getAnmArcName();
|
||||||
char* getArcName();
|
DUSK_CONST char* getArcName();
|
||||||
char* getAlwaysArcName();
|
DUSK_CONST char* getAlwaysArcName();
|
||||||
int getDoorType();
|
int getDoorType();
|
||||||
char* getOpenAnm();
|
DUSK_CONST char* getOpenAnm();
|
||||||
char* getCloseAnm();
|
DUSK_CONST char* getCloseAnm();
|
||||||
char* getBmd();
|
DUSK_CONST char* getBmd();
|
||||||
char* getBtk();
|
DUSK_CONST char* getBtk();
|
||||||
char* getDzb();
|
DUSK_CONST char* getDzb();
|
||||||
J3DModelData* getDoorModelData();
|
J3DModelData* getDoorModelData();
|
||||||
int CreateHeap();
|
int CreateHeap();
|
||||||
void calcMtx();
|
void calcMtx();
|
||||||
|
|||||||
@@ -45,12 +45,12 @@ public:
|
|||||||
ACTION_DEMO,
|
ACTION_DEMO,
|
||||||
};
|
};
|
||||||
|
|
||||||
char* getStopBmdName();
|
char DUSK_CONST* getStopBmdName();
|
||||||
J3DModelData* getStopModelData();
|
J3DModelData* getStopModelData();
|
||||||
char* getAlwaysArcName();
|
char DUSK_CONST* getAlwaysArcName();
|
||||||
char* getArcName();
|
char DUSK_CONST* getArcName();
|
||||||
char* getBmdName();
|
char DUSK_CONST* getBmdName();
|
||||||
char* getBtk();
|
char DUSK_CONST* getBtk();
|
||||||
J3DModelData* getModelData();
|
J3DModelData* getModelData();
|
||||||
f32 getSize2X();
|
f32 getSize2X();
|
||||||
int CreateHeap();
|
int CreateHeap();
|
||||||
@@ -115,7 +115,7 @@ public:
|
|||||||
int chkStopOpen();
|
int chkStopOpen();
|
||||||
int chkMakeKey();
|
int chkMakeKey();
|
||||||
|
|
||||||
virtual char* getDzbName();
|
virtual char DUSK_CONST* getDzbName();
|
||||||
virtual int getDemoAction();
|
virtual int getDemoAction();
|
||||||
|
|
||||||
void onFlag(u16 flag) { field_0x68e |= flag; }
|
void onFlag(u16 flag) { field_0x68e |= flag; }
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ public:
|
|||||||
/* 0x5B4 */ J3DModel* mpModel;
|
/* 0x5B4 */ J3DModel* mpModel;
|
||||||
/* 0x5B8 */ u8 mArrowType;
|
/* 0x5B8 */ u8 mArrowType;
|
||||||
/* 0x5B9 */ u8 mFlags;
|
/* 0x5B9 */ u8 mFlags;
|
||||||
/* 0x5BC */ char* mResName;
|
/* 0x5BC */ char DUSK_CONST* mResName;
|
||||||
/* 0x5C0 */ s16 field_0x5c0;
|
/* 0x5C0 */ s16 field_0x5c0;
|
||||||
/* 0x5C2 */ s16 mAction;
|
/* 0x5C2 */ s16 mAction;
|
||||||
/* 0x5C4 */ s16 mMode;
|
/* 0x5C4 */ s16 mMode;
|
||||||
|
|||||||
@@ -60,7 +60,7 @@ public:
|
|||||||
/* 0x5B5 */ u8 mDistanceParam;
|
/* 0x5B5 */ u8 mDistanceParam;
|
||||||
/* 0x5B6 */ u8 mType;
|
/* 0x5B6 */ u8 mType;
|
||||||
/* 0x5B7 */ u8 mPathIndex;
|
/* 0x5B7 */ u8 mPathIndex;
|
||||||
/* 0x5B8 */ char* mArcName;
|
/* 0x5B8 */ DUSK_CONST char* mArcName;
|
||||||
/* 0x5BC */ u8 field_0x5bc;
|
/* 0x5BC */ u8 field_0x5bc;
|
||||||
/* 0x5BD */ s8 mPathPoint;
|
/* 0x5BD */ s8 mPathPoint;
|
||||||
/* 0x5BE */ s8 mPathStep;
|
/* 0x5BE */ s8 mPathStep;
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ public:
|
|||||||
/* 0x05CC */ s16 target_ya;
|
/* 0x05CC */ s16 target_ya;
|
||||||
/* 0x05D0 */ mDoExt_McaMorfSO* anm_p;
|
/* 0x05D0 */ mDoExt_McaMorfSO* anm_p;
|
||||||
/* 0x05D4 */ Z2CreatureEnemy sound;
|
/* 0x05D4 */ Z2CreatureEnemy sound;
|
||||||
/* 0x0678 */ char* resName;
|
/* 0x0678 */ DUSK_CONST char* resName;
|
||||||
/* 0x067C */ int anm;
|
/* 0x067C */ int anm;
|
||||||
/* 0x0680 */ int field_0x680;
|
/* 0x0680 */ int field_0x680;
|
||||||
/* 0x0684 */ dJntCol_c mJntCol;
|
/* 0x0684 */ dJntCol_c mJntCol;
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ public:
|
|||||||
/* 0x05C8 */ s16 mTargetAngleY;
|
/* 0x05C8 */ s16 mTargetAngleY;
|
||||||
/* 0x05CC */ mDoExt_McaMorfSO* mpMorf;
|
/* 0x05CC */ mDoExt_McaMorfSO* mpMorf;
|
||||||
/* 0x05D0 */ Z2CreatureEnemy mSound;
|
/* 0x05D0 */ Z2CreatureEnemy mSound;
|
||||||
/* 0x0674 */ char* mpArcName;
|
/* 0x0674 */ char DUSK_CONST* mpArcName;
|
||||||
/* 0x0678 */ int mAnm;
|
/* 0x0678 */ int mAnm;
|
||||||
/* 0x067C */ u8 field_0x67c[0x680 - 0x67c];
|
/* 0x067C */ u8 field_0x67c[0x680 - 0x67c];
|
||||||
/* 0x0680 */ dJntCol_c mJntCol;
|
/* 0x0680 */ dJntCol_c mJntCol;
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ private:
|
|||||||
/* 0x6D4 */ f32 field_0x6d4;
|
/* 0x6D4 */ f32 field_0x6d4;
|
||||||
/* 0x6D8 */ s16 mFootJoints[4];
|
/* 0x6D8 */ s16 mFootJoints[4];
|
||||||
/* 0x6E0 */ s16 field_0x6e0;
|
/* 0x6E0 */ s16 field_0x6e0;
|
||||||
/* 0x6E4 */ char* mpResName;
|
/* 0x6E4 */ char DUSK_CONST* mpResName;
|
||||||
/* 0x6E8 */ u16 mDamageCooldownTimer;
|
/* 0x6E8 */ u16 mDamageCooldownTimer;
|
||||||
/* 0x6EA */ u8 mGenericTimer;
|
/* 0x6EA */ u8 mGenericTimer;
|
||||||
/* 0x6EC */ int mAttackTimer;
|
/* 0x6EC */ int mAttackTimer;
|
||||||
|
|||||||
@@ -99,7 +99,7 @@ public:
|
|||||||
/* 0x0000 */ fopEn_enemy_c enemy; ///< @brief Base enemy class instance.
|
/* 0x0000 */ fopEn_enemy_c enemy; ///< @brief Base enemy class instance.
|
||||||
/* 0x05AC */ request_of_phase_process_class phase; ///< @brief Phase process request handler.
|
/* 0x05AC */ request_of_phase_process_class phase; ///< @brief Phase process request handler.
|
||||||
/* 0x05B4 */ s16 ride_mode; ///< @brief Current sub-action mode within the run action.
|
/* 0x05B4 */ s16 ride_mode; ///< @brief Current sub-action mode within the run action.
|
||||||
/* 0x05B8 */ char* resName; ///< @brief Resource name for loading models/animations.
|
/* 0x05B8 */ char DUSK_CONST* resName; ///< @brief Resource name for loading models/animations.
|
||||||
/* 0x05BC */ u8 arg0; ///< @brief Creation parameter 1.
|
/* 0x05BC */ u8 arg0; ///< @brief Creation parameter 1.
|
||||||
/* 0x05BD */ u8 arg1; ///< @brief Creation parameter 2.
|
/* 0x05BD */ u8 arg1; ///< @brief Creation parameter 2.
|
||||||
/* 0x05BE */ u8 field_0x5be;
|
/* 0x05BE */ u8 field_0x5be;
|
||||||
|
|||||||
@@ -213,8 +213,8 @@ private:
|
|||||||
/* 0x750 */ int field_0x750;
|
/* 0x750 */ int field_0x750;
|
||||||
/* 0x754 */ int field_0x754;
|
/* 0x754 */ int field_0x754;
|
||||||
/* 0x758 */ int field_0x758;
|
/* 0x758 */ int field_0x758;
|
||||||
/* 0x75C */ char* mArcName;
|
/* 0x75C */ DUSK_CONST char* mArcName;
|
||||||
/* 0x760 */ char* mDemoName;
|
/* 0x760 */ DUSK_CONST char* mDemoName;
|
||||||
/* 0x764 */ u32 mShadowId;
|
/* 0x764 */ u32 mShadowId;
|
||||||
/* 0x768 */ dPath* mpPath1;
|
/* 0x768 */ dPath* mpPath1;
|
||||||
/* 0x76C */ dPath* mpPath2;
|
/* 0x76C */ dPath* mpPath2;
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ public:
|
|||||||
/* 0x5F4 */ s16 mYawToPlayer;
|
/* 0x5F4 */ s16 mYawToPlayer;
|
||||||
/* 0x5F6 */ s16 field_0x5f6;
|
/* 0x5F6 */ s16 field_0x5f6;
|
||||||
/* 0x5F8 */ s16 field_0x5f8;
|
/* 0x5F8 */ s16 field_0x5f8;
|
||||||
/* 0x5FC */ char* mResName;
|
/* 0x5FC */ DUSK_CONST char* mResName;
|
||||||
/* 0x600 */ mDoExt_McaMorf* mpMorf;
|
/* 0x600 */ mDoExt_McaMorf* mpMorf;
|
||||||
/* 0x604 */ J3DAnmTransform* mAnmTransform;
|
/* 0x604 */ J3DAnmTransform* mAnmTransform;
|
||||||
/* 0x608 */ u32 mShadowId;
|
/* 0x608 */ u32 mShadowId;
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ public:
|
|||||||
|
|
||||||
/* 0x0000 */ fopAc_ac_c actor;
|
/* 0x0000 */ fopAc_ac_c actor;
|
||||||
/* 0x0568 */ request_of_phase_process_class phase;
|
/* 0x0568 */ request_of_phase_process_class phase;
|
||||||
/* 0x0570 */ char* arcname;
|
/* 0x0570 */ DUSK_CONST char* arcname;
|
||||||
/* 0x0574 */ u8 arg0;
|
/* 0x0574 */ u8 arg0;
|
||||||
/* 0x0575 */ u8 arg1;
|
/* 0x0575 */ u8 arg1;
|
||||||
/* 0x0576 */ u8 arg2;
|
/* 0x0576 */ u8 arg2;
|
||||||
@@ -299,8 +299,13 @@ public:
|
|||||||
/* 0x168C */ u8 field_0x168c;
|
/* 0x168C */ u8 field_0x168c;
|
||||||
/* 0x168D */ u8 field_0x168d;
|
/* 0x168D */ u8 field_0x168d;
|
||||||
/* 0x168E */ u8 HIOInit;
|
/* 0x168E */ u8 HIOInit;
|
||||||
|
|
||||||
|
#if TARGET_PC
|
||||||
|
cXyz mLineInterpPrev[MG_ROD_LURE_LINE_LEN];
|
||||||
|
cXyz mLineInterpCurr[MG_ROD_LURE_LINE_LEN];
|
||||||
|
bool mLineInterpPrevValid;
|
||||||
|
bool mLineInterpCurrValid;
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
STATIC_ASSERT(sizeof(dmg_rod_class) == 0x1690);
|
|
||||||
|
|
||||||
#endif /* D_A_MG_ROD_H */
|
#endif /* D_A_MG_ROD_H */
|
||||||
|
|||||||
@@ -103,8 +103,8 @@ public:
|
|||||||
void animePlay();
|
void animePlay();
|
||||||
int setMcaMorfAnm(J3DAnmTransformKey*, f32, f32, int, int, int);
|
int setMcaMorfAnm(J3DAnmTransformKey*, f32, f32, int, int, int);
|
||||||
void setBtpAnm(J3DAnmTexPattern*, J3DModelData*, f32, int);
|
void setBtpAnm(J3DAnmTexPattern*, J3DModelData*, f32, int);
|
||||||
J3DAnmTransformKey* getTrnsfrmKeyAnm(char*);
|
J3DAnmTransformKey* getTrnsfrmKeyAnm(DUSK_CONST char*);
|
||||||
J3DAnmTexPattern* getTexPtrnAnm(char*);
|
J3DAnmTexPattern* getTexPtrnAnm(DUSK_CONST char*);
|
||||||
int checkEndAnm(J3DFrameCtrl*);
|
int checkEndAnm(J3DFrameCtrl*);
|
||||||
int checkEndAnm(f32);
|
int checkEndAnm(f32);
|
||||||
u8 getItemNumMax();
|
u8 getItemNumMax();
|
||||||
|
|||||||
@@ -519,7 +519,7 @@ public:
|
|||||||
/* 0x568 */ daNpcT_faceMotionAnmData_c const* mpFaceMotionAnmData;
|
/* 0x568 */ daNpcT_faceMotionAnmData_c const* mpFaceMotionAnmData;
|
||||||
/* 0x56C */ daNpcT_motionAnmData_c const* mpMotionAnmData;
|
/* 0x56C */ daNpcT_motionAnmData_c const* mpMotionAnmData;
|
||||||
/* 0x570 */ daNpcT_evtData_c const* mpEvtData;
|
/* 0x570 */ daNpcT_evtData_c const* mpEvtData;
|
||||||
/* 0x574 */ char** mpArcNames;
|
/* 0x574 */ DUSK_CONST char* DUSK_CONST* mpArcNames;
|
||||||
/* 0x578 */ mDoExt_McaMorfSO* mpMorf[2];
|
/* 0x578 */ mDoExt_McaMorfSO* mpMorf[2];
|
||||||
/* 0x580 */ Z2Creature mSound;
|
/* 0x580 */ Z2Creature mSound;
|
||||||
/* 0x610 */ mDoExt_bckAnm mBckAnm;
|
/* 0x610 */ mDoExt_bckAnm mBckAnm;
|
||||||
@@ -627,7 +627,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum, daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
int i_motionStepNum, daNpcT_evtData_c const* i_evtData, DUSK_CONST char* DUSK_CONST* i_arcNames)
|
||||||
:
|
:
|
||||||
mpFaceMotionAnmData(i_faceMotionAnmData),
|
mpFaceMotionAnmData(i_faceMotionAnmData),
|
||||||
mpMotionAnmData(i_motionAnmData),
|
mpMotionAnmData(i_motionAnmData),
|
||||||
@@ -654,8 +654,8 @@ public:
|
|||||||
int setBtkAnm(J3DAnmTextureSRTKey*, J3DModelData*, f32, int);
|
int setBtkAnm(J3DAnmTextureSRTKey*, J3DModelData*, f32, int);
|
||||||
int setBrkAnm(J3DAnmTevRegKey*, J3DModelData*, f32, int);
|
int setBrkAnm(J3DAnmTevRegKey*, J3DModelData*, f32, int);
|
||||||
int setBpkAnm(J3DAnmColor*, J3DModelData*, f32, int);
|
int setBpkAnm(J3DAnmColor*, J3DModelData*, f32, int);
|
||||||
int loadRes(s8 const*, char const**);
|
int loadRes(s8 const*, char const* DUSK_CONST*);
|
||||||
void deleteRes(s8 const*, char const**);
|
void deleteRes(s8 const*, char const* DUSK_CONST*);
|
||||||
int execute();
|
int execute();
|
||||||
int draw(BOOL, BOOL, f32, GXColorS10*, f32, BOOL, BOOL, BOOL);
|
int draw(BOOL, BOOL, f32, GXColorS10*, f32, BOOL, BOOL, BOOL);
|
||||||
void setEnvTevColor();
|
void setEnvTevColor();
|
||||||
|
|||||||
@@ -86,12 +86,12 @@ public:
|
|||||||
class daBaseNpc_c : public fopAc_ac_c {
|
class daBaseNpc_c : public fopAc_ac_c {
|
||||||
public:
|
public:
|
||||||
daBaseNpc_c();
|
daBaseNpc_c();
|
||||||
J3DAnmTransform* getTrnsfrmKeyAnmP(char*, int);
|
J3DAnmTransform* getTrnsfrmKeyAnmP(char DUSK_CONST*, int);
|
||||||
int setMcaMorfAnm(J3DAnmTransformKey*, f32, f32, int, int, int);
|
int setMcaMorfAnm(J3DAnmTransformKey*, f32, f32, int, int, int);
|
||||||
int setBckAnm(J3DAnmTransform*, f32, int, int, int, bool);
|
int setBckAnm(J3DAnmTransform*, f32, int, int, int, bool);
|
||||||
J3DAnmTransform* getTexPtrnAnmP(char*, int);
|
J3DAnmTransform* getTexPtrnAnmP(char DUSK_CONST*, int);
|
||||||
int setBtpAnm(J3DAnmTexPattern*, J3DModelData*, f32, int);
|
int setBtpAnm(J3DAnmTexPattern*, J3DModelData*, f32, int);
|
||||||
void orderEvent(int, char*);
|
void orderEvent(int, char DUSK_CONST*);
|
||||||
void setEnvTevColor();
|
void setEnvTevColor();
|
||||||
void setRoomNo();
|
void setRoomNo();
|
||||||
int checkEndAnm(f32);
|
int checkEndAnm(f32);
|
||||||
@@ -128,7 +128,7 @@ public:
|
|||||||
/* 0x808 */ mDoExt_btpAnm mBtp;
|
/* 0x808 */ mDoExt_btpAnm mBtp;
|
||||||
/* 0x820 */ mDoExt_btkAnm mBtk;
|
/* 0x820 */ mDoExt_btkAnm mBtk;
|
||||||
/* 0x838 */ s16 field_0x838;
|
/* 0x838 */ s16 field_0x838;
|
||||||
/* 0x83C */ u16* field_0x83c;
|
/* 0x83C */ u16 DUSK_CONST* field_0x83c;
|
||||||
/* 0x840 */ u16 field_0x840;
|
/* 0x840 */ u16 field_0x840;
|
||||||
/* 0x842 */ u16 field_0x842;
|
/* 0x842 */ u16 field_0x842;
|
||||||
/* 0x844 */ u8 field_0x844;
|
/* 0x844 */ u8 field_0x844;
|
||||||
|
|||||||
@@ -311,10 +311,10 @@ public:
|
|||||||
static void* srchActor(void*, void*);
|
static void* srchActor(void*, void*);
|
||||||
|
|
||||||
void initialize();
|
void initialize();
|
||||||
J3DAnmTransformKey* getTrnsfrmKeyAnmP(char*, int);
|
J3DAnmTransformKey* getTrnsfrmKeyAnmP(DUSK_CONST char*, int);
|
||||||
J3DAnmTexPattern* getTexPtrnAnmP(char*, int);
|
J3DAnmTexPattern* getTexPtrnAnmP(DUSK_CONST char*, int);
|
||||||
J3DAnmTextureSRTKey* getTexSRTKeyAnmP(char*, int);
|
J3DAnmTextureSRTKey* getTexSRTKeyAnmP(DUSK_CONST char*, int);
|
||||||
J3DAnmTevRegKey* getTevRegKeyAnmP(char*, int);
|
J3DAnmTevRegKey* getTevRegKeyAnmP(DUSK_CONST char*, int);
|
||||||
BOOL setMcaMorfAnm(J3DAnmTransformKey* i_anm, f32 i_rate, f32 i_morf, int i_attr,
|
BOOL setMcaMorfAnm(J3DAnmTransformKey* i_anm, f32 i_rate, f32 i_morf, int i_attr,
|
||||||
int i_start, int i_end);
|
int i_start, int i_end);
|
||||||
BOOL setBckAnm(J3DAnmTransform* i_bck, f32 i_rate, int i_attr, int i_start,
|
BOOL setBckAnm(J3DAnmTransform* i_bck, f32 i_rate, int i_attr, int i_start,
|
||||||
@@ -336,8 +336,8 @@ public:
|
|||||||
BOOL hitChk2(dCcD_Cyl*, BOOL, BOOL);
|
BOOL hitChk2(dCcD_Cyl*, BOOL, BOOL);
|
||||||
void setDamage(int, int, int);
|
void setDamage(int, int, int);
|
||||||
int ctrlMsgAnm(int&, int&, fopAc_ac_c*, BOOL);
|
int ctrlMsgAnm(int&, int&, fopAc_ac_c*, BOOL);
|
||||||
void orderEvent(int, char*, u16, u16, u8, u16);
|
void orderEvent(int, DUSK_CONST char*, u16, u16, u8, u16);
|
||||||
void changeEvent(char*, char*, u16, u16);
|
void changeEvent(DUSK_CONST char*, DUSK_CONST char*, u16, u16);
|
||||||
BOOL chkActorInSight(fopAc_ac_c*, f32);
|
BOOL chkActorInSight(fopAc_ac_c*, f32);
|
||||||
BOOL chkActorInArea(fopAc_ac_c*, cXyz, cXyz, s16);
|
BOOL chkActorInArea(fopAc_ac_c*, cXyz, cXyz, s16);
|
||||||
BOOL chkActorInAttnArea(fopAc_ac_c*, fopAc_ac_c*, int);
|
BOOL chkActorInAttnArea(fopAc_ac_c*, fopAc_ac_c*, int);
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ public:
|
|||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -171,8 +171,8 @@ public:
|
|||||||
u8 getPathID() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
u8 getPathID() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
||||||
void setLastIn() { mLastGoatIn = true; }
|
void setLastIn() { mLastGoatIn = true; }
|
||||||
|
|
||||||
static char* mCutNameList[7];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[7];
|
||||||
static cutFunc mCutList[7];
|
static cutFunc DUSK_CONST mCutList[7];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_ARU_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_ARU_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -135,7 +135,7 @@ public:
|
|||||||
inline bool step(s16, int, f32);
|
inline bool step(s16, int, f32);
|
||||||
inline void playExpression();
|
inline void playExpression();
|
||||||
|
|
||||||
static EventFn mEvtSeqList[2];
|
static EventFn DUSK_CONST mEvtSeqList[2];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2Creature mCreatureSound;
|
/* 0xB48 */ Z2Creature mCreatureSound;
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -117,8 +117,8 @@ public:
|
|||||||
return rv;
|
return rv;
|
||||||
}
|
}
|
||||||
|
|
||||||
static char* mCutNameList[4];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[4];
|
||||||
static cutFunc mCutList[4];
|
static cutFunc DUSK_CONST mCutList[4];
|
||||||
|
|
||||||
/* 0x0F7C */ mDoExt_McaMorfSO* mpScoopMorf;
|
/* 0x0F7C */ mDoExt_McaMorfSO* mpScoopMorf;
|
||||||
/* 0x0F80 */ NPC_BANS_HIO_CLASS* mHIO;
|
/* 0x0F80 */ NPC_BANS_HIO_CLASS* mHIO;
|
||||||
|
|||||||
@@ -112,7 +112,7 @@ public:
|
|||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -140,8 +140,8 @@ public:
|
|||||||
u8 getPathID() { return (fopAcM_GetParam(this) & 0xff00) >> 8; }
|
u8 getPathID() { return (fopAcM_GetParam(this) & 0xff00) >> 8; }
|
||||||
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xff0000) >> 16; }
|
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xff0000) >> 16; }
|
||||||
|
|
||||||
static char* mCutNameList[15];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[15];
|
||||||
static cutFunc mCutList[15];
|
static cutFunc DUSK_CONST mCutList[15];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0E40 */ mDoExt_McaMorfSO* mpCupModelMorf;
|
/* 0x0E40 */ mDoExt_McaMorfSO* mpCupModelMorf;
|
||||||
|
|||||||
@@ -124,7 +124,7 @@ public:
|
|||||||
return var_r30;
|
return var_r30;
|
||||||
}
|
}
|
||||||
|
|
||||||
static EventFn mEvtSeqList[];
|
static EventFn DUSK_CONST mEvtSeqList[];
|
||||||
|
|
||||||
/* 0xB48 */ Z2Creature mSound;
|
/* 0xB48 */ Z2Creature mSound;
|
||||||
/* 0xBD8 */ u8 field_0xBD8[0xBDC - 0xBD8];
|
/* 0xBD8 */ u8 field_0xBD8[0xBDC - 0xBD8];
|
||||||
|
|||||||
@@ -89,7 +89,7 @@ public:
|
|||||||
daNpc_Bou_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
daNpc_Bou_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
||||||
daNpcT_evtData_c const* param_7, char** param_8)
|
daNpcT_evtData_c const* param_7, char DUSK_CONST* DUSK_CONST* param_8)
|
||||||
:
|
:
|
||||||
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
||||||
{}
|
{}
|
||||||
@@ -114,8 +114,8 @@ public:
|
|||||||
virtual int drawDbgInfo();
|
virtual int drawDbgInfo();
|
||||||
virtual void changeAnm(int*, int*);
|
virtual void changeAnm(int*, int*);
|
||||||
|
|
||||||
static char* mCutNameList[9];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[9];
|
||||||
static cutFunc mCutList[9];
|
static cutFunc DUSK_CONST mCutList[9];
|
||||||
|
|
||||||
int getFlowNodeNo() {
|
int getFlowNodeNo() {
|
||||||
u16 nodeNo = home.angle.x;
|
u16 nodeNo = home.angle.x;
|
||||||
|
|||||||
@@ -102,7 +102,7 @@ public:
|
|||||||
void setFear() { mFear = true; }
|
void setFear() { mFear = true; }
|
||||||
void setTalkFlag() { mTalkFlag = true; }
|
void setTalkFlag() { mTalkFlag = true; }
|
||||||
|
|
||||||
static eventFunc mEvtSeqList[1];
|
static eventFunc DUSK_CONST mEvtSeqList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2CreatureCitizen mSound;
|
/* 0xB48 */ Z2CreatureCitizen mSound;
|
||||||
|
|||||||
@@ -100,7 +100,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum, daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
int i_motionStepNum, daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -124,8 +124,8 @@ public:
|
|||||||
|
|
||||||
u8 getMaxNumItem() { return (fopAcM_GetParam(this) & 0xF000000) >> 24; }
|
u8 getMaxNumItem() { return (fopAcM_GetParam(this) & 0xF000000) >> 24; }
|
||||||
|
|
||||||
static char* mCutNameList[1];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[1];
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0F7C */ NPC_CLERKA_HIO_CLASS* mpHIO;
|
/* 0x0F7C */ NPC_CLERKA_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -113,7 +113,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum, daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
int i_motionStepNum, daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -137,8 +137,8 @@ public:
|
|||||||
|
|
||||||
u8 getMaxNumItem() { return (fopAcM_GetParam(this) & 0xF000000) >> 24; }
|
u8 getMaxNumItem() { return (fopAcM_GetParam(this) & 0xF000000) >> 24; }
|
||||||
|
|
||||||
static char* mCutNameList[1];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[1];
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0F7C */ mDoExt_bpkAnm mBpkAnm2;
|
/* 0x0F7C */ mDoExt_bpkAnm mBpkAnm2;
|
||||||
|
|||||||
@@ -91,7 +91,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -125,8 +125,8 @@ public:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static char* mCutNameList[1];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[1];
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0F7C */ NPC_CLERKT_HIO_CLASS* mpHIO;
|
/* 0x0F7C */ NPC_CLERKT_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -66,7 +66,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames)
|
i_arcNames)
|
||||||
@@ -133,8 +133,8 @@ public:
|
|||||||
return (fopAcM_GetParam(this) & 0xFF00) >> 8;
|
return (fopAcM_GetParam(this) & 0xFF00) >> 8;
|
||||||
}
|
}
|
||||||
|
|
||||||
static char* mCutNameList[1];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[1];
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_DOC_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_DOC_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -78,7 +78,7 @@ public:
|
|||||||
inline int getTimeHour();
|
inline int getTimeHour();
|
||||||
inline bool isDummyTalk();
|
inline bool isDummyTalk();
|
||||||
|
|
||||||
static EventFn mEvtSeqList[1];
|
static EventFn DUSK_CONST mEvtSeqList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2CreatureCitizen mSound;
|
/* 0xB48 */ Z2CreatureCitizen mSound;
|
||||||
|
|||||||
@@ -256,7 +256,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -294,8 +294,8 @@ public:
|
|||||||
u8 getSceneNo1() { return (fopAcM_GetParam(this) >> 8) & 0xFF; }
|
u8 getSceneNo1() { return (fopAcM_GetParam(this) >> 8) & 0xFF; }
|
||||||
u8 getSceneNo2() { return (fopAcM_GetParam(this) >> 16) & 0xFF; }
|
u8 getSceneNo2() { return (fopAcM_GetParam(this) >> 16) & 0xFF; }
|
||||||
|
|
||||||
static char* mCutNameList[18];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[18];
|
||||||
static cutFunc mCutList[18];
|
static cutFunc DUSK_CONST mCutList[18];
|
||||||
private:
|
private:
|
||||||
/* 0x0E40 */ NPC_FAIRY_HIO_CLASS* mHIO;
|
/* 0x0E40 */ NPC_FAIRY_HIO_CLASS* mHIO;
|
||||||
/* 0x0E44 */ dCcD_Cyl mCyl;
|
/* 0x0E44 */ dCcD_Cyl mCyl;
|
||||||
|
|||||||
@@ -71,7 +71,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3,
|
||||||
int param_4,
|
int param_4,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5,
|
||||||
int param_6, daNpcT_evtData_c const* param_7, char** param_8)
|
int param_6, daNpcT_evtData_c const* param_7, DUSK_CONST char* DUSK_CONST* param_8)
|
||||||
: daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8) {}
|
: daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8) {}
|
||||||
|
|
||||||
u8 getType() { return fopAcM_GetParam(this) & 0xFF; }
|
u8 getType() { return fopAcM_GetParam(this) & 0xFF; }
|
||||||
@@ -90,8 +90,8 @@ public:
|
|||||||
|
|
||||||
int getSeneNo() { return (fopAcM_GetParam(this) >> 8) & 0xFF; }
|
int getSeneNo() { return (fopAcM_GetParam(this) >> 8) & 0xFF; }
|
||||||
|
|
||||||
static char* mCutNameList[1];
|
static DUSK_CONST char* mCutNameList[1];
|
||||||
static cutFunc mCutList[1];
|
static DUSK_CONST cutFunc mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_FAIRY_SEIREI_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_FAIRY_SEIREI_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -96,8 +96,8 @@ public:
|
|||||||
s32 getNeckJointNo() { return 3; }
|
s32 getNeckJointNo() { return 3; }
|
||||||
s32 getBackboneJointNo() { return 1; }
|
s32 getBackboneJointNo() { return 1; }
|
||||||
|
|
||||||
static char* mCutNameList[1];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[1];
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_GND_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_GND_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -138,9 +138,9 @@ public:
|
|||||||
void addCarryNum() { field_0x1692++; }
|
void addCarryNum() { field_0x1692++; }
|
||||||
u8 getPathNoFromParam() { return home.angle.z; }
|
u8 getPathNoFromParam() { return home.angle.z; }
|
||||||
void setGateWalk() { field_0x14D0 = 1; }
|
void setGateWalk() { field_0x14D0 = 1; }
|
||||||
static char* mEvtCutNameList[12];
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList[12];
|
||||||
typedef BOOL (daNpc_grA_c::*cut_type)(int);
|
typedef BOOL (daNpc_grA_c::*cut_type)(int);
|
||||||
static cut_type mEvtCutList[];
|
static cut_type DUSK_CONST mEvtCutList[];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
typedef BOOL (daNpc_grA_c::*daNpc_grA_c_Action)(void*);
|
typedef BOOL (daNpc_grA_c::*daNpc_grA_c_Action)(void*);
|
||||||
|
|||||||
@@ -89,8 +89,8 @@ public:
|
|||||||
void setPrtcl();
|
void setPrtcl();
|
||||||
void adjustShapeAngle() {}
|
void adjustShapeAngle() {}
|
||||||
|
|
||||||
static char* mEvtCutNameList;
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList;
|
||||||
static EventFn mEvtCutList[1];
|
static EventFn DUSK_CONST mEvtCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2Creature mSound;
|
/* 0xB48 */ Z2Creature mSound;
|
||||||
|
|||||||
@@ -81,8 +81,8 @@ public:
|
|||||||
BOOL ECut_nodToGrz(int);
|
BOOL ECut_nodToGrz(int);
|
||||||
void adjustShapeAngle() {}
|
void adjustShapeAngle() {}
|
||||||
|
|
||||||
static char* mEvtCutNameList[2];
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList[2];
|
||||||
static cutFunc mEvtCutList[2];
|
static cutFunc DUSK_CONST mEvtCutList[2];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2Creature mSound;
|
/* 0xB48 */ Z2Creature mSound;
|
||||||
|
|||||||
@@ -120,7 +120,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -131,8 +131,8 @@ public:
|
|||||||
BOOL checkChangeJoint(int param_0) { return param_0 == JNT_HEAD; }
|
BOOL checkChangeJoint(int param_0) { return param_0 == JNT_HEAD; }
|
||||||
BOOL checkRemoveJoint(int param_0) { return param_0 == JNT_MOUTH; }
|
BOOL checkRemoveJoint(int param_0) { return param_0 == JNT_MOUTH; }
|
||||||
|
|
||||||
static char* mCutNameList[2];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[2];
|
||||||
static cutFunc mCutList[2];
|
static cutFunc DUSK_CONST mCutList[2];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0F7C */ NPC_GRM_HIO_CLASS* mpHIO;
|
/* 0x0F7C */ NPC_GRM_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -113,7 +113,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -124,8 +124,8 @@ public:
|
|||||||
BOOL checkRemoveJoint(int param_1) { return param_1 == JNT_MOUTH; }
|
BOOL checkRemoveJoint(int param_1) { return param_1 == JNT_MOUTH; }
|
||||||
u16 getEyeballMaterialNo() { return 1; };
|
u16 getEyeballMaterialNo() { return 1; };
|
||||||
|
|
||||||
static char* mCutNameList;
|
static char DUSK_CONST* DUSK_CONST mCutNameList;
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0F7C */ NPC_GRMC_HIO_CLASS* mpHIO;
|
/* 0x0F7C */ NPC_GRMC_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -85,8 +85,8 @@ public:
|
|||||||
int test(void*);
|
int test(void*);
|
||||||
void adjustShapeAngle() {}
|
void adjustShapeAngle() {}
|
||||||
|
|
||||||
static char* mEvtCutNameList[3];
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList[3];
|
||||||
static cutFunc mEvtCutList[3];
|
static cutFunc DUSK_CONST mEvtCutList[3];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2Creature mSound;
|
/* 0xB48 */ Z2Creature mSound;
|
||||||
|
|||||||
@@ -83,8 +83,8 @@ public:
|
|||||||
int test(void*);
|
int test(void*);
|
||||||
void adjustShapeAngle() {}
|
void adjustShapeAngle() {}
|
||||||
|
|
||||||
static char* mEvtCutNameList;
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList;
|
||||||
static cutFunc mEvtCutList[1];
|
static cutFunc DUSK_CONST mEvtCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2Creature mSound;
|
/* 0xB48 */ Z2Creature mSound;
|
||||||
|
|||||||
@@ -84,8 +84,8 @@ public:
|
|||||||
void setPrtcl();
|
void setPrtcl();
|
||||||
void adjustShapeAngle() {}
|
void adjustShapeAngle() {}
|
||||||
|
|
||||||
static char* mEvtCutNameList[2];
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList[2];
|
||||||
static cutFunc mEvtCutList[2];
|
static cutFunc DUSK_CONST mEvtCutList[2];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2Creature mSound;
|
/* 0xB48 */ Z2Creature mSound;
|
||||||
|
|||||||
@@ -116,8 +116,8 @@ public:
|
|||||||
|
|
||||||
u8 getPathNoFromParam() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
u8 getPathNoFromParam() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
||||||
|
|
||||||
static char* mEvtCutNameList[7];
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList[7];
|
||||||
static cutFunc mEvtCutList[7];
|
static cutFunc DUSK_CONST mEvtCutList[7];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0B48 */ Z2Creature mSound;
|
/* 0x0B48 */ Z2Creature mSound;
|
||||||
|
|||||||
@@ -104,8 +104,8 @@ public:
|
|||||||
void setHowlingEndFlag() { field_0xe1c = 2; }
|
void setHowlingEndFlag() { field_0xe1c = 2; }
|
||||||
void setHowlingFlag() { field_0xe1c = 1; }
|
void setHowlingFlag() { field_0xe1c = 1; }
|
||||||
|
|
||||||
static char* mEvtCutNameList[5];
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList[5];
|
||||||
static cutFunc mEvtCutList[5];
|
static cutFunc DUSK_CONST mEvtCutList[5];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2Creature mSound;
|
/* 0xB48 */ Z2Creature mSound;
|
||||||
|
|||||||
@@ -194,7 +194,7 @@ public:
|
|||||||
daNpc_Hanjo_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
daNpc_Hanjo_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
||||||
daNpcT_evtData_c const* param_7, char** param_8) :
|
daNpcT_evtData_c const* param_7, char DUSK_CONST* DUSK_CONST* param_8) :
|
||||||
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
||||||
{}
|
{}
|
||||||
u16 getEyeballMaterialNo() { return 2; }
|
u16 getEyeballMaterialNo() { return 2; }
|
||||||
@@ -218,9 +218,9 @@ public:
|
|||||||
u8 getPathID() { return (fopAcM_GetParam(this) & 0xff00) >> 8; }
|
u8 getPathID() { return (fopAcM_GetParam(this) & 0xff00) >> 8; }
|
||||||
|
|
||||||
static dCcD_SrcGObjInf const mStoneCcDObjInfo;
|
static dCcD_SrcGObjInf const mStoneCcDObjInfo;
|
||||||
static char* mCutNameList[6];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[6];
|
||||||
static cutFunc mCutList[6];
|
static cutFunc DUSK_CONST mCutList[6];
|
||||||
static dCcD_SrcSph mStoneCcDSph;
|
static dCcD_SrcSph DUSK_CONST mStoneCcDSph;
|
||||||
private:
|
private:
|
||||||
/* 0x0E40 */ NPC_HANJO_HIO_CLASS* mpHIO;
|
/* 0x0E40 */ NPC_HANJO_HIO_CLASS* mpHIO;
|
||||||
/* 0x0E44 */ J3DModel* mModel1;
|
/* 0x0E44 */ J3DModel* mModel1;
|
||||||
|
|||||||
@@ -91,7 +91,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames)
|
i_arcNames)
|
||||||
@@ -125,8 +125,8 @@ public:
|
|||||||
bool getGameStartFlag() { return mGameStartFlag; }
|
bool getGameStartFlag() { return mGameStartFlag; }
|
||||||
void setPotBreakFlag() { mPotBreakFlag = true; }
|
void setPotBreakFlag() { mPotBreakFlag = true; }
|
||||||
|
|
||||||
static char* mCutNameList[8];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[8];
|
||||||
static cutFunc mCutList[];
|
static cutFunc DUSK_CONST mCutList[];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_HOZ_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_HOZ_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -138,7 +138,7 @@ public:
|
|||||||
daNpc_Jagar_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
daNpc_Jagar_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
||||||
daNpcT_evtData_c const* param_7, char** param_8) :
|
daNpcT_evtData_c const* param_7, char DUSK_CONST* DUSK_CONST* param_8) :
|
||||||
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
||||||
{}
|
{}
|
||||||
u16 getEyeballMaterialNo() { return MAT_JAGA_EYEBALL; }
|
u16 getEyeballMaterialNo() { return MAT_JAGA_EYEBALL; }
|
||||||
@@ -223,8 +223,8 @@ public:
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static char* mCutNameList[7];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[7];
|
||||||
static cutFunc mCutList[7];
|
static cutFunc DUSK_CONST mCutList[7];
|
||||||
private:
|
private:
|
||||||
/* 0x0E40 */ NPC_JAGAR_HIO_CLASS* mpHIO;
|
/* 0x0E40 */ NPC_JAGAR_HIO_CLASS* mpHIO;
|
||||||
/* 0x0E44 */ dCcD_Cyl mCyl1;
|
/* 0x0E44 */ dCcD_Cyl mCyl1;
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames)
|
i_arcNames)
|
||||||
@@ -113,8 +113,8 @@ public:
|
|||||||
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
||||||
u8 getBitSW2() { return (fopAcM_GetParam(this) & 0xFF0000) >> 16; }
|
u8 getBitSW2() { return (fopAcM_GetParam(this) & 0xFF0000) >> 16; }
|
||||||
|
|
||||||
static char* mCutNameList[4];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[4];
|
||||||
static int (daNpc_Kakashi_c::*mCutList[])(int);
|
static int (daNpc_Kakashi_c::* DUSK_CONST mCutList[])(int);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0E40 */ NPC_KAKASHI_HIO_CLASS* mpHIO;
|
/* 0x0E40 */ NPC_KAKASHI_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -120,7 +120,7 @@ public:
|
|||||||
void chgWeightLight() { mCcStts.SetWeight(0xD8); }
|
void chgWeightLight() { mCcStts.SetWeight(0xD8); }
|
||||||
BOOL pl_front_check() { return actor_front_check(daPy_getPlayerActorClass()); }
|
BOOL pl_front_check() { return actor_front_check(daPy_getPlayerActorClass()); }
|
||||||
|
|
||||||
static EventFn mEvtSeqList[1];
|
static EventFn DUSK_CONST mEvtSeqList[1];
|
||||||
static daTagEscape_c* mTargetTag;
|
static daTagEscape_c* mTargetTag;
|
||||||
static f32 mTargetTagDist;
|
static f32 mTargetTagDist;
|
||||||
static s16 mWolfAngle;
|
static s16 mWolfAngle;
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ public:
|
|||||||
void chgWeightLight() { mCcStts.SetWeight(0xD8); }
|
void chgWeightLight() { mCcStts.SetWeight(0xD8); }
|
||||||
BOOL pl_front_check() { return actor_front_check(daPy_getPlayerActorClass()); }
|
BOOL pl_front_check() { return actor_front_check(daPy_getPlayerActorClass()); }
|
||||||
|
|
||||||
static EventFn mEvtSeqList[1];
|
static EventFn DUSK_CONST mEvtSeqList[1];
|
||||||
static daTagEscape_c* mTargetTag;
|
static daTagEscape_c* mTargetTag;
|
||||||
static f32 mTargetTagDist;
|
static f32 mTargetTagDist;
|
||||||
static s16 mWolfAngle;
|
static s16 mWolfAngle;
|
||||||
|
|||||||
@@ -71,7 +71,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames)
|
i_arcNames)
|
||||||
@@ -118,8 +118,8 @@ public:
|
|||||||
return mpMorf[0]->getModel()->getAnmMtx(5);
|
return mpMorf[0]->getModel()->getAnmMtx(5);
|
||||||
}
|
}
|
||||||
|
|
||||||
static char* mCutNameList[3];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[3];
|
||||||
static int (daNpc_Kkri_c::*mCutList[])(int);
|
static int (daNpc_Kkri_c::* DUSK_CONST mCutList[])(int);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_KKRI_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_KKRI_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ public:
|
|||||||
/* 0x05AC */ const daNpcT_faceMotionAnmData_c* mpFaceMotionAnmData;
|
/* 0x05AC */ const daNpcT_faceMotionAnmData_c* mpFaceMotionAnmData;
|
||||||
/* 0x05B0 */ const daNpcT_motionAnmData_c* mpMotionAnmData;
|
/* 0x05B0 */ const daNpcT_motionAnmData_c* mpMotionAnmData;
|
||||||
/* 0x05B4 */ const daNpcT_evtData_c* mpEventData;
|
/* 0x05B4 */ const daNpcT_evtData_c* mpEventData;
|
||||||
/* 0x05B8 */ char** mpArcNames;
|
/* 0x05B8 */ char DUSK_CONST* DUSK_CONST* mpArcNames;
|
||||||
/* 0x05BC */ mDoExt_McaMorfSO* mpModelMorf[2];
|
/* 0x05BC */ mDoExt_McaMorfSO* mpModelMorf[2];
|
||||||
/* 0x05C4 */ Z2Creature mSound;
|
/* 0x05C4 */ Z2Creature mSound;
|
||||||
/* 0x0654 */ mDoExt_bckAnm mBckAnm;
|
/* 0x0654 */ mDoExt_bckAnm mBckAnm;
|
||||||
@@ -322,8 +322,8 @@ public:
|
|||||||
int setMcaMorfAnm(J3DAnmTransformKey*, f32, f32, int, int, int);
|
int setMcaMorfAnm(J3DAnmTransformKey*, f32, f32, int, int, int);
|
||||||
BOOL setBtpAnm(J3DAnmTexPattern*, J3DModelData*, f32, int);
|
BOOL setBtpAnm(J3DAnmTexPattern*, J3DModelData*, f32, int);
|
||||||
BOOL setBtkAnm(J3DAnmTextureSRTKey*, J3DModelData*, f32, int);
|
BOOL setBtkAnm(J3DAnmTextureSRTKey*, J3DModelData*, f32, int);
|
||||||
int loadRes(s8 const*, char const**);
|
int loadRes(s8 const*, char const* DUSK_CONST*);
|
||||||
void deleteRes(s8 const*, char const**);
|
void deleteRes(s8 const*, char const* DUSK_CONST*);
|
||||||
int execute();
|
int execute();
|
||||||
int draw(int, int, f32, GXColorS10*, f32, int, int, int);
|
int draw(int, int, f32, GXColorS10*, f32, int, int, int);
|
||||||
void setEnvTevColor();
|
void setEnvTevColor();
|
||||||
@@ -355,7 +355,7 @@ public:
|
|||||||
daNpcT_motionAnmData_c const* param_1,
|
daNpcT_motionAnmData_c const* param_1,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_2, int param_3,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_2, int param_3,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_4, int param_5,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_4, int param_5,
|
||||||
daNpcT_evtData_c const* param_6, char** param_7)
|
daNpcT_evtData_c const* param_6, char DUSK_CONST* DUSK_CONST* param_7)
|
||||||
: mpFaceMotionAnmData(param_0), mpMotionAnmData(param_1), mFaceMotionSeqMngr(param_2, param_3),
|
: mpFaceMotionAnmData(param_0), mpMotionAnmData(param_1), mFaceMotionSeqMngr(param_2, param_3),
|
||||||
mMotionSeqMngr(param_4, param_5), mpEventData(param_6), mpArcNames(param_7)
|
mMotionSeqMngr(param_4, param_5), mpEventData(param_6), mpArcNames(param_7)
|
||||||
{
|
{
|
||||||
@@ -413,8 +413,8 @@ public:
|
|||||||
virtual bool afterSetMotionAnm(int, int, f32, int);
|
virtual bool afterSetMotionAnm(int, int, f32, int);
|
||||||
|
|
||||||
static const dCcD_SrcGObjInf mCcDObjData;
|
static const dCcD_SrcGObjInf mCcDObjData;
|
||||||
static char* mCutNameList[21];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[21];
|
||||||
static cutFunc mCutList[21];
|
static cutFunc DUSK_CONST mCutList[21];
|
||||||
static dCcD_SrcCyl mCcDCyl;
|
static dCcD_SrcCyl mCcDCyl;
|
||||||
static dCcD_SrcSph mCcDSph;
|
static dCcD_SrcSph mCcDSph;
|
||||||
static s16 mSrchName;
|
static s16 mSrchName;
|
||||||
|
|||||||
@@ -75,13 +75,13 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
|
|
||||||
static char* mCutNameList[1];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[1];
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_KNJ_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_KNJ_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -93,7 +93,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -120,8 +120,8 @@ public:
|
|||||||
virtual void changeAnm(int*, int*);
|
virtual void changeAnm(int*, int*);
|
||||||
virtual void changeBck(int*, int*);
|
virtual void changeBck(int*, int*);
|
||||||
|
|
||||||
static char* mCutNameList[11];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[11];
|
||||||
static cutFunc mCutList[11];
|
static cutFunc DUSK_CONST mCutList[11];
|
||||||
|
|
||||||
u32 getFlowNodeNo() {
|
u32 getFlowNodeNo() {
|
||||||
u16 nodeNo = home.angle.x;
|
u16 nodeNo = home.angle.x;
|
||||||
|
|||||||
@@ -140,7 +140,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -150,8 +150,8 @@ public:
|
|||||||
s32 getBackboneJointNo() { return mType == 2 ? ZRCB_JNT_BACKBONE1 : KOLINB_JNT_BACKBONE1; }
|
s32 getBackboneJointNo() { return mType == 2 ? ZRCB_JNT_BACKBONE1 : KOLINB_JNT_BACKBONE1; }
|
||||||
s32 getNeckJointNo() { return mType == 2 ? ZRCB_JNT_NECK : KOLINB_JNT_NECK; }
|
s32 getNeckJointNo() { return mType == 2 ? ZRCB_JNT_NECK : KOLINB_JNT_NECK; }
|
||||||
|
|
||||||
static char* mCutNameList[7];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[7];
|
||||||
static cutFunc mCutList[7];
|
static cutFunc DUSK_CONST mCutList[7];
|
||||||
|
|
||||||
u32 getFlowNodeNo() {
|
u32 getFlowNodeNo() {
|
||||||
u16 nodeNo = home.angle.x;
|
u16 nodeNo = home.angle.x;
|
||||||
|
|||||||
@@ -106,7 +106,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3,
|
||||||
int param_4,
|
int param_4,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5,
|
||||||
int param_6, daNpcT_evtData_c const* param_7, char** param_8)
|
int param_6, daNpcT_evtData_c const* param_7, char DUSK_CONST* DUSK_CONST* param_8)
|
||||||
: daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8) {}
|
: daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8) {}
|
||||||
u16 getEyeballMaterialNo() { return 2; }
|
u16 getEyeballMaterialNo() { return 2; }
|
||||||
s32 getHeadJointNo() { return 4; }
|
s32 getHeadJointNo() { return 4; }
|
||||||
@@ -123,8 +123,8 @@ public:
|
|||||||
return nodeNo;
|
return nodeNo;
|
||||||
}
|
}
|
||||||
|
|
||||||
static char* mCutNameList[2];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[2];
|
||||||
static cutFunc mCutList[2];
|
static cutFunc DUSK_CONST mCutList[2];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_KYURY_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_KYURY_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -100,8 +100,8 @@ public:
|
|||||||
s32 getFootRJointNo() { return 32; }
|
s32 getFootRJointNo() { return 32; }
|
||||||
BOOL chkXYItems() { return TRUE; }
|
BOOL chkXYItems() { return TRUE; }
|
||||||
|
|
||||||
static char* mCutNameList[4];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[4];
|
||||||
static cutFunc mCutList[4];
|
static cutFunc DUSK_CONST mCutList[4];
|
||||||
|
|
||||||
int getFlowNodeNo() {
|
int getFlowNodeNo() {
|
||||||
u16 nodeNo = home.angle.x;
|
u16 nodeNo = home.angle.x;
|
||||||
|
|||||||
@@ -91,7 +91,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -111,8 +111,8 @@ public:
|
|||||||
}
|
}
|
||||||
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xff0000) >> 16; }
|
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xff0000) >> 16; }
|
||||||
|
|
||||||
static char* mCutNameList[8];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[8];
|
||||||
static cutFunc mCutList[8];
|
static cutFunc DUSK_CONST mCutList[8];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ mDoExt_McaMorfSO* mpBowlMorf;
|
/* 0xE40 */ mDoExt_McaMorfSO* mpBowlMorf;
|
||||||
|
|||||||
@@ -132,7 +132,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -167,8 +167,8 @@ public:
|
|||||||
void startChoccai() { field_0x1134 = 1; }
|
void startChoccai() { field_0x1134 = 1; }
|
||||||
void endChoccai() { field_0x1134 = 0; }
|
void endChoccai() { field_0x1134 = 0; }
|
||||||
|
|
||||||
static char* mCutNameList[17];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[17];
|
||||||
static cutFunc mCutList[17];
|
static cutFunc DUSK_CONST mCutList[17];
|
||||||
|
|
||||||
u8 getGroupId() {
|
u8 getGroupId() {
|
||||||
return (fopAcM_GetParam(this) & 0xF0000000) >> 28;
|
return (fopAcM_GetParam(this) & 0xF0000000) >> 28;
|
||||||
|
|||||||
@@ -130,7 +130,7 @@ public:
|
|||||||
daNpc_midP_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
daNpc_midP_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
||||||
daNpcT_evtData_c const* param_7, char** param_8) :
|
daNpcT_evtData_c const* param_7, char DUSK_CONST* DUSK_CONST* param_8) :
|
||||||
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8) {}
|
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8) {}
|
||||||
u16 getEyeballRMaterialNo() { return 3; }
|
u16 getEyeballRMaterialNo() { return 3; }
|
||||||
u16 getEyeballLMaterialNo() { return 2; }
|
u16 getEyeballLMaterialNo() { return 2; }
|
||||||
@@ -148,8 +148,8 @@ public:
|
|||||||
return nodeNo;
|
return nodeNo;
|
||||||
}
|
}
|
||||||
|
|
||||||
static char* mCutNameList;
|
static char DUSK_CONST* DUSK_CONST mCutNameList;
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_MIDP_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_MIDP_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -128,7 +128,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -158,8 +158,8 @@ public:
|
|||||||
bool chkSFight() { return field_0x166b == 1; }
|
bool chkSFight() { return field_0x166b == 1; }
|
||||||
u8 getPathID() { return (fopAcM_GetParam(this) & 0xff00) >> 8; }
|
u8 getPathID() { return (fopAcM_GetParam(this) & 0xff00) >> 8; }
|
||||||
|
|
||||||
static char* mCutNameList[5];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[5];
|
||||||
static cutFunc mCutList[5];
|
static cutFunc DUSK_CONST mCutList[5];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0E40 */ NPC_MOI_HIO_CLASS* mpHIO;
|
/* 0x0E40 */ NPC_MOI_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -87,8 +87,8 @@ public:
|
|||||||
|
|
||||||
int getType() { return mType; }
|
int getType() { return mType; }
|
||||||
|
|
||||||
static char* mEvtCutNameList[5];
|
static char DUSK_CONST* DUSK_CONST mEvtCutNameList[5];
|
||||||
static EventFn mEvtCutList[];
|
static EventFn DUSK_CONST mEvtCutList[];
|
||||||
|
|
||||||
/* 0xB48 */ u8 field_0xB48[0xB4C - 0xB48];
|
/* 0xB48 */ u8 field_0xB48[0xB4C - 0xB48];
|
||||||
/* 0xB4C */ daNpcF_Lookat_c mLookat;
|
/* 0xB4C */ daNpcF_Lookat_c mLookat;
|
||||||
|
|||||||
@@ -115,7 +115,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -144,8 +144,8 @@ public:
|
|||||||
void setTagPos(cXyz const& i_pos) { mTagPos = i_pos; }
|
void setTagPos(cXyz const& i_pos) { mTagPos = i_pos; }
|
||||||
void setLookPos(cXyz const& i_pos) { mLookPos = i_pos; }
|
void setLookPos(cXyz const& i_pos) { mLookPos = i_pos; }
|
||||||
|
|
||||||
static char* mCutNameList[11];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[11];
|
||||||
static cutFunc mCutList[11];
|
static cutFunc DUSK_CONST mCutList[11];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_PACHI_BESU_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_PACHI_BESU_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -184,8 +184,8 @@ public:
|
|||||||
void setFMotion_Niramu_to_Besu() { mFMotion = 1; }
|
void setFMotion_Niramu_to_Besu() { mFMotion = 1; }
|
||||||
void setFMotion_LookNone() { mFMotion = 2; }
|
void setFMotion_LookNone() { mFMotion = 2; }
|
||||||
|
|
||||||
static char* mCutNameList[11];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[11];
|
||||||
static cutFunc mCutList[11];
|
static cutFunc DUSK_CONST mCutList[11];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_PACHI_MARO_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_PACHI_MARO_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -166,7 +166,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -196,8 +196,8 @@ public:
|
|||||||
void setTagPos(cXyz const& i_pos) { mTagPos = i_pos; }
|
void setTagPos(cXyz const& i_pos) { mTagPos = i_pos; }
|
||||||
void setLookPos(cXyz const& i_pos) { mLookPos = i_pos; }
|
void setLookPos(cXyz const& i_pos) { mLookPos = i_pos; }
|
||||||
|
|
||||||
static char* mCutNameList[11];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[11];
|
||||||
static cutFunc mCutList[11];
|
static cutFunc DUSK_CONST mCutList[11];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0E40 */ NPC_PACHI_TARO_HIO_CLASS* mpHIO;
|
/* 0x0E40 */ NPC_PACHI_TARO_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -125,7 +125,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -153,8 +153,8 @@ public:
|
|||||||
|
|
||||||
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
||||||
|
|
||||||
static char* mCutNameList[2];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[2];
|
||||||
static cutFunc mCutList[2];
|
static cutFunc DUSK_CONST mCutList[2];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0E40 */ mDoExt_McaMorfSO* mpFlagModelMorf;
|
/* 0x0E40 */ mDoExt_McaMorfSO* mpFlagModelMorf;
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -146,8 +146,8 @@ public:
|
|||||||
|
|
||||||
MtxP getHeadMtx() { return mpMorf[0]->getModel()->getAnmMtx(4); }
|
MtxP getHeadMtx() { return mpMorf[0]->getModel()->getAnmMtx(4); }
|
||||||
|
|
||||||
static char* mCutNameList[3];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[3];
|
||||||
static cutFunc mCutList[3];
|
static cutFunc DUSK_CONST mCutList[3];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_POUYA_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_POUYA_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ public:
|
|||||||
|
|
||||||
s16 getMessageNo() { return (fopAcM_GetParam(this) >> 8) & 0xFFFF; }
|
s16 getMessageNo() { return (fopAcM_GetParam(this) >> 8) & 0xFFFF; }
|
||||||
|
|
||||||
static EvtSeq mEvtSeqList[];
|
static EvtSeq DUSK_CONST mEvtSeqList[];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xB48 */ Z2CreatureCitizen mSound;
|
/* 0xB48 */ Z2CreatureCitizen mSound;
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -145,8 +145,8 @@ public:
|
|||||||
u8 getPathID() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
u8 getPathID() { return (fopAcM_GetParam(this) & 0xFF00) >> 8; }
|
||||||
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xFF0000) >> 16; }
|
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xFF0000) >> 16; }
|
||||||
|
|
||||||
static char* mCutNameList;
|
static char DUSK_CONST* DUSK_CONST mCutNameList;
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_RACA_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_RACA_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -115,7 +115,7 @@ public:
|
|||||||
daNpc_Saru_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
daNpc_Saru_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
||||||
daNpcT_evtData_c const* param_7, char** param_8) :
|
daNpcT_evtData_c const* param_7, char DUSK_CONST* DUSK_CONST* param_8) :
|
||||||
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
||||||
{}
|
{}
|
||||||
s32 getHeadJointNo() { return JNT_HEAD; }
|
s32 getHeadJointNo() { return JNT_HEAD; }
|
||||||
@@ -133,8 +133,8 @@ public:
|
|||||||
u8 getPathID() { return (fopAcM_GetParam(this) & 0xff0000) >> 16; }
|
u8 getPathID() { return (fopAcM_GetParam(this) & 0xff0000) >> 16; }
|
||||||
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xff00) >> 8; }
|
u8 getBitSW() { return (fopAcM_GetParam(this) & 0xff00) >> 8; }
|
||||||
|
|
||||||
static char* mCutNameList[4];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[4];
|
||||||
static cutFunc mCutList[4];
|
static cutFunc DUSK_CONST mCutList[4];
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_SARU_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_SARU_HIO_CLASS* mpHIO;
|
||||||
/* 0xE44 */ J3DModel* mpRoseModels[2];
|
/* 0xE44 */ J3DModel* mpRoseModels[2];
|
||||||
|
|||||||
@@ -80,12 +80,12 @@ public:
|
|||||||
daNpc_seiB_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
daNpc_seiB_c(daNpcT_faceMotionAnmData_c const* param_1, daNpcT_motionAnmData_c const* param_2,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_3, int param_4,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* param_5, int param_6,
|
||||||
daNpcT_evtData_c const* param_7, char** param_8) :
|
daNpcT_evtData_c const* param_7, char DUSK_CONST* DUSK_CONST* param_8) :
|
||||||
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
daNpcT_c(param_1, param_2, param_3, param_4, param_5, param_6, param_7, param_8)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
static char* mCutNameList;
|
static char DUSK_CONST* DUSK_CONST mCutNameList;
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_SEIB_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_SEIB_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -82,13 +82,13 @@ public:
|
|||||||
daNpc_seiC_c(daNpcT_faceMotionAnmData_c const* i_faceMotionAnmData, daNpcT_motionAnmData_c const* i_motionAnmData,
|
daNpc_seiC_c(daNpcT_faceMotionAnmData_c const* i_faceMotionAnmData, daNpcT_motionAnmData_c const* i_motionAnmData,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData, int i_faceMotionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData, int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {};
|
i_arcNames) {};
|
||||||
|
|
||||||
static char* mCutNameList;
|
static char DUSK_CONST* DUSK_CONST mCutNameList;
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_SEIC_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_SEIC_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -81,13 +81,13 @@ public:
|
|||||||
daNpc_seiD_c(daNpcT_faceMotionAnmData_c const* i_faceMotionAnmData, daNpcT_motionAnmData_c const* i_motionAnmData,
|
daNpc_seiD_c(daNpcT_faceMotionAnmData_c const* i_faceMotionAnmData, daNpcT_motionAnmData_c const* i_motionAnmData,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData, int i_faceMotionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData, int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {};
|
i_arcNames) {};
|
||||||
|
|
||||||
static char* mCutNameList;
|
static char DUSK_CONST* DUSK_CONST mCutNameList;
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_SEID_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_SEID_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -100,7 +100,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -114,8 +114,8 @@ public:
|
|||||||
BOOL checkChangeJoint(int val) { return val == 4; }
|
BOOL checkChangeJoint(int val) { return val == 4; }
|
||||||
BOOL checkRemoveJoint(int val) { return val == 8; }
|
BOOL checkRemoveJoint(int val) { return val == 8; }
|
||||||
|
|
||||||
static char* mCutNameList[2];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[2];
|
||||||
static cutFunc mCutList[2];
|
static cutFunc DUSK_CONST mCutList[2];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0F7C */ mDoExt_McaMorfSO* mpSeiraMorf;
|
/* 0x0F7C */ mDoExt_McaMorfSO* mpSeiraMorf;
|
||||||
|
|||||||
@@ -92,7 +92,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_faceMotionSequenceData,
|
||||||
int i_faceMotionStepNum,
|
int i_faceMotionStepNum,
|
||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData, int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData, char** i_arcNames)
|
daNpcT_evtData_c const* i_evtData, char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: dShopSystem_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {
|
i_arcNames) {
|
||||||
@@ -106,8 +106,8 @@ public:
|
|||||||
BOOL checkChangeJoint(int val) { return val == 4; }
|
BOOL checkChangeJoint(int val) { return val == 4; }
|
||||||
BOOL checkRemoveJoint(int val) { return val == 8; }
|
BOOL checkRemoveJoint(int val) { return val == 8; }
|
||||||
|
|
||||||
static char* mCutNameList[1];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[1];
|
||||||
static cutFunc mCutList[1];
|
static cutFunc DUSK_CONST mCutList[1];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0x0F7C */ mDoExt_McaMorfSO* mpSeiraMorf;
|
/* 0x0F7C */ mDoExt_McaMorfSO* mpSeiraMorf;
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) {}
|
i_arcNames) {}
|
||||||
@@ -99,8 +99,8 @@ public:
|
|||||||
u32 getBitSW() { return (fopAcM_GetParam(this) & 0xFF000) >> 12; }
|
u32 getBitSW() { return (fopAcM_GetParam(this) & 0xFF000) >> 12; }
|
||||||
bool getDoBtnChkFlag() { return (fopAcM_GetParam(this) & 0x100) == 0; }
|
bool getDoBtnChkFlag() { return (fopAcM_GetParam(this) & 0x100) == 0; }
|
||||||
|
|
||||||
static char* mCutNameList[2];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[2];
|
||||||
static cutFunc mCutList[2];
|
static cutFunc DUSK_CONST mCutList[2];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* 0xE40 */ NPC_SEIREI_HIO_CLASS* mpHIO;
|
/* 0xE40 */ NPC_SEIREI_HIO_CLASS* mpHIO;
|
||||||
|
|||||||
@@ -184,7 +184,7 @@ public:
|
|||||||
void lookat();
|
void lookat();
|
||||||
BOOL drawDbgInfo();
|
BOOL drawDbgInfo();
|
||||||
|
|
||||||
static EventFn mEvtSeqList[14];
|
static EventFn DUSK_CONST mEvtSeqList[14];
|
||||||
|
|
||||||
u8 getPathID() { return (fopAcM_GetParam(this) >> 8) & 0xFF; }
|
u8 getPathID() { return (fopAcM_GetParam(this) >> 8) & 0xFF; }
|
||||||
s16 getMessageNo() { return shape_angle.x; }
|
s16 getMessageNo() { return shape_angle.x; }
|
||||||
|
|||||||
@@ -94,7 +94,7 @@ public:
|
|||||||
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
daNpcT_MotionSeqMngr_c::sequenceStepData_c const* i_motionSequenceData,
|
||||||
int i_motionStepNum,
|
int i_motionStepNum,
|
||||||
daNpcT_evtData_c const* i_evtData,
|
daNpcT_evtData_c const* i_evtData,
|
||||||
char** i_arcNames)
|
char DUSK_CONST* DUSK_CONST* i_arcNames)
|
||||||
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
: daNpcT_c(i_faceMotionAnmData, i_motionAnmData, i_faceMotionSequenceData,
|
||||||
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
i_faceMotionStepNum, i_motionSequenceData, i_motionStepNum, i_evtData,
|
||||||
i_arcNames) { OS_REPORT("|%06d:%x|daNpc_Sha_c -> コンストラクト\n", g_Counter.mCounter0, this); }
|
i_arcNames) { OS_REPORT("|%06d:%x|daNpc_Sha_c -> コンストラクト\n", g_Counter.mCounter0, this); }
|
||||||
@@ -110,8 +110,8 @@ public:
|
|||||||
return nodeNo == 0xFFFF ? -1 : nodeNo;
|
return nodeNo == 0xFFFF ? -1 : nodeNo;
|
||||||
}
|
}
|
||||||
|
|
||||||
static char* mCutNameList[2];
|
static char DUSK_CONST* DUSK_CONST mCutNameList[2];
|
||||||
static cutFunc mCutList[2];
|
static cutFunc DUSK_CONST mCutList[2];
|
||||||
static const u16 mEvtBitLabels[6];
|
static const u16 mEvtBitLabels[6];
|
||||||
static const u16 mTmpBitLabels[6];
|
static const u16 mTmpBitLabels[6];
|
||||||
static const int mSceneChangeNoTable[48];
|
static const int mSceneChangeNoTable[48];
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user