Skip to content

Commit

Permalink
add doxygen theme and begin writing manual
Browse files Browse the repository at this point in the history
  • Loading branch information
bates64 committed Jan 2, 2025
1 parent f01596b commit 09e5337
Show file tree
Hide file tree
Showing 16 changed files with 501 additions and 144 deletions.
25 changes: 14 additions & 11 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,21 @@ jobs:
name: Game
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v25
with:
fetch-depth: 0
- name: Install dependencies
run: ./install_deps.sh
- name: Install compilers
run: ./install_compilers.sh
- name: Install cargo-binstall
uses: cargo-bins/cargo-binstall@main
- name: Install pigment64 and crunch64
run: cargo binstall pigment64 crunch64-cli -y
nix_path: nixpkgs=channel:nixos-unstable
- uses: cachix/cachix-action@v14
with:
name: mycache
# If you chose signing key for write access
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
# If you chose API tokens for write access OR if you have a private cache
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- run: nix-build
- run: nix-shell --run "echo OK"
- name: Download baserom
run: curl -L $BASEROM_US_URL -o ver/us/baserom.z64
env:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ jobs:
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Upload entire repository
path: '.'
path: ./docs/doxygen/html/

- name: Deploy to GitHub Pages
id: deployment
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "docs/doxygen-awesome-css"]
path = docs/doxygen-awesome-css
url = https://github.com/jothepro/doxygen-awesome-css.git
32 changes: 4 additions & 28 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,38 +2,14 @@
"version": "2.0.0",
"tasks": [
{
"label": "run",
"label": "Run Mod",
"type": "shell",
"command": "./run",
"command": "nix-shell --command ./run",
"problemMatcher": "$gcc",
"group": {
"kind": "none",
"kind": "build",
"isDefault": true
}
},
{
"type": "cppbuild",
"label": "C/C++: clang build active file",
"command": "/usr/bin/clang",
"args": [
"-fcolor-diagnostics",
"-fansi-escape-codes",
"-g",
"${file}",
"-o",
"${fileDirname}/${fileBasenameNoExtension}"
],
"options": {
"cwd": "${fileDirname}"
},
"problemMatcher": [
"$gcc"
],
"group": {
"kind": "build",
"isDefault": true
},
"detail": "Task generated by Debugger."
}
]
}
}
62 changes: 37 additions & 25 deletions Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ DOXYFILE_ENCODING = UTF-8
# title of most generated pages and in a few other places.
# The default value is: My Project.

PROJECT_NAME = "papermario"
PROJECT_NAME = "Paper Mario DX"

# The PROJECT_NUMBER tag can be used to enter a project or revision number. This
# could be handy for archiving the generated documentation or if some version
Expand All @@ -54,7 +54,7 @@ PROJECT_NUMBER =
# for a project that appears at the top of each page and should give viewer a
# quick idea about the purpose of the project. Keep the description short.

PROJECT_BRIEF = "Decompilation of Paper Mario"
PROJECT_BRIEF = "Paper Mario (N64) modding"

# With the PROJECT_LOGO tag one can specify a logo or an icon that is included
# in the documentation. The maximum height of the logo should not exceed 55
Expand Down Expand Up @@ -199,7 +199,7 @@ STRIP_FROM_PATH =
# specify the list of include paths that are normally passed to the compiler
# using the -I flag.

STRIP_FROM_INC_PATH =
STRIP_FROM_INC_PATH = include src

# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but
# less readable) file names. This can be useful is your file systems doesn't
Expand Down Expand Up @@ -368,7 +368,7 @@ MARKDOWN_SUPPORT = YES
# Minimum value: 0, maximum value: 99, default value: 5.
# This tag requires that the tag MARKDOWN_SUPPORT is set to YES.

TOC_INCLUDE_HEADINGS = 5
TOC_INCLUDE_HEADINGS = 2

# The MARKDOWN_ID_STYLE tag can be used to specify the algorithm used to
# generate identifiers for the Markdown headings. Note: Every identifier is
Expand Down Expand Up @@ -675,20 +675,20 @@ SHOW_GROUPED_MEMB_INC = NO
# files with double quotes in the documentation rather than with sharp brackets.
# The default value is: NO.

FORCE_LOCAL_INCLUDES = NO
FORCE_LOCAL_INCLUDES = YES

# If the INLINE_INFO tag is set to YES then a tag [inline] is inserted in the
# documentation for inline members.
# The default value is: YES.

INLINE_INFO = YES
INLINE_INFO = NO

