C
C#5mo ago
thefake

making an overlay

I want to make my own overlay, just like xbox gamebar or that geforce experience thing where you can broadcast, etc. I dont want to tab out of my games when I just need media controls to skip a song. I want it to be similiar to the ALT + R thing from geforce experience where you get an overlay, that shows you info. How should I do this? I’d like it to be a system tray thing that toggles the gui on keypress. Should I do this with basic .NET C# in visual studio to make the gui and make it system tray thing somehow or should I do something else to build the ui?
24 Replies
Pobiega
Pobiega5mo ago
https://github.com/michel-pi/GameOverlay.Net is an excellent startingpoint
thefake
thefake5mo ago
Looks good, but I’d like it to be interactive
Pobiega
Pobiega5mo ago
so make it interactive?
thefake
thefake5mo ago
I only read “click-through”
Pobiega
Pobiega5mo ago
you can disable that iirc
thefake
thefake5mo ago
Ah okay then Awesome
Pobiega
Pobiega5mo ago
take the example code, make it run, try to make some clickies work seems like a good starting point
thefake
thefake5mo ago
Ill try this evening
Pobiega
Pobiega5mo ago
if that doesnt work, maybe look at https://github.com/lolp1/Overlay.NET
thefake
thefake5mo ago
I dont know if I want to work with libraries I thought I would do it with bare .NET and C#
Pobiega
Pobiega5mo ago
uhh
thefake
thefake5mo ago
Would that be worse?
Pobiega
Pobiega5mo ago
yes so, in order to render things "on top" of an exclusive full screen game, like the steam or geforce experience overlays do... you need to do some tricky stuff with directx
thefake
thefake5mo ago
Oh I dont think im at the point where I can fool around with directx yet
Pobiega
Pobiega5mo ago
this is very much non-trivial code for a beginner, and if you truly want "no libraries" you cant even use SharpDX or similar direct x libs so you'll have to interface with native directx apis yourself 😄 tldr: dont be afraid of using libraries
thefake
thefake5mo ago
Im not afraid but I want to go deep in C# and libraries are premade stuff
Pobiega
Pobiega5mo ago
You can make it with a library first, then check the source code of the library to see how it works then remake it without the library ¯\_(ツ)_/¯
thefake
thefake5mo ago
I guess thats the best way
Pobiega
Pobiega5mo ago
Realistictly, you won't be able to do this using strictly only the base class library of .NET it simply doesnt have the bindings required to do something like this if you just want a desktop app that you can tab into, thats a different story
thefake
thefake5mo ago
No Thats the point Tabbing out often “lags” games
Pobiega
Pobiega5mo ago
yep
thefake
thefake5mo ago
I always do borderless window if I can but some only got fullscreen And in far cry 4 for example I wasnt even able to get the windows menu with the win-key or esc+ctrl, I had to use alt+tab and even when I did that it was laggy and weird Ive looked at the source code and it seems relatively easy
public static void MakeTopmost(IntPtr hwnd) => User32.SetWindowPos(hwnd, User32.HwndInsertTopMost, 0, 0, 0, 0, SwpFlags.ShowWindow | SwpFlags.NoActivate | SwpFlags.NoMove | SwpFlags.NoSize);
public static void MakeTopmost(IntPtr hwnd) => User32.SetWindowPos(hwnd, User32.HwndInsertTopMost, 0, 0, 0, 0, SwpFlags.ShowWindow | SwpFlags.NoActivate | SwpFlags.NoMove | SwpFlags.NoSize);
thefake
thefake5mo ago
No description
thefake
thefake5mo ago
Ive made a sketch in adobe illustrator of how I want it to be Everything will be rounded as hell
Want results from more Discord servers?
Add your server
More Posts
i dont understand why sometimes this code works and sometimes i get an infinite loop``` public List<List<int>> roomMatrix = new List<List<int>> { new List<int> {-1, -1, Assigning Values to Nested Class MembersI am new to C#. I am wondering how to instantiate an object with nested class members: ```c# namespHow to use Server Sent Events with HttpClientI'm working with an API framework (https://docs.mistral.ai/api/#operation/createChatCompletion) in wHow could I implement the tree correctly using XAML?Hello! I've started a XAML .NET application https://github.com/PerikiyoXD/RWTree/ The problem I'm Forwarding domain emails without a mailboxI have a few domain names on GoDaddy and they charge to have a mailbox, although I don't need the maHow do i send zipefile html with video and imageSo I'm doing a project at school and I am using Visual studio code.. I've usually don't code so i doHaving Trouble setting Outputpath for FrostyHash.vcxprojI'm not entirely sure where to set the output path in the vcxproj due to it looking different to theHow do I set environment variables for a MAUI Android app?at work my team and I have been struggling with how to get values (versions, prod urls, etc.) we sto✅ Database Scaffolding going wrong.Hello all, reading the title you can imagine what I want to ask today. Using efcore to add migrationbest way to handle multiple codebases interacting with same db?Hi everyone, I’m working on a “bank” project that has two codebases, the first is an ASP.NET based A