Search
 
 

Display results as :
 


Rechercher Advanced Search

Latest topics
» ~=?{The future is here, TastyExploit officially open to the public}?=~
Tue Mar 02, 2010 11:00 pm by Dami

» My first aa script
Tue Mar 02, 2010 7:00 am by wafflemaster

» the real story behind Maverin
Tue Mar 02, 2010 1:33 am by SoundOfDeat

» Random spam
Mon Mar 01, 2010 11:52 pm by Danny1994

» [Request] EMS v56 Exe
Mon Mar 01, 2010 12:39 am by Dami

» [Blacklist] NX-Trading Blacklist.
Mon Mar 01, 2010 12:38 am by Danny1994

» I have a question regarding the meso farmer
Sat Feb 27, 2010 10:30 pm by Dami

» What are you listening to now?
Sat Feb 27, 2010 7:57 pm by Noname111111

» Video(s) Of The Day
Sat Feb 27, 2010 7:37 pm by Noname111111

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search
Affiliates
free forum
 



Help with C#

View previous topic View next topic Go down

Help with C#

Post by mathias on Wed Jan 13, 2010 12:35 am

Code:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Runtime.InteropServices;


namespace mathiasproject
{
    public partial class Form1 : Form
    { 
        #region Don't mess with these - External Imports

        #region Form Dragging API Support
        //The SendMessage function sends a message to a window or windows.
        [DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = false)]
        static extern IntPtr SendMessage(IntPtr hWnd, uint Msg, int wParam, int lParam);

        //ReleaseCapture releases a mouse capture
        [DllImportAttribute("user32.dll", CharSet = CharSet.Auto, SetLastError = false)]
        public static extern bool ReleaseCapture();
        //partial code acquired from
        #endregion

        [DllImport("kernel32.dll")]
        public static extern IntPtr OpenProcess(uint dwDesiredAccess, int bInheritHandle, uint dwProcessId);

        [DllImport("user32.dll", SetLastError = true)]
        private static extern uint GetWindowThreadProcessId(IntPtr hWnd, out uint lpdwProcessId);

        [DllImport("user32.dll", SetLastError = true)]
        private static extern IntPtr FindWindow(string lpClassName, string lpWindowName);

        [DllImport("user32.dll")]
        public static extern IntPtr ShowWindow(IntPtr hWnd, int nCmdShow);

        [DllImport("kernel32.dll")]
        public static extern int ReadProcessMemory(IntPtr hProcess, IntPtr lpBaseAddress, [In, Out] byte[] buffer, uint size, out IntPtr lpNumberOfBytesRead);

        [DllImport("kernel32.dll")]
        static extern Int32 WriteProcessMemory(IntPtr hProcess, IntPtr lpBaseAddress, [Out] byte[] buffer, UInt32 size, out IntPtr lpNumberOfBytesWritten);
       
        #endregion

        #region Don't mess with these variables

        private uint ProcessID;
        private IntPtr ProcessHandle;
        private IntPtr hWnd;
       
        #endregion

        #region A ton of addresses to update every patch
       
        public IntPtr HPMPAddress = (IntPtr)0x99913C;
        public Int32 HPOffset = 0xD00;
        public Int32 MPOffset = 0xD04;
        private int MyHP;
        private int MyMP;

        public IntPtr SuperTubiAddress = (IntPtr)0x4C649C;

        public IntPtr PinUndormizerAddress = (IntPtr)0x4C649C;

        #endregion

        public Form1()
        {
            InitializeComponent();
        }

        /* This will try to get basic info and display it every 250ms, until sucessful.
        * There was probably a better way to do this, but adding timers is faster. */
        private void WastingYourCPUCycles_Tick(object sender, EventArgs e)
        {
            if (ProcessHandle == (IntPtr)0)
            {
                GetWindowThreadProcessId(hWnd, out ProcessID);
                ProcessHandle = OpenProcess(0x38, 1, ProcessID);
                hWnd = FindWindow("MapleStoryClass", null);
                hWndLabel.Text = ("MS hWnd: " + Convert.ToString(hWnd));
                ProcessHandleLabel.Text = ("Process Handle: " + Convert.ToString(ProcessHandle));
            }
            else
            {
                UpdateAddressesTimer.Enabled = true;
                WastingYourCPUCycles.Enabled = false;
            }
        }

        #region Wrappers