# If the SORT_MEMBER_DOCS tag is set to YES then doxygen will sort the
# (detailed) documentation of file and class members alphabetically by member
# name. If set to NO, the members will appear in declaration order.
# The default value is: YES.

SORT_MEMBER_DOCS = YES
SORT_MEMBER_DOCS = NO

# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the brief
# descriptions of file, namespace and class members alphabetically by member
Expand Down Expand Up @@ -843,7 +843,7 @@ CITE_BIB_FILES =
# messages are off.
# The default value is: NO.

QUIET = NO
QUIET = YES

# The WARNINGS tag can be used to turn on/off the warning messages that are
# generated to standard error (stderr) by doxygen. If WARNINGS is set to YES
Expand All @@ -867,14 +867,17 @@ WARN_IF_UNDOCUMENTED = YES
# using markup commands wrongly.
# The default value is: YES.

WARN_IF_DOC_ERROR = YES
# disabled because @evtapi funcs warn about parameters being documented that aren't really parameters, because they
# are evt Call parameters rather than actual C function parameters
WARN_IF_DOC_ERROR = NO

# If WARN_IF_INCOMPLETE_DOC is set to YES, doxygen will warn about incomplete
# function parameter documentation. If set to NO, doxygen will accept that some
# parameters have no documentation without warning.
# The default value is: YES.

WARN_IF_INCOMPLETE_DOC = YES
# same reason as WARN_IF_DOC_ERROR
WARN_IF_INCOMPLETE_DOC = NO

# This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that
# are documented, but have no documentation for their parameters or return
Expand All @@ -884,7 +887,7 @@ WARN_IF_INCOMPLETE_DOC = YES
# WARN_IF_INCOMPLETE_DOC
# The default value is: NO.

WARN_NO_PARAMDOC = NO
WARN_NO_PARAMDOC = YES

# If WARN_IF_UNDOC_ENUM_VAL option is set to YES, doxygen will warn about
# undocumented enumeration values. If set to NO, doxygen will accept
Expand Down Expand Up @@ -950,7 +953,10 @@ WARN_LOGFILE =
# spaces. See also FILE_PATTERNS and EXTENSION_MAPPING
# Note: If this tag is empty the current directory is searched.

INPUT = include src
INPUT = README.md include src \
manual/introduction.md \
manual/setup.md \
manual/assets.md

# This tag can be used to specify the character encoding of the source files
# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses
Expand Down Expand Up @@ -1076,15 +1082,15 @@ EXCLUDE_SYMLINKS = NO
# Note that the wildcards are matched against the file with absolute path, so to
# exclude all test directories for example use the pattern */test/*

