Questions tagged [c#]

A multi-paradigm programming language encompassing strong typing, imperative, declarative, functional, generic, object-oriented (class-based), and component-oriented programming disciplines

94 questions
1
vote
1 answer

C# - Identical block of code, but IL instructions changed after update. How do I modify the more convoluted update?

Background info - For the game 7 Days To Die, there is a C# wrapper that implements the Harmony API, which allows us to intercept the game's function calls, as well as changing the IL instructions themselves. I originally used the Transpiler…
FiftyTifty
  • 65
  • 1
  • 7
1
vote
1 answer

Reverse code check

I'm currently only patching this code to return true, do you guys have any idea of how I could start making a generator to make valid codes? I can't understand the logic here. public static bool ValidateQrCode(string code) { if…
Aman
  • 133
  • 3
0
votes
1 answer

Cannot compile native/unmanaged method

I disassembled a C# program with ildasm and modified the il code to my needs but now when i try to assemble it back into an exe i get these errors: Cannot compile native/unmanaged method Local (embedded native) PInvoke method, the resulting PE file…
user1365830
  • 563
  • 1
  • 5
  • 7
0
votes
0 answers

How can I have a breakpoint once a value changes in DnSpy?

I am trying to track a certain value in a game to analyze the cause of a crash (basically, it goes to null at one point and I would like to know what exactly puts that to null as it causes issues later on). I am relatively a beginner in C# reversing…
aldelaro5
  • 1
  • 1