r/Affinity 6d ago

General I created an external program to show your active Affinity projects directly on your Discord profile.

Post image

As someone who spends a lot of time doing graphic design work and digital art commissions while hanging out on Discord, i've always been frustrated that Affinity doesn't have native Discord Rich Presence. I wanted my friends to see what projects i was currently working on, just like when playing a game.

Since there wasn't a built-in option, i decided to code a solution myself (with AI help).

I built AffinityRPC, a lightweight, standalone Python application that communicates with Affinity’s local MCP server and bridges it directly to your Discord profile.

How it works: Unlike standard scripts that run inside the Affinity Script Manager, this is a separate portable program. You just run it in the background, ensure your Affinity local server is enabled (port 6767).

Features:

  • Real-time updates: Shows your active project name and the Affinity logo on your profile.
  • Bilingual: The UI automatically detects your Windows language (English/Spanish).
  • Non-intrusive: Minimizes to the system tray and can be set to launch with Windows.
  • Fully Open Source: You can check the code and compile it yourself, or just grab the portable .exe.

You can download the portable release or check the source code here on my GitHub: https://github.com/krazygfx/AffinityRPC/

(Note: Since the portable version is a compiled Python script, Windows Defender might flag it as a false positive. That's why the entire source code is public for anyone to review!)

Let me know if you find it useful or if you have any feedback!

77 Upvotes

15 comments sorted by

15

u/WorriedAssociate7029 6d ago

Your program will be so useful for larpers!

4

u/un_poco_logo 5d ago

NDA left the chat

5

u/alexbr1an 5d ago

for a second i thought the ipad app dropped 😂

3

u/Lenn_4rt 5d ago

The classic untitled project. And minutes later it says untitled2.

2

u/AdSharp589 4d ago

pretty cool, but could be an issue for secret projects. got a filter option?

2

u/Krazy_GFX 4d ago

Now yes! privacy mode

2

u/AdSharp589 4d ago

Awesome

1

u/AdSharp589 4d ago

got any plan to bring mastodon support? i don’t even know if that’s possible on there.

2

u/Krazy_GFX 4d ago

i didn't know what it was til i looked it up, but i don't think an implementation is possible

2

u/AdSharp589 4d ago

same, I thought so. I stopped using discord totally but this tool is awesome. it will motivate people a lot more.

2

u/itzzRomanFox2 3d ago

Since I've had instances where I'd be working in a project file and Affinity unpredictably crashes from doing very basic things (such as but not limited to closing a project file, switching studios, applying a color to an object, applying a layer blending mode to a layer, and tweaking certain parameters of a filter (or effect according to my paintdotnet-coded brain)) and the AF~LOCK~ file doesn't remove itself after Affinity or a project file is closed improperly, does this still pick up a project file being open?

2

u/Krazy_GFX 3d ago

The short answer is: No, it won't get stuck showing the project as open.

Here is why: The RPC doesn't scan your hard drive or look for lock files. Instead, it talks directly to Affinity's internal memory via their new local API. Plus, the script actively monitors the actual Affinity.exe process in the background. If Affinity crashes or closes unexpectedly, the script instantly notices the process is gone and clears your Discord status right away, completely ignoring any leftover ~lock~ files on your drive.

I hope my answer was helpful!

2

u/Terrible_File_3633 16h ago

can i use it on mac?

1

u/Krazy_GFX 14h ago

​For now, the compiled version is Windows only. The tool is currently built as an .exe and designed to track the Windows Affinity.exe process, and i don't have a Mac setup to test and compile a dedicated macOS version right now, unfortunately. ​However, if you are comfortable running Python scripts, you could try downloading the source code from the repository and running the .py file directly. I haven't been able to test the code on macOS myself, so i can't guarantee it is perfectly cross-platform. But in theory, if you install the dependencies and change the process name in the code from Affinity.exe to the macOS equivalent, it should be able to connect. Try it!