can c# do low level stuff?

05/11/2011 15:55 tkblackbelt#1
Hi, so I already know java quit well and want to learn a new language thaf will Allow me to do memory editing and such for game hacking/bots. Would c# allow me to do this, or is c++ the better way to go. Thanks
05/11/2011 16:43 w00tare#2
Quote:
Originally Posted by tkblackbelt View Post
Hi, so I already know java quit well and want to learn a new language thaf will Allow me to do memory editing and such for game hacking/bots. Would c# allow me to do this, or is c++ the better way to go. Thanks
You can, but its harder to do I guess. (API's and shit).
05/11/2011 18:09 InfamousNoone#3
It's in no sense harder. How is this low-level in any way what so ever?
05/11/2011 20:38 Lateralus#4
Quote:
Originally Posted by InfamousNoone View Post
It's in no sense harder. How is this low-level in any way what so ever?
It IS a little more trouble to work with memory in C# over C++. At least I've found that it's hard as shit to use pointers, though you're not "supposed" to.
05/12/2011 00:02 Korvacs#5
Quote:
Originally Posted by Lateralus View Post
It IS a little more trouble to work with memory in C# over C++. At least I've found that it's hard as shit to use pointers, though you're not "supposed" to.
Whats difficult about using pointers? And of course your supposed to use pointers, they wouldnt give you the ability to do so if you werent supposed to, what sort of logic is that?

While you can happily work with memory in C#, you have a little more control over it in C++, but that certainly doesnt mean that you must use C++.
05/12/2011 00:24 tkblackbelt#6
Thanks guys I think I'll learn C# since its very close the java, provides RAP, and won't have to worry about all the issues that can arise in c++. I wish java had pointers and had the ability to do low level stuff, without using the jni.
05/12/2011 16:51 w00tare#7
in C++ you can use _asm { //shit here } , as far as I know you can't do anything like that in C#.
05/12/2011 17:34 shitboi#8
since C# programs gets compiled to exe, you can ollydbg the exe to add in asm codes :)
05/12/2011 17:52 IAmHawtness#9
Quote:
Originally Posted by shitboi View Post
since C# programs gets compiled to exe, you can ollydbg the exe to add in asm codes :)
Or make a C++ DLL that you would call from your C# program to execute the specific assembler instructions.
05/12/2011 20:23 Lateralus#10
Quote:
Originally Posted by Korvacs View Post
Whats difficult about using pointers? And of course your supposed to use pointers, they wouldnt give you the ability to do so if you werent supposed to, what sort of logic is that?

While you can happily work with memory in C#, you have a little more control over it in C++, but that certainly doesnt mean that you must use C++.
Sorry, that was badly worded, and didn't really capture the point I was making. What I meant instead of "you're not supposed to..." is that you can do everything in C# without pointers, though some things may be more difficult. As far as using pointers in C#, it seems that there are more restraints on it to protect memory exceptions to novice programmers than C++, as well as it requires more code to implement the same in C++.

As w00tare said, you can implement direct asm instructions from C++ (instead of going through the stuff mentioned above), and not in C#. That's pretty low level, haha.
05/13/2011 18:38 _DreadNought_#11
What about BlackMagic ASM?
05/13/2011 19:00 IAmHawtness#12
Quote:
Originally Posted by _DreadNought_ View Post
What about BlackMagic ASM?
That's a really shitty way of doing it. Writing the assembly instructions in a C++ DLL and then calling them from your C# project is a much, MUCH better and easier approach. BlackMagic is for remote code execution, not really for local code execution.
05/22/2011 20:08 BaussHacker#13
I remember a while back there was a source released for assembly in C#.

Let me find it.

#Edit

There you go:
[Only registered and activated users can see links. Click Here To Register...]
05/22/2011 21:23 tkblackbelt#14
Quote:
Originally Posted by BaussHacker View Post
I remember a while back there was a source released for assembly in C#.

Let me find it.

#Edit

There you go:
[Only registered and activated users can see links. Click Here To Register...]
Cool, I'll have a look at it. :)
05/22/2011 21:51 IAmHawtness#15
Quote:
Originally Posted by BaussHacker View Post
I remember a while back there was a source released for assembly in C#.

Let me find it.

#Edit

There you go:
[Only registered and activated users can see links. Click Here To Register...]
This does exactly the same as the BlackMagic library, fyi.
It's a really bad way of executing assembly instructions inside your own program.