I already found a way how to change the contents of a function at runtime: https://stackoverflow.com/a/36415711/14727115
But is it possible just to add content to, lets say, a standard constructor? What I originally thought was I create a byte-buffer (malloc/marshall) of size: the size of the method/constructor I want to change + the size of the method to add, and then replace the memory address the original constructor/method refers to, to the new created one.
But that didnt work out well, because I am not sure whether .PrepareMethod handles ConstructorInfo as it does MethodInfo