Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
shnakamura committed Mar 11, 2024
0 parents commit 97ff2c8
Show file tree
Hide file tree
Showing 69 changed files with 3,136 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/ISSUE_TEMPLATE/BUG_REPORT.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: "🐛 Bug Report"
description: Create an issue for a bug report.
title: "<title>"
labels: [
"Bug",
"New Issue"
]
body:
- type: textarea
id: description
attributes:
label: "Description"
description: Please enter an explicit description of your issue.
validations:
required: true
- type: textarea
id: reprod
attributes:
label: "Reproduction steps"
description: Please demonstrate the steps to replicate your issue, if known about.
validations:
required: false
- type: textarea
id: screenshot
attributes:
label: "Screenshots"
description: Please attach screenshots to help further demonstrate your issue.
validations:
required: false
- type: textarea
id: logs
attributes:
label: "Logs"
description: Please copy and paste any relevant log output, if any.
render: bash
validations:
required: false
22 changes: 22 additions & 0 deletions .github/ISSUE_TEMPLATE/FEATURE_REQUEST.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: "⭐ Feature Request"
description: Create an issue for a feature request.
title: "<title>"
labels: [
"Feature",
"New Issue"
]
body:
- type: textarea
id: summary
attributes:
label: "Summary"
description: Please provide a brief explanation of the request.
validations:
required: true
- type: textarea
id: reasonings
attributes:
label: "Reasonings"
description: Please provide reasons why your request should be taken into account.
validations:
required: true
5 changes: 5 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
blank_issues_enabled: true
contact_links:
- name: Discord Server
url: https://www.discord.gg/vPTUZcvXjg
about: Need extra assistance? Get in touch with developers through our Discord Server.
38 changes: 38 additions & 0 deletions .github/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
> [!NOTE]
> This is the `.github/README.md` file. We choose to leave it outside of the root directory. You can move it to the root directory or edit it in `.github/`.
# template-mod

This is the Team Catalyst Template Mod, a template repository for quick-starting development with [terraria-catalyst/catalyst](https://github.com/terraria-catalyst/catalyst).

Catalyst is a build toolchain and extension to the tModLoader ecosystem that facilitates monolithic/multi-project repositories that may contain multiple projects, including multiple mods.

## About Catalyst

Catalyst is a set of projects and MSBuild targets/props that make mod development quicker and easier. It provides features like access transformers, allows for non-standard project organization, features source generators, and more.

This template is specifically designed to integrate with it, so it isn't optional.

## Cloning

The repository should be cloned into the `tModLoader/ModSources/` directory, such that the path looks like: `tModLoader/ModSources/template-mod`. This requirement may change in the future as Catalyst develops.

## Building

Once cloned, one should run the `scripts/setup.sh` script. This script generates symlinks, initializes and updates submodules, and builds Catalyst.

After running the setup script, you can build any mod project with `dotnet build` and it will produce binaries in the `bin/` directory and a built `.tmod` archive in `tModLoader/Mods`, just like regular tModLoader.

## Symbolic Linking

As mentioned in [Building](#building), symbolic links are used. These are used to mimic the expected tModLoader mod directory setup. Your cloned repository is included in `ModSources/` but isn't actually a mod. Normally, any mods within `src/` would go unrecognized. To fix this, symbolic links are generated that lie within `ModSources/` and point to the projects in `src/`. The allows for tML to detect your mods, reference assets like icons for publishing, and properly update and hot reload localization files.

Generating symbolic links may require administrator/root permissions.

## Generating Projects

You can generate projects with the `gen-mod.js` and `gen-library.js` scripts, which will create a new mod or library project respectively.

When generating a mod, you should pass in both the namespace and internal mod name (assembly name) as arguments. When generating a library, you should just pass in the namespace (assembly name).

To generate the solution file, run `gen-sln.js` with the name as input. **Generating mods and libraries will not automatically add them to the solution.**
10 changes: 10 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
.vs/
.vscode/
.idea/
.catalyst/

bin/
obj/

*.user

3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "catalyst"]
path = catalyst
url = https://github.com/terraria-catalyst/catalyst.git
Loading

0 comments on commit 97ff2c8

Please sign in to comment.