This hook marks a provided page to be used by the patcher so its content can be written to a targeted file in the patch repository. It should be used on Patch pages.
When used on pages, it will appear as a link inside a small, gray (or colored) box.
Usage
{{Thcrap Include|page|target=|name|game=}}
page
- The page which will be used to generate the file. For pages in the "File" namespace, the patcher will use the raw content of the file to generate the targeted file; for pages in any other namespace, the patcher will dynamically create content by using other thcrap hooks in the page.
target=
- The file to be targeted for writing.
name (optional)
- A name to display on the page using this template. This parameter is unused by the TouhouPatchCenter extension.
game= (optional)
- The game in which the file is used. This determines the patch repository folder in which the target file will be placed (e.g., providing
game=th06 for patch lang_en will result in the file being placed in the folder lang_en/th06 ). If not provided, the file will be placed in the patch's root directory. Note that some target files (like th06.js ) may need to go in the root directory to function.
Examples
These examples are used under the context of being on the Patch:Lang en page.
{{Thcrap Include|File:Font Cirno.json|target=th09.js|TH09: Use Cirno}} would copy the content of File:Font Cirno.json to lang_en/th09.js .
{{Thcrap Include|File:lang_en-th095-mission.msg|target=mission.msg|Hard-patched spell card comments|game=th095}} would copy the content of File:lang_en-th095-mission.msg to lang_en/th095/mission.msg .
For more usage examples, refer to the source code of the pages using this template.
|