EXCLUDE_PATTERNS = */gcc/* */os/*
EXCLUDE_PATTERNS = */gcc/* */os/* */world/area_*/* */battle/area/* include/mapfs/*

# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names
# (namespaces, classes, functions, etc.) that should be excluded from the
# output. The symbol name can be a fully qualified name, a word, or if the
# wildcard * is used, a substring. Examples: ANamespace, AClass,
# ANamespace::AClass, ANamespace::*Test

EXCLUDE_SYMBOLS = API_CALLABLE N
EXCLUDE_SYMBOLS = API_CALLABLE N NAMESPACE

# The EXAMPLE_PATH tag can be used to specify one or more files or directories
# that contain example code fragments that are included (see the \include
Expand Down Expand Up @@ -1171,7 +1177,7 @@ FILTER_SOURCE_PATTERNS =
# (index.html). This can be useful if you have a project on for instance GitHub
# and want to reuse the introduction page also for the doxygen output.

USE_MDFILE_AS_MAINPAGE =
USE_MDFILE_AS_MAINPAGE = README.md

# The Fortran standard specifies that for fixed formatted Fortran code all
# characters from position 72 are to be considered as comment. A common
Expand All @@ -1193,14 +1199,14 @@ FORTRAN_COMMENT_AFTER = 72
# also VERBATIM_HEADERS is set to NO.
# The default value is: NO.

SOURCE_BROWSER = NO
SOURCE_BROWSER = YES

# Setting the INLINE_SOURCES tag to YES will include the body of functions,
# multi-line macros, enums or list initialized variables directly into the
# documentation.
# The default value is: NO.

INLINE_SOURCES = NO
INLINE_SOURCES = YES

# Setting the STRIP_CODE_COMMENTS tag to YES will instruct doxygen to hide any
# special comment blocks from generated source code fragments. Normal C, C++ and
Expand Down Expand Up @@ -1267,7 +1273,7 @@ USE_HTAGS = NO
# See also: Section \class.
# The default value is: YES.

VERBATIM_HEADERS = NO
VERBATIM_HEADERS = YES

#---------------------------------------------------------------------------
# Configuration options related to the alphabetical class index
Expand All @@ -1287,7 +1293,7 @@ ALPHABETICAL_INDEX = YES
# after removing the prefix.
# This tag requires that the tag ALPHABETICAL_INDEX is set to YES.

IGNORE_PREFIX =
IGNORE_PREFIX = _ __

#---------------------------------------------------------------------------
# Configuration options related to the HTML output
Expand Down Expand Up @@ -1331,7 +1337,7 @@ HTML_FILE_EXTENSION = .html
# of the possible markers and block names see the documentation.
# This tag requires that the tag GENERATE_HTML is set to YES.

HTML_HEADER =
HTML_HEADER = docs/doxytheme/header.html

# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each
# generated HTML page. If the tag is left blank doxygen will generate a standard
Expand Down Expand Up @@ -1371,7 +1377,9 @@ HTML_STYLESHEET =
# documentation.
# This tag requires that the tag GENERATE_HTML is set to YES.

HTML_EXTRA_STYLESHEET = docs/doxytheme/theme.css
HTML_EXTRA_STYLESHEET = docs/doxytheme/theme.css \
docs/doxygen-awesome-css/doxygen-awesome.css \
docs/doxygen-awesome-css/doxygen-awesome-sidebar-only.css

# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or
# other source files which should be copied to the HTML output directory. Note
Expand All @@ -1381,7 +1389,11 @@ HTML_EXTRA_STYLESHEET = docs/doxytheme/theme.css
# files will be copied as-is; there are no commands or markers available.
# This tag requires that the tag GENERATE_HTML is set to YES.

HTML_EXTRA_FILES = docs/doxytheme/theme.js
HTML_EXTRA_FILES = docs/doxytheme/theme.js \
docs/doxygen-awesome-css/doxygen-awesome-fragment-copy-button.js \
docs/doxygen-awesome-css/doxygen-awesome-paragraph-link.js \
docs/doxygen-awesome-css/doxygen-awesome-interactive-toc.js \
docs/doxygen-awesome-css/doxygen-awesome-tabs.js

# The HTML_COLORSTYLE tag can be used to specify if the generated HTML output
# should be rendered with a dark or light theme.
Expand All @@ -1394,7 +1406,7 @@ HTML_EXTRA_FILES = docs/doxytheme/theme.js
# The default value is: AUTO_LIGHT.
# This tag requires that the tag GENERATE_HTML is set to YES.

HTML_COLORSTYLE = AUTO_DARK
HTML_COLORSTYLE = LIGHT

# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen
# will adjust the colors in the style sheet and background images according to
Expand Down Expand Up @@ -1461,7 +1473,7 @@ HTML_CODE_FOLDING = YES
# The default value is: YES.
# This tag requires that the tag GENERATE_HTML is set to YES.

HTML_COPY_CLIPBOARD = YES
HTML_COPY_CLIPBOARD = NO

# Doxygen stores a couple of settings persistently in the browser (via e.g.
# cookies). By default these settings apply to all HTML pages generated by
Expand Down Expand Up @@ -1734,7 +1746,7 @@ GENERATE_TREEVIEW = YES
# The default value is: NO.
# This tag requires that the tag GENERATE_HTML is set to YES.

FULL_SIDEBAR = YES
FULL_SIDEBAR = NO

# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values that
# doxygen will group on one line in the generated HTML documentation.
Expand Down
22 changes: 15 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
# Paper Mario DX

[![Release](https://img.shields.io/github/v/release/star-haven/papermario-dx)][releases]
[![Download](https://img.shields.io/github/downloads/star-haven/papermario-dx/total)][download]
![Build Status](https://img.shields.io/github/actions/workflow/status/star-haven/papermario-dx/build.yaml)
[![Release](https://img.shields.io/github/v/release/bates64/papermario-dx)][releases]
[![Download](https://img.shields.io/github/downloads/bates64/papermario-dx/total)][download]
![Build Status](https://img.shields.io/github/actions/workflow/status/bates64/papermario-dx/build.yaml)

This is a fork of the [Paper Mario decompilation][papermario-repo] which provides a flexible, easy-to-use base for creating romhacks.

To get started, see [docs.starhaven.dev](https://docs.starhaven.dev/tools/decomp/setup.html).
To get started, [read the manual](manual/introduction.md).

[discord]: https://discord.gg/star-haven
[discord-badge]: https://img.shields.io/discord/279322074412089344?color=%237289DA&logo=discord&logoColor=ffffff
[papermario-repo]: https://github.com/pmret/papermario
[releases]: https://github.com/star-haven/papermario-dx/releases
[download]: https://github.com/star-haven/papermario-dx/releases/download/latest/papermario.bps
[releases]: https://github.com/bates64/papermario-dx/releases
[download]: https://github.com/bates64/papermario-dx/releases/download/latest/papermario.bps

## List of changes
### List of changes (incomplete)

- US release only (no JP, PAL, or iQue - none of these are near 100% yet).
- Default configure flags: `--shift --modern-gcc --non-matching --ccache`
Expand All @@ -32,3 +32,11 @@ To get started, see [docs.starhaven.dev](https://docs.starhaven.dev/tools/decomp
- Additional features can be configured in [src/dx/config.h](src/dx/config.h).

[libgcc_vr4300]: https://github.com/Decompollaborate/libgcc_vr4300

<div class="section_buttons">

| Next |
|----------------------------------------------:|
|[Introduction](manual/introduction.md) |

</div>
1 change: 1 addition & 0 deletions docs/doxygen-awesome-css
Submodule doxygen-awesome-css added at 568f56
16 changes: 16 additions & 0 deletions docs/doxytheme/footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,22 @@
$generatedby&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="$relpath^doxygen.svg" width="104" height="31" alt="doxygen"/></a> $doxygenversion
</small></address>
<!--END !GENERATE_TREEVIEW-->

<script src="theme.js"></script>

<script type="text/javascript" src="$relpath^doxygen-awesome-fragment-copy-button.js"></script>
<script type="text/javascript" src="$relpath^doxygen-awesome-paragraph-link.js"></script>
<script type="text/javascript" src="$relpath^doxygen-awesome-interactive-toc.js"></script>
<script type="text/javascript" src="$relpath^doxygen-awesome-tabs.js"></script>
<script type="text/javascript">
DoxygenAwesomeFragmentCopyButton.init()
DoxygenAwesomeParagraphLink.init()
DoxygenAwesomeInteractiveToc.init()
DoxygenAwesomeTabs.init()
</script>

<!-- https://tholman.com/github-corners/ -->
<a href="https://github.com/bates64/papermario-dx" class="github-corner" aria-label="View on GitHub"><svg width="64" height="64" viewBox="0 0 250 250" style="fill:#fff; color: var(--page-background-color); position: absolute; top: 0; border: 0; right: 0;" aria-hidden="true"><path d="M0,0 L115,115 L130,115 L142,142 L250,250 L250,0 Z"/><path d="M128.3,109.0 C113.8,99.7 119.0,89.6 119.0,89.6 C122.0,82.7 120.5,78.6 120.5,78.6 C119.2,72.0 123.4,76.3 123.4,76.3 C127.3,80.9 125.5,87.3 125.5,87.3 C122.9,97.6 130.6,101.9 134.4,103.2" fill="currentColor" style="transform-origin: 130px 106px;" class="octo-arm"/><path d="M115.0,115.0 C114.9,115.1 118.7,116.5 119.8,115.4 L133.7,101.6 C136.9,99.2 139.9,98.4 142.2,98.6 C133.8,88.0 127.5,74.4 143.8,58.0 C148.5,53.4 154.0,51.2 159.7,51.0 C160.3,49.4 163.2,43.6 171.4,40.1 C171.4,40.1 176.1,42.5 178.8,56.2 C183.1,58.6 187.2,61.8 190.9,65.4 C194.5,69.0 197.7,73.2 200.1,77.6 C213.8,80.2 216.3,84.9 216.3,84.9 C212.7,93.1 206.9,96.0 205.4,96.6 C205.1,102.4 203.0,107.8 198.3,112.5 C181.9,128.9 168.3,122.5 157.7,114.1 C157.9,116.9 156.7,120.9 152.7,124.9 L141.0,136.5 C139.8,137.7 141.6,141.9 141.8,141.8 Z" fill="currentColor" class="octo-body"/></svg></a><style>.github-corner:hover .octo-arm{animation:octocat-wave 560ms ease-in-out}@keyframes octocat-wave{0%,100%{transform:rotate(0)}20%,60%{transform:rotate(-25deg)}40%,80%{transform:rotate(10deg)}}@media (max-width:500px){.github-corner:hover .octo-arm{animation:none}.github-corner .octo-arm{animation:octocat-wave 560ms ease-in-out}}</style>

</body>
</html>
Loading

0 comments on commit 09e5337

Please sign in to comment.