        public byte[] ReadProcessMemory(IntPtr MemoryAddress, uint bytesToRead, out int bytesread)
        {
            IntPtr ptr;
            byte[] buffer = new byte[bytesToRead];
            ReadProcessMemory(ProcessHandle, MemoryAddress, buffer, bytesToRead, out ptr);
            bytesread = ptr.ToInt32();
            return buffer;
        }

        public void WriteProcessMemory(IntPtr address, byte[] buffer, int size)
        {
            IntPtr ptr;
            WriteProcessMemory(ProcessHandle, address, buffer, (uint)size, out ptr);
        }

        private int CurrentHP()
        {
            int HPMPInt;
            int HPAddress = BitConverter.ToInt32(ReadProcessMemory(HPMPAddress, 4, out HPMPInt), 0) + HPOffset;
            return BitConverter.ToInt32(this.ReadProcessMemory((IntPtr)HPAddress, 4, out HPMPInt), 0);
        }

        private int CurrentMP()
        {
            int HPMPInt;
            int MPAddress = BitConverter.ToInt32(ReadProcessMemory(HPMPAddress, 4, out HPMPInt), 0) + MPOffset;
            return BitConverter.ToInt32(this.ReadProcessMemory((IntPtr)MPAddress, 4, out HPMPInt), 0);
        }

        #region Simple memory edits

        private void PinUndormizerCB_CheckedChanged(object sender, EventArgs e)
        {
            if (PinUndormizerCB.Checked == true)
            {
                byte[] buffer = new byte[] { 0x0F, 0x83 };
                WriteProcessMemory(PinUndormizerCBAddress, buffer, buffer.Length);
            }
            else if (PinUndormizerCBCB.Checked == false)
            {
                byte[] buffer = new byte[] { 0x0F, 0x86 };
                WriteProcessMemory(PinUndormizerCBAddress, buffer, buffer.Length);
            }
        }

        private void SuperTubiCB_CheckedChanged(object sender, EventArgs e)
        {
            if (SuperTubiCB.Checked == true)
            {
                byte[] buffer = new byte[] { 0x90, 0x90 };
                WriteProcessMemory(SuperTubiAddress, buffer, buffer.Length);
            }
            else if (SuperTubiCB.Checked == false)
            {
                byte[] buffer = new byte[] { 0x75, 0x36 };
                WriteProcessMemory(SuperTubiAddress, buffer, buffer.Length);
            }
        }

        #endregion

        private void Form1_MouseDown(object sender, MouseEventArgs e)
        {
           
            if (e.Button == MouseButtons.Left)
            {
                ReleaseCapture();
                SendMessage(this.Handle, 0xa1, 0x2, 0);
            }
           
        }

    }
}

check if everything well done
this is my problem
http://img706.imageshack.us/img706/9868/bladb.png

mathias
BanHammered
BanHammered

Posts : 44
Join date : 2010-01-02
Age : 23

Back to top Go down

Re: Help with C#

Post by Eltax on Wed Jan 13, 2010 2:09 am

Arent you missing a #endregion for your wrapper Smile?
avatar
Eltax
New member
New member

Posts : 53
Join date : 2009-11-30
Location : Denmark

Back to top Go down

Re: Help with C#

Post by Dami on Wed Jan 13, 2010 5:05 am

We cannot possibly add people to members group who cannot use code tags on theyr post.
Now you took 5 seconds of my time on editing your post...
avatar
Dami
Dragon
Dragon

Posts : 1414
Join date : 2009-08-10
Age : 28
Location : Finland

Back to top Go down

Re: Help with C#

Post by kaiseko on Wed Jan 13, 2010 7:48 am

lololololol, how can you not know whats wrong

kaiseko
New member
New member

Posts : 54
Join date : 2009-10-29

Back to top Go down

Re: Help with C#

Post by mathias on Wed Jan 13, 2010 10:08 pm

thx
I fixed everything
a few days here it put an

dami
but do not close the topic

how add this script

Spoiler:
[Enable]
//Pin Unrandomizer
alloc(pinunrandom,512)
label(returnhere)
label(zeroAlign)
label(continueCompare)

0074D33C: // 03 C2 80 38 0A 73 07 80 E1 01 D0 E1 EB 03 80 E1
jmp pinunrandom
returnhere:

pinunrandom:
add eax,edx
push edx
shr edx,1
cmp edx,09
je zeroAlign
ja continueCompare
inc edx
jmp continueCompare

zeroAlign:
mov edx,0

continueCompare:
mov [eax],edx
pop edx
cmp byte ptr [eax],0a
jmp returnhere

