Hi! First of all, thank you for showing interest in the project! This document will guide you on how to contribute to Dissonity.
You don't need to write code to contribute — testing or helping with documentation are examples of tasks that are also very appreciated!
- pnpm - Package manager
- Yalc - Testing npm packages locally
- Doxygen - Generating documentation for the C# API
- Act (and Docker) - Testing workflows locally
If you find a bug, open an issue using the "[v2] Bug report" template. You may also open an issue for:
- Feature requests
- Change suggestions
- Feedback
- Typos
If you want to change a fundamental part of the project, please open an issue to discuss it before opening a pull request.
It's recommended to open an issue before submiting a pull request, but you can open one directly if you are sure about your changes.
After opening a pull request, a maintainer will review the code and may request new changes. When working on a PR:
- Only add commits related to the PR
- Ask for help if you feel lost
- Request a new review once the new changes are implemented
We recommend using Conventional Commits.
| Module | Description | Status | Allows contributions? | When will it allow contributions? |
|---|---|---|---|---|
| /unity | C# Unity package. | Unlikely to undergo major unexpected changes. | ✅ | |
| /unity/Editor/Assets/Template | WebGL Template used to run the hiRPC interface before the game build. | Unlikely to undergo major unexpected changes. | ✅ | |
| /hirpc | Underlying module that interacts with the Discord RPC. | Unlikely to undergo major unexpected changes. | ✅ | |
| /hirpc-interface | hiRPC implementation for Unity. | Unlikely to undergo major unexpected changes. | ✅ | |
| /hirpc-kit | hiRPC utilities for JavaScript. | Unlikely to undergo major unexpected changes. | ✅ | |
| /website | Site that hosts documentation and guides. | Contributions are accepted. | ✅ |
- Fixes to incorrect or outdated statements in the documentation
- Fixing grammatical errors
- Rewording to clarify complicated explanations
- Subjective formatting changes
- Modifications to the overall structure of the documentation
- Additions that document private or unreleased functionality
Dissonity is a strongly typed implementation of a weakly typed API, meaning Discord can make slight variations of a data structure and call it the same way.
While developing the C# package we don't have as much information as Discord; we simply mirror the official package. Therefore, we need to make careful decisions about the package:
-
Mysterious or spontaneous fields without documentation can be excluded.
-
Notable structure variations can be handled by creating multiple models (e.g.,
GuildMember,GuildMemberRpc,User,Participant, etc.)
- Add command models to Dissonity.Commands
- Update CommandUtility
- Add command to Api.Commands
- Add mock response to Api.MockSendCommand
- Add event models to Dissonity.Events
- Update EventUtility
- Add event to Api.Subscribe
- Add event to mock
- Check if it needs initialization / hiRPC ready
- Check if it needs a mock implementation
- Check if new models are needed
After updating the C# API, the generated Doxygen reference on the website should be automatically updated via the deployment workflow.
Bump the package.json version as required. Lastly, the update dialog should be updated to reflect the changes.
- Check if functionality should require access to the hash
- Bump the SDK_VERSION constant if required
- Bump package.json version
- Write tests if needed
- Run pnpm build and pnpm move
- Build hiRPC
- Bump package.json version
- Run pnpm build and pnpm move
- Build hiRPC
- Bump package.json version
- Test locally using Yalc
The Core Team consists of two people, but the community is also an important part of the development process.
If you contribute to the project, you could be added to a contributor list as a thank you.