| View previous topic :: View next topic |
| Author |
Message |
ZenX Grandmaster Cheater Supreme
Reputation: 1
Joined: 26 May 2007 Posts: 1021 Location: ">>Pointer<<" : Address 00400560 Offset :1FE
|
Posted: Sun Nov 18, 2007 10:04 pm Post subject: |
|
|
| samuri25404 wrote: | | Code: |
//using System.IO
FileStream file = null;
StreamReader reader = null;
try
{
file = new FileStream("c:\\verify.ini", FileMode.Open);
reader = new StreamReader(file);
if (reader.ReadLine() == "0x00456")
{
MessageBox.show("j00 Failz");
}
}
finally
{
reader.Close();
file.Close();
}
|
|
Two things:
1)
| Code: |
file = new FileStream("c:\\verify.ini", FileMode.Open);
|
You can do better than that, right?
| Code: |
file = new FileStream(@"c:\verify.ini", FileMode.Open);
|
Nobody likes to see a bunch of slashes when they don't need to. =)
2)
I understand what try-catch-finally is, but why use finally?
You could just
| Code: |
try
{
file = new FileStream("c:\\verify.ini", FileMode.Open);
reader = new StreamReader(file);
if (reader.ReadLine() == "0x00456")
{
MessageBox.show("j00 Failz");
}
}
reader.Close();
file.Close();
|
Is it supposed to be good practice or something?[/quote]
Well, No one will see the slashes, considering the Bypass Source Code won't be for the public.
_________________
CEF Moderator since 2007 ^_^
ZenX-Engine |
|
| Back to top |
|
 |
samuri25404 Grandmaster Cheater
Reputation: 7
Joined: 04 May 2007 Posts: 955 Location: Why do you care?
|
Posted: Sun Nov 18, 2007 10:14 pm Post subject: |
|
|
The Source Code, I mean, and I've debugged before with like:
| Code: |
C:\\Documents and Settings\\s\\fgaw\\ge\\\\asd\\
|
And it gets REALLY confusing after a while--especially after your eyes have been staring at the screen for who knows how long--I like to limit the ammount that I have to see that.
~~
Btw, you may want to use the obfuscator, if you don't want the source to be public and you're doing C#.
~~
@Appal
So the code won't continue if the try throws an error without the finally?
I never knew that--you learn something every day! =)
|
|
| Back to top |
|
 |
ZenX Grandmaster Cheater Supreme
Reputation: 1
Joined: 26 May 2007 Posts: 1021 Location: ">>Pointer<<" : Address 00400560 Offset :1FE
|
Posted: Sun Nov 18, 2007 10:52 pm Post subject: |
|
|
obfuscator?
What is that?Some sort of Application protection?
_________________
CEF Moderator since 2007 ^_^
ZenX-Engine |
|
| Back to top |
|
 |
samuri25404 Grandmaster Cheater
Reputation: 7
Joined: 04 May 2007 Posts: 955 Location: Why do you care?
|
Posted: Mon Nov 19, 2007 9:47 am Post subject: |
|
|
Basically.
It makes your source code in the ILASM (Intermediate Language Assembly--what all .NET source code turns into) completely unreadable.
If you don't have Visual Studio (i.e., you're using C# Express), I don't think you can use the obfuscator, but I'd be willing to do it for you. (I don't even play Lunia, I'm just a little curious about what your program's doing.)
If you don't believe me, I'll show you this:
http://img517.imageshack.us/my.php?image=comparecl0.png
(P.S., don't rag on me about the handwriting, I'm left-handed)
|
|
| Back to top |
|
 |
|