[Disable]
0074D33C:
add eax,edx
cmp byte ptr [eax],0a

dealloc(pinunrandom)

to here
Code:
private void PinUndormizerCB_CheckedChanged(object sender, EventArgs e)
        {
            if (PinUndormizerCB.Checked == true)
            {
                byte[] buffer = new byte[] { 0x0F, 0x83 };
                WriteProcessMemory(PinUndormizerCBAddress, buffer, buffer.Length);
            }
            else if (PinUndormizerCB.Checked == false)
            {
                byte[] buffer = new byte[] { 0x0F, 0x86 };
                WriteProcessMemory(PinUndormizerCBAddress, buffer, buffer.Length);
            }
        }

mathias
BanHammered
BanHammered

Posts : 44
Join date : 2010-01-02
Age : 23

Back to top Go down

Re: Help with C#

Post by Dami on Thu Jan 14, 2010 12:15 am

mathias wrote:thx
I fixed everything
a few days here it put an

dami
but do not close the topic

how add this script

Spoiler:
[Enable]
//Pin Unrandomizer
alloc(pinunrandom,512)
label(returnhere)
label(zeroAlign)
label(continueCompare)

0074D33C: // 03 C2 80 38 0A 73 07 80 E1 01 D0 E1 EB 03 80 E1
jmp pinunrandom
returnhere:

pinunrandom:
add eax,edx
push edx
shr edx,1
cmp edx,09
je zeroAlign
ja continueCompare
inc edx
jmp continueCompare

zeroAlign:
mov edx,0

continueCompare:
mov [eax],edx
pop edx
cmp byte ptr [eax],0a
jmp returnhere

[Disable]
0074D33C:
add eax,edx
cmp byte ptr [eax],0a

dealloc(pinunrandom)

to here
Code:
private void PinUndormizerCB_CheckedChanged(object sender, EventArgs e)
        {
            if (PinUndormizerCB.Checked == true)
            {
                byte[] buffer = new byte[] { 0x0F, 0x83 };
                WriteProcessMemory(PinUndormizerCBAddress, buffer, buffer.Length);
            }
            else if (PinUndormizerCB.Checked == false)
            {
                byte[] buffer = new byte[] { 0x0F, 0x86 };
                WriteProcessMemory(PinUndormizerCBAddress, buffer, buffer.Length);
            }
        }

You cant, thats why i dont support shitty languages like C#.
Well perhaps there is a gay way to do it, but still...
avatar
Dami
Dragon
Dragon

Posts : 1414
Join date : 2009-08-10
Age : 28
Location : Finland

Back to top Go down

Re: Help with C#

Post by mathias on Thu Jan 14, 2010 12:42 am

why my hacks dont working
Code:
   public IntPtr SuperTubiCBAddress = (IntPtr)0x4C738C;

        public IntPtr SpeedWalkCBAddress = (IntPtr)0x82212F;

   #region Simple memory edits

        private void SpeedWalkCB_CheckedChanged(object sender, EventArgs e)
        {
            if (SpeedWalkCB.Checked == true)
            {
                byte[] buffer = new byte[] { 0x4D };
                WriteProcessMemory(SpeedWalkCBAddress, buffer, buffer.Length);
            }
            else if (SpeedWalkCB.Checked == false)
            {
                byte[] buffer = new byte[] { 0x4D };
                WriteProcessMemory(SpeedWalkCBAddress, buffer, buffer.Length );

            }
        }

        private void SuperTubiCB_CheckedChanged(object sender, EventArgs e)
        {
            if (SuperTubiCB.Checked == true)
            {
                byte[] buffer = new byte[] { 0x5A, 0x5A };
                WriteProcessMemory(SuperTubiCBAddress, buffer, buffer.Length);
            }
            else if (SuperTubiCB.Checked == false)
            {
                byte[] buffer = new byte[] { 0x4B, 0x24 };
                WriteProcessMemory(SuperTubiCBAddress, buffer, buffer.Length);
            }
        }
this is my code super tubi and speed walk

mathias
BanHammered
BanHammered

Posts : 44
Join date : 2010-01-02
Age : 23

Back to top Go down

Re: Help with C#

Post by wafflemaster on Sat Jan 16, 2010 7:54 am

Dami wrote:You cant, thats why i dont support shitty languages like C#.
Well perhaps there is a gay way to do it, but still...

I made a guide to do it the gay way. Smile

@above: WriteProcessMemory is simply a wrapper for NtWriteVirtualMemory. And that ends up being a wrapper for some KiFastSystemCall. HackShield hooked it in kernelmode. So if you want to use that API, you're screwed unless you rape HS up the ass or write a driver. see http://www.uc-forum.com/forum/americas-army-coding-tutorials/60431-read-writeprocessmemory.html for more info.

wafflemaster
V.I.P
V.I.P

Posts : 123
Join date : 2009-10-27

Back to top Go down

Re: Help with C#

Post by mathias on Sat Jan 16, 2010 4:31 pm

my hacks dont working
when i run the maple story and i tick the cheats nothing happens
why?

mathias
BanHammered
BanHammered

Posts : 44
Join date : 2010-01-02
Age : 23

Back to top Go down

Re: Help with C#

Post by Danny1994 on Sat Jan 16, 2010 6:04 pm

Because you need a Bypass ? o_0
avatar
Danny1994
Silver Member
Silver Member

Posts : 376
Join date : 2009-08-16
Age : 23
Location : Germany

Back to top Go down

Re: Help with C#

Post by Eltax on Sat Jan 16, 2010 6:36 pm

mathias wrote:my hacks dont working
when i run the maple story and i tick the cheats nothing happens
why?

Read above post?

wafflemaster wrote:
@above: WriteProcessMemory is simply a wrapper for NtWriteVirtualMemory. And that ends up being a wrapper for some KiFastSystemCall. HackShield hooked it in kernelmode. So if you want to use that API, you're screwed unless you rape HS up the ass or write a driver. see http://www.uc-forum.com/forum/americas-army-coding-tutorials/60431-read-writeprocessmemory.html for more info.
avatar
Eltax
New member
New member

Posts : 53
Join date : 2009-11-30
Location : Denmark

Back to top Go down

Re: Help with C#

Post by Dami on Sat Jan 16, 2010 7:42 pm

Eltax wrote:
mathias wrote:my hacks dont working
when i run the maple story and i tick the cheats nothing happens
why?

Read above post?

wafflemaster wrote:
@above: WriteProcessMemory is simply a wrapper for NtWriteVirtualMemory. And that ends up being a wrapper for some KiFastSystemCall. HackShield hooked it in kernelmode. So if you want to use that API, you're screwed unless you rape HS up the ass or write a driver. see http://www.uc-forum.com/forum/americas-army-coding-tutorials/60431-read-writeprocessmemory.html for more info.

Yeah, as long as you dont use RPM, WPM, unhook the driver or write your own driver for it, you have no problems.
avatar
Dami
Dragon
Dragon

Posts : 1414
Join date : 2009-08-10
Age : 28
Location : Finland

Back to top Go down

Re: Help with C#

Post by mathias on Sat Jan 16, 2010 8:20 pm

so waffle soucre need bypass
kitterz soucre dont need bypass?

mathias
BanHammered
BanHammered

Posts : 44
Join date : 2010-01-02
Age : 23

Back to top Go down

Re: Help with C#

Post by Eltax on Sat Jan 16, 2010 9:44 pm

mathias wrote:so waffle soucre need bypass
kitterz soucre dont need bypass?

Its the language witch you write in.
The C# memory functions are hook by hs (Not working without bypass)
avatar
Eltax
New member
New member

Posts : 53
Join date : 2009-11-30
Location : Denmark

Back to top Go down

Re: Help with C#

Post by Dami on Sat Jan 16, 2010 11:22 pm

Eltax wrote:
mathias wrote:so waffle soucre need bypass
kitterz soucre dont need bypass?

Its the language witch you write in.
The C# memory functions are hook by hs (Not working without bypass)

Not really... but ah well...
avatar
Dami
Dragon
Dragon

Posts : 1414
Join date : 2009-08-10
Age : 28
Location : Finland

Back to top Go down

Re: Help with C#

Post by mathias on Sun Jan 17, 2010 1:12 am

so why my hacks dont working
i update it
plss help me

mathias
BanHammered
BanHammered

Posts : 44
Join date : 2010-01-02
Age : 23

Back to top Go down

Re: Help with C#

Post by kaiseko on Sun Jan 17, 2010 3:09 am

wow, read?

You need a fuckin bypass...

WPM/RPM is hooked

kaiseko
New member
New member

Posts : 54
Join date : 2009-10-29

Back to top Go down

Re: Help with C#

Post by Sponsored content


Sponsored content


Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum