PDA

View Full Version : When i activate one hack all hacks activate, I can't fix it..



loller90
05-31-2008, 09:43 AM
My code:


// dpblDlg.cpp : implementation file
//

#include "stdafx.h"
#include "dpbl.h"
HINSTANCE hDLL = NULL;


typedef void (*STAMINA)();
STAMINA Stamina;

typedef void (*ISPAWN)();
ISPAWN ispawn;

typedef void (*NFD)();
NFD nfd;

typedef void (*FULLBRIGHT)();
FULLBRIGHT fullbright;

typedef void (*NOSPREAD)();
NOSPREAD nospread;

typedef void (*BOXES)();
BOXES boxes;

typedef void (*NOWATER)();
NOWATER nowater;

typedef void (*FASTFAHR)();
FASTFAHR fastfahr;

#include "dpblDlg.h"
#include "resource.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CAboutDlg dialog used for App About

class CAboutDlg : public CDialog
{
public:
CAboutDlg();

// Dialog Data
//{{AFX_DATA(CAboutDlg)
enum { IDD = IDD_ABOUTBOX };
//}}AFX_DATA

// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CAboutDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL

// Implementation
protected:
afx_msg void OnContextMenu(CWnd*, CPoint point);
//{{AFX_MSG(CAboutDlg)
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};

CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
{
//{{AFX_DATA_INIT(CAboutDlg)
//}}AFX_DATA_INIT
}

void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CAboutDlg)
//}}AFX_DATA_MAP
}

BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
ON_WM_CONTEXTMENU()
//{{AFX_MSG_MAP(CAboutDlg)
// No message handlers
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CDpblDlg dialog

CDpblDlg::CDpblDlg(CWnd* pParent /*=NULL*/)
: CDialog(CDpblDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CDpblDlg)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
// Note that LoadIcon does not require a subsequent DestroyIcon in Win32
m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
}

void CDpblDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CDpblDlg)
// NOTE: the ClassWizard will add DDX and DDV calls here
//}}AFX_DATA_MAP
}

BEGIN_MESSAGE_MAP(CDpblDlg, CDialog)
//{{AFX_MSG_MAP(CDpblDlg)
ON_WM_SYSCOMMAND()
ON_WM_PAINT()
ON_WM_QUERYDRAGICON()
ON_WM_TIMER()
ON_BN_CLICKED(IDC_BUTTON1, OnButton1)
ON_BN_CLICKED(IDC_BUTTON2, OnButton2)
ON_BN_CLICKED(IDC_BUTTON3, OnButton3)
ON_BN_CLICKED(IDC_BUTTON10, OnButton10)
ON_BN_CLICKED(IDC_BUTTON4, OnButton4)
ON_BN_CLICKED(IDC_BUTTON5, OnButton5)
ON_BN_CLICKED(IDC_BUTTON7, OnButton7)
ON_BN_CLICKED(IDC_BUTTON9, OnButton9)
ON_BN_CLICKED(IDC_BUTTON8, OnButton8)
ON_BN_CLICKED(IDC_BUTTON6, OnButton6)
ON_BN_CLICKED(IDC_BUTTON11, OnButton11)
ON_BN_CLICKED(IDC_BUTTON12, OnButton12)
ON_BN_CLICKED(IDC_BUTTON13, OnButton13)
ON_BN_CLICKED(IDC_BUTTON14, OnButton14)
ON_BN_CLICKED(IDC_BUTTON15, OnButton15)
ON_BN_CLICKED(IDC_BUTTON16, OnButton16)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CDpblDlg message handlers

BOOL CDpblDlg::OnInitDialog()

{
hDLL = AfxLoadLibrary("dritarsdll");

if( hDLL == NULL )
{
MessageBox("Could not load dritarsdll.dll");
}
else
{
Stamina = (STAMINA)GetProcAddress(hDLL, "Stamina");
ispawn = (ISPAWN)GetProcAddress(hDLL, "ispawn");
nfd = (NFD)GetProcAddress(hDLL, "nfd");
fullbright = (FULLBRIGHT)GetProcAddress(hDLL, "fullbright");
nospread = (NOSPREAD)GetProcAddress(hDLL, "nospread");
boxes = (BOXES)GetProcAddress(hDLL, "boxes");
nowater = (NOWATER)GetProcAddress(hDLL, "nowater");
fastfahr = (FASTFAHR)GetProcAddress(hDLL, "fastfahr");
}


CDialog::OnInitDialog();

// Add "About..." menu item to system menu.

// IDM_ABOUTBOX must be in the system command range.
ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
ASSERT(IDM_ABOUTBOX < 0xF000);

CMenu* pSysMenu = GetSystemMenu(FALSE);
if (pSysMenu != NULL)
{
CString strAboutMenu;
strAboutMenu.LoadString(IDS_ABOUTBOX);
if (!strAboutMenu.IsEmpty())
{
pSysMenu->AppendMenu(MF_SEPARATOR);
pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
}
}

// Set the icon for this dialog. The framework does this automatically
// when the application's main window is not a dialog
SetIcon(m_hIcon, TRUE); // Set big icon
SetIcon(m_hIcon, FALSE); // Set small icon

// TODO: Add extra initialization here

return TRUE; // return TRUE unless you set the focus to a control
}

void CDpblDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
if ((nID & 0xFFF0) == IDM_ABOUTBOX)
{
CAboutDlg dlgAbout;
dlgAbout.DoModal();
}
else
{
CDialog::OnSysCommand(nID, lParam);
}
}

// If you add a minimize button to your dialog, you will need the code below
// to draw the icon. For MFC applications using the document/view model,
// this is automatically done for you by the framework.

void CDpblDlg::OnPaint()
{
if (IsIconic())
{
CPaintDC dc(this); // device context for painting

SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0);

// Center icon in client rectangle
int cxIcon = GetSystemMetrics(SM_CXICON);
int cyIcon = GetSystemMetrics(SM_CYICON);
CRect rect;
GetClientRect(&rect);
int x = (rect.Width() - cxIcon + 1) / 2;
int y = (rect.Height() - cyIcon + 1) / 2;

// Draw the icon
dc.DrawIcon(x, y, m_hIcon);
}
else
{
CDialog::OnPaint();
}
}

// The system calls this to obtain the cursor to display while the user drags
// the minimized window.
HCURSOR CDpblDlg::OnQueryDragIcon()
{
return (HCURSOR) m_hIcon;
}

void CDpblDlg::OnTimer(UINT nIDEvent)
{
switch(nIDEvent)
{
case FIRSTTIMER:
{
//Hack for timer goes here,say stamina
Stamina();
}
break; // end of a case
case SECONDTIMER:
{
//Hack for timer goes here,say stamina
ispawn();
}
break; // end of a case
case THIRDTIMER:
{
//Hack for timer goes here,say stamina
nfd();
}
break; // end of a case
case FORTHTIMER:
{
//Hack for timer goes here,say stamina
fullbright();
}
break; // end of a case
case FIFTHTIMER:
{
//Hack for timer goes here,say stamina
nospread();
}
break; // end of a case
case SIXTHTIMER:
{
//Hack for timer goes here,say stamina
boxes();
}
break; // end of a case
case SEVENTHTIMER:
{
//Hack for timer goes here,say stamina
nowater();
}
break; // end of a case
case EIGHTHTIMER:
{
//Hack for timer goes here,say stamina
fastfahr();
}
break; // end of a case
}
CDialog::OnTimer(nIDEvent);
}

void CDpblDlg::OnButton1()
{
//Test
SetTimer(FIRSTTIMER, 1, NULL);
}

void CDpblDlg::OnButton2()
{
KillTimer(FIRSTTIMER);
}

void CAboutDlg::OnContextMenu(CWnd*, CPoint point)
{

// CG: This block was added by the Pop-up Menu component
{
if (point.x == -1 && point.y == -1){
//keystroke invocation
CRect rect;
GetClientRect(rect);
ClientToScreen(rect);

point = rect.TopLeft();
point.Offset(5, 5);
}

CMenu menu;
VERIFY(menu.LoadMenu(CG_IDR_POPUP_ABOUT_DLG));

CMenu* pPopup = menu.GetSubMenu(0);
ASSERT(pPopup != NULL);
CWnd* pWndPopupOwner = this;

while (pWndPopupOwner->GetStyle() & WS_CHILD)
pWndPopupOwner = pWndPopupOwner->GetParent();

pPopup->TrackPopupMenu(TPM_LEFTALIGN | TPM_RIGHTBUTTON, point.x, point.y,
pWndPopupOwner);
}
}

void CDpblDlg::OnButton3()
{
SetTimer(SECONDTIMER, 1, NULL);
}

void CDpblDlg::OnButton10()
{
KillTimer(SECONDTIMER);

}

void CDpblDlg::OnButton4()
{
SetTimer(THIRDTIMER, 1, NULL);

}

void CDpblDlg::OnButton5()
{
SetTimer(FORTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton7()
{
SetTimer(FIFTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton9()
{
SetTimer(SIXTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton8()
{
SetTimer(SEVENTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton6()
{
SetTimer(EIGHTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton11()
{
KillTimer(THIRDTIMER);

}

void CDpblDlg::OnButton12()
{
KillTimer(FORTHTIMER);
}

void CDpblDlg::OnButton13()
{
KillTimer(FIFTHTIMER);
}

void CDpblDlg::OnButton14()
{
KillTimer(SIXTHTIMER);

}

void CDpblDlg::OnButton15()
{
KillTimer(SEVENTHTIMER);
}

void CDpblDlg::OnButton16()
{
KillTimer(EIGHTHTIMER);
}

I defined all them in resources:


#define IDC_BUTTON1 1000
#define IDC_BUTTON2 1001
#define FIRSTTIMER 1002
#define IDC_BUTTON3 1003
#define SECONDTIMER 1004
#define IDC_BUTTON4 1005
#define THIRDTIMER 1006
#define IDC_BUTTON5 1007
#define FORTHTIMER 1008
#define IDC_BUTTON6 1009
#define FIFTHTIMER 1010
#define IDC_BUTTON7 1011
#define SIXTHTIMER 1012
#define IDC_BUTTON8 1013
#define SEVENTHTIMER 1014
#define IDC_BUTTON9 1015
#define EIGHTHTIMER 1016
#define IDC_BUTTON10 1017
#define IDC_BUTTON11 1018
#define IDC_BUTTON12 1019
#define IDC_BUTTON13 1020
#define IDC_BUTTON14 1021
#define IDC_BUTTON15 1023
#define IDC_BUTTON16 1024
#define IDC_PICTURE 1025
#define IDC_DRITAR 1026

But when i activate one hack all of them activate. Help please!

P.S. I will thank your post!

CptM0rg@n
06-01-2008, 09:43 PM
dude im good in C++ but i cant read that, looks really confusing, i code C++ different.

spartacchio
06-02-2008, 04:43 AM
My code:


// dpblDlg.cpp : implementation file
//

#include "stdafx.h"
#include "dpbl.h"
HINSTANCE hDLL = NULL;


typedef void (*STAMINA)();
STAMINA Stamina;

typedef void (*ISPAWN)();
ISPAWN ispawn;

typedef void (*NFD)();
NFD nfd;

typedef void (*FULLBRIGHT)();
FULLBRIGHT fullbright;

typedef void (*NOSPREAD)();
NOSPREAD nospread;

typedef void (*BOXES)();
BOXES boxes;

typedef void (*NOWATER)();
NOWATER nowater;

typedef void (*FASTFAHR)();
FASTFAHR fastfahr;

#include "dpblDlg.h"
#include "resource.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CAboutDlg dialog used for App About

class CAboutDlg : public CDialog
{
public:
CAboutDlg();

// Dialog Data
//{{AFX_DATA(CAboutDlg)
enum { IDD = IDD_ABOUTBOX };
//}}AFX_DATA

// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CAboutDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL

// Implementation
protected:
afx_msg void OnContextMenu(CWnd*, CPoint point);
//{{AFX_MSG(CAboutDlg)
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};

CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
{
//{{AFX_DATA_INIT(CAboutDlg)
//}}AFX_DATA_INIT
}

void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CAboutDlg)
//}}AFX_DATA_MAP
}

BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
ON_WM_CONTEXTMENU()
//{{AFX_MSG_MAP(CAboutDlg)
// No message handlers
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CDpblDlg dialog

CDpblDlg::CDpblDlg(CWnd* pParent /*=NULL*/)
: CDialog(CDpblDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CDpblDlg)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
// Note that LoadIcon does not require a subsequent DestroyIcon in Win32
m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
}

void CDpblDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CDpblDlg)
// NOTE: the ClassWizard will add DDX and DDV calls here
//}}AFX_DATA_MAP
}

BEGIN_MESSAGE_MAP(CDpblDlg, CDialog)
//{{AFX_MSG_MAP(CDpblDlg)
ON_WM_SYSCOMMAND()
ON_WM_PAINT()
ON_WM_QUERYDRAGICON()
ON_WM_TIMER()
ON_BN_CLICKED(IDC_BUTTON1, OnButton1)
ON_BN_CLICKED(IDC_BUTTON2, OnButton2)
ON_BN_CLICKED(IDC_BUTTON3, OnButton3)
ON_BN_CLICKED(IDC_BUTTON10, OnButton10)
ON_BN_CLICKED(IDC_BUTTON4, OnButton4)
ON_BN_CLICKED(IDC_BUTTON5, OnButton5)
ON_BN_CLICKED(IDC_BUTTON7, OnButton7)
ON_BN_CLICKED(IDC_BUTTON9, OnButton9)
ON_BN_CLICKED(IDC_BUTTON8, OnButton8)
ON_BN_CLICKED(IDC_BUTTON6, OnButton6)
ON_BN_CLICKED(IDC_BUTTON11, OnButton11)
ON_BN_CLICKED(IDC_BUTTON12, OnButton12)
ON_BN_CLICKED(IDC_BUTTON13, OnButton13)
ON_BN_CLICKED(IDC_BUTTON14, OnButton14)
ON_BN_CLICKED(IDC_BUTTON15, OnButton15)
ON_BN_CLICKED(IDC_BUTTON16, OnButton16)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CDpblDlg message handlers

BOOL CDpblDlg::OnInitDialog()

{
hDLL = AfxLoadLibrary("dritarsdll");

if( hDLL == NULL )
{
MessageBox("Could not load dritarsdll.dll");
}
else
{
Stamina = (STAMINA)GetProcAddress(hDLL, "Stamina");
ispawn = (ISPAWN)GetProcAddress(hDLL, "ispawn");
nfd = (NFD)GetProcAddress(hDLL, "nfd");
fullbright = (FULLBRIGHT)GetProcAddress(hDLL, "fullbright");
nospread = (NOSPREAD)GetProcAddress(hDLL, "nospread");
boxes = (BOXES)GetProcAddress(hDLL, "boxes");
nowater = (NOWATER)GetProcAddress(hDLL, "nowater");
fastfahr = (FASTFAHR)GetProcAddress(hDLL, "fastfahr");
}


CDialog::OnInitDialog();

// Add "About..." menu item to system menu.

// IDM_ABOUTBOX must be in the system command range.
ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
ASSERT(IDM_ABOUTBOX < 0xF000);

CMenu* pSysMenu = GetSystemMenu(FALSE);
if (pSysMenu != NULL)
{
CString strAboutMenu;
strAboutMenu.LoadString(IDS_ABOUTBOX);
if (!strAboutMenu.IsEmpty())
{
pSysMenu->AppendMenu(MF_SEPARATOR);
pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
}
}

// Set the icon for this dialog. The framework does this automatically
// when the application's main window is not a dialog
SetIcon(m_hIcon, TRUE); // Set big icon
SetIcon(m_hIcon, FALSE); // Set small icon

// TODO: Add extra initialization here

return TRUE; // return TRUE unless you set the focus to a control
}

void CDpblDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
if ((nID & 0xFFF0) == IDM_ABOUTBOX)
{
CAboutDlg dlgAbout;
dlgAbout.DoModal();
}
else
{
CDialog::OnSysCommand(nID, lParam);
}
}

// If you add a minimize button to your dialog, you will need the code below
// to draw the icon. For MFC applications using the document/view model,
// this is automatically done for you by the framework.

void CDpblDlg::OnPaint()
{
if (IsIconic())
{
CPaintDC dc(this); // device context for painting

SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0);

// Center icon in client rectangle
int cxIcon = GetSystemMetrics(SM_CXICON);
int cyIcon = GetSystemMetrics(SM_CYICON);
CRect rect;
GetClientRect(&rect);
int x = (rect.Width() - cxIcon + 1) / 2;
int y = (rect.Height() - cyIcon + 1) / 2;

// Draw the icon
dc.DrawIcon(x, y, m_hIcon);
}
else
{
CDialog::OnPaint();
}
}

// The system calls this to obtain the cursor to display while the user drags
// the minimized window.
HCURSOR CDpblDlg::OnQueryDragIcon()
{
return (HCURSOR) m_hIcon;
}

void CDpblDlg::OnTimer(UINT nIDEvent)
{
switch(nIDEvent)
{
case FIRSTTIMER:
{
//Hack for timer goes here,say stamina
Stamina();
}
break; // end of a case
case SECONDTIMER:
{
//Hack for timer goes here,say stamina
ispawn();
}
break; // end of a case
case THIRDTIMER:
{
//Hack for timer goes here,say stamina
nfd();
}
break; // end of a case
case FORTHTIMER:
{
//Hack for timer goes here,say stamina
fullbright();
}
break; // end of a case
case FIFTHTIMER:
{
//Hack for timer goes here,say stamina
nospread();
}
break; // end of a case
case SIXTHTIMER:
{
//Hack for timer goes here,say stamina
boxes();
}
break; // end of a case
case SEVENTHTIMER:
{
//Hack for timer goes here,say stamina
nowater();
}
break; // end of a case
case EIGHTHTIMER:
{
//Hack for timer goes here,say stamina
fastfahr();
}
break; // end of a case
}
CDialog::OnTimer(nIDEvent);
}

void CDpblDlg::OnButton1()
{
//Test
SetTimer(FIRSTTIMER, 1, NULL);
}

void CDpblDlg::OnButton2()
{
KillTimer(FIRSTTIMER);
}

void CAboutDlg::OnContextMenu(CWnd*, CPoint point)
{

// CG: This block was added by the Pop-up Menu component
{
if (point.x == -1 && point.y == -1){
//keystroke invocation
CRect rect;
GetClientRect(rect);
ClientToScreen(rect);

point = rect.TopLeft();
point.Offset(5, 5);
}

CMenu menu;
VERIFY(menu.LoadMenu(CG_IDR_POPUP_ABOUT_DLG));

CMenu* pPopup = menu.GetSubMenu(0);
ASSERT(pPopup != NULL);
CWnd* pWndPopupOwner = this;

while (pWndPopupOwner->GetStyle() & WS_CHILD)
pWndPopupOwner = pWndPopupOwner->GetParent();

pPopup->TrackPopupMenu(TPM_LEFTALIGN | TPM_RIGHTBUTTON, point.x, point.y,
pWndPopupOwner);
}
}

void CDpblDlg::OnButton3()
{
SetTimer(SECONDTIMER, 1, NULL);
}

void CDpblDlg::OnButton10()
{
KillTimer(SECONDTIMER);

}

void CDpblDlg::OnButton4()
{
SetTimer(THIRDTIMER, 1, NULL);

}

void CDpblDlg::OnButton5()
{
SetTimer(FORTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton7()
{
SetTimer(FIFTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton9()
{
SetTimer(SIXTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton8()
{
SetTimer(SEVENTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton6()
{
SetTimer(EIGHTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton11()
{
KillTimer(THIRDTIMER);

}

void CDpblDlg::OnButton12()
{
KillTimer(FORTHTIMER);
}

void CDpblDlg::OnButton13()
{
KillTimer(FIFTHTIMER);
}

void CDpblDlg::OnButton14()
{
KillTimer(SIXTHTIMER);

}

void CDpblDlg::OnButton15()
{
KillTimer(SEVENTHTIMER);
}

void CDpblDlg::OnButton16()
{
KillTimer(EIGHTHTIMER);
}

I defined all them in resources:


#define IDC_BUTTON1 1000
#define IDC_BUTTON2 1001
#define FIRSTTIMER 1002
#define IDC_BUTTON3 1003
#define SECONDTIMER 1004
#define IDC_BUTTON4 1005
#define THIRDTIMER 1006
#define IDC_BUTTON5 1007
#define FORTHTIMER 1008
#define IDC_BUTTON6 1009
#define FIFTHTIMER 1010
#define IDC_BUTTON7 1011
#define SIXTHTIMER 1012
#define IDC_BUTTON8 1013
#define SEVENTHTIMER 1014
#define IDC_BUTTON9 1015
#define EIGHTHTIMER 1016
#define IDC_BUTTON10 1017
#define IDC_BUTTON11 1018
#define IDC_BUTTON12 1019
#define IDC_BUTTON13 1020
#define IDC_BUTTON14 1021
#define IDC_BUTTON15 1023
#define IDC_BUTTON16 1024
#define IDC_PICTURE 1025
#define IDC_DRITAR 1026

But when i activate one hack all of them activate. Help please!

P.S. I will thank your post!

i don't know why all hack acctivate but i know that boxes and NOOPED functions in general doesn't go in a TIMER.

MezeyTrobo
03-11-2009, 06:22 AM
My code:


// dpblDlg.cpp : implementation file
//

#include "stdafx.h"
#include "dpbl.h"
HINSTANCE hDLL = NULL;


typedef void (*STAMINA)();
STAMINA Stamina;

typedef void (*ISPAWN)();
ISPAWN ispawn;

typedef void (*NFD)();
NFD nfd;

typedef void (*FULLBRIGHT)();
FULLBRIGHT fullbright;

typedef void (*NOSPREAD)();
NOSPREAD nospread;

typedef void (*BOXES)();
BOXES boxes;

typedef void (*NOWATER)();
NOWATER nowater;

typedef void (*FASTFAHR)();
FASTFAHR fastfahr;

#include "dpblDlg.h"
#include "resource.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CAboutDlg dialog used for App About

class CAboutDlg : public CDialog
{
public:
CAboutDlg();

// Dialog Data
//{{AFX_DATA(CAboutDlg)
enum { IDD = IDD_ABOUTBOX };
//}}AFX_DATA

// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CAboutDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL

// Implementation
protected:
afx_msg void OnContextMenu(CWnd*, CPoint point);
//{{AFX_MSG(CAboutDlg)
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};

CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
{
//{{AFX_DATA_INIT(CAboutDlg)
//}}AFX_DATA_INIT
}

void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CAboutDlg)
//}}AFX_DATA_MAP
}

BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
ON_WM_CONTEXTMENU()
//{{AFX_MSG_MAP(CAboutDlg)
// No message handlers
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CDpblDlg dialog

CDpblDlg::CDpblDlg(CWnd* pParent /*=NULL*/)
: CDialog(CDpblDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CDpblDlg)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
// Note that LoadIcon does not require a subsequent DestroyIcon in Win32
m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
}

void CDpblDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CDpblDlg)
// NOTE: the ClassWizard will add DDX and DDV calls here
//}}AFX_DATA_MAP
}

BEGIN_MESSAGE_MAP(CDpblDlg, CDialog)
//{{AFX_MSG_MAP(CDpblDlg)
ON_WM_SYSCOMMAND()
ON_WM_PAINT()
ON_WM_QUERYDRAGICON()
ON_WM_TIMER()
ON_BN_CLICKED(IDC_BUTTON1, OnButton1)
ON_BN_CLICKED(IDC_BUTTON2, OnButton2)
ON_BN_CLICKED(IDC_BUTTON3, OnButton3)
ON_BN_CLICKED(IDC_BUTTON10, OnButton10)
ON_BN_CLICKED(IDC_BUTTON4, OnButton4)
ON_BN_CLICKED(IDC_BUTTON5, OnButton5)
ON_BN_CLICKED(IDC_BUTTON7, OnButton7)
ON_BN_CLICKED(IDC_BUTTON9, OnButton9)
ON_BN_CLICKED(IDC_BUTTON8, OnButton8)
ON_BN_CLICKED(IDC_BUTTON6, OnButton6)
ON_BN_CLICKED(IDC_BUTTON11, OnButton11)
ON_BN_CLICKED(IDC_BUTTON12, OnButton12)
ON_BN_CLICKED(IDC_BUTTON13, OnButton13)
ON_BN_CLICKED(IDC_BUTTON14, OnButton14)
ON_BN_CLICKED(IDC_BUTTON15, OnButton15)
ON_BN_CLICKED(IDC_BUTTON16, OnButton16)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CDpblDlg message handlers

BOOL CDpblDlg::OnInitDialog()

{
hDLL = AfxLoadLibrary("dritarsdll");

if( hDLL == NULL )
{
MessageBox("Could not load dritarsdll.dll");
}
else
{
Stamina = (STAMINA)GetProcAddress(hDLL, "Stamina");
ispawn = (ISPAWN)GetProcAddress(hDLL, "ispawn");
nfd = (NFD)GetProcAddress(hDLL, "nfd");
fullbright = (FULLBRIGHT)GetProcAddress(hDLL, "fullbright");
nospread = (NOSPREAD)GetProcAddress(hDLL, "nospread");
boxes = (BOXES)GetProcAddress(hDLL, "boxes");
nowater = (NOWATER)GetProcAddress(hDLL, "nowater");
fastfahr = (FASTFAHR)GetProcAddress(hDLL, "fastfahr");
}


CDialog::OnInitDialog();

// Add "About..." menu item to system menu.

// IDM_ABOUTBOX must be in the system command range.
ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
ASSERT(IDM_ABOUTBOX < 0xF000);

CMenu* pSysMenu = GetSystemMenu(FALSE);
if (pSysMenu != NULL)
{
CString strAboutMenu;
strAboutMenu.LoadString(IDS_ABOUTBOX);
if (!strAboutMenu.IsEmpty())
{
pSysMenu->AppendMenu(MF_SEPARATOR);
pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
}
}

// Set the icon for this dialog. The framework does this automatically
// when the application's main window is not a dialog
SetIcon(m_hIcon, TRUE); // Set big icon
SetIcon(m_hIcon, FALSE); // Set small icon

// TODO: Add extra initialization here

return TRUE; // return TRUE unless you set the focus to a control
}

void CDpblDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
if ((nID & 0xFFF0) == IDM_ABOUTBOX)
{
CAboutDlg dlgAbout;
dlgAbout.DoModal();
}
else
{
CDialog::OnSysCommand(nID, lParam);
}
}

// If you add a minimize button to your dialog, you will need the code below
// to draw the icon. For MFC applications using the document/view model,
// this is automatically done for you by the framework.

void CDpblDlg::OnPaint()
{
if (IsIconic())
{
CPaintDC dc(this); // device context for painting

SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0);

// Center icon in client rectangle
int cxIcon = GetSystemMetrics(SM_CXICON);
int cyIcon = GetSystemMetrics(SM_CYICON);
CRect rect;
GetClientRect(&rect);
int x = (rect.Width() - cxIcon + 1) / 2;
int y = (rect.Height() - cyIcon + 1) / 2;

// Draw the icon
dc.DrawIcon(x, y, m_hIcon);
}
else
{
CDialog::OnPaint();
}
}

// The system calls this to obtain the cursor to display while the user drags
// the minimized window.
HCURSOR CDpblDlg::OnQueryDragIcon()
{
return (HCURSOR) m_hIcon;
}

void CDpblDlg::OnTimer(UINT nIDEvent)
{
switch(nIDEvent)
{
case FIRSTTIMER:
{
//Hack for timer goes here,say stamina
Stamina();
}
break; // end of a case
case SECONDTIMER:
{
//Hack for timer goes here,say stamina
ispawn();
}
break; // end of a case
case THIRDTIMER:
{
//Hack for timer goes here,say stamina
nfd();
}
break; // end of a case
case FORTHTIMER:
{
//Hack for timer goes here,say stamina
fullbright();
}
break; // end of a case
case FIFTHTIMER:
{
//Hack for timer goes here,say stamina
nospread();
}
break; // end of a case
case SIXTHTIMER:
{
//Hack for timer goes here,say stamina
boxes();
}
break; // end of a case
case SEVENTHTIMER:
{
//Hack for timer goes here,say stamina
nowater();
}
break; // end of a case
case EIGHTHTIMER:
{
//Hack for timer goes here,say stamina
fastfahr();
}
break; // end of a case
}
CDialog::OnTimer(nIDEvent);
}

void CDpblDlg::OnButton1()
{
//Test
SetTimer(FIRSTTIMER, 1, NULL);
}

void CDpblDlg::OnButton2()
{
KillTimer(FIRSTTIMER);
}

void CAboutDlg::OnContextMenu(CWnd*, CPoint point)
{

// CG: This block was added by the Pop-up Menu component
{
if (point.x == -1 && point.y == -1){
//keystroke invocation
CRect rect;
GetClientRect(rect);
ClientToScreen(rect);

point = rect.TopLeft();
point.Offset(5, 5);
}

CMenu menu;
VERIFY(menu.LoadMenu(CG_IDR_POPUP_ABOUT_DLG));

CMenu* pPopup = menu.GetSubMenu(0);
ASSERT(pPopup != NULL);
CWnd* pWndPopupOwner = this;

while (pWndPopupOwner->GetStyle() & WS_CHILD)
pWndPopupOwner = pWndPopupOwner->GetParent();

pPopup->TrackPopupMenu(TPM_LEFTALIGN | TPM_RIGHTBUTTON, point.x, point.y,
pWndPopupOwner);
}
}

void CDpblDlg::OnButton3()
{
SetTimer(SECONDTIMER, 1, NULL);
}

void CDpblDlg::OnButton10()
{
KillTimer(SECONDTIMER);

}

void CDpblDlg::OnButton4()
{
SetTimer(THIRDTIMER, 1, NULL);

}

void CDpblDlg::OnButton5()
{
SetTimer(FORTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton7()
{
SetTimer(FIFTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton9()
{
SetTimer(SIXTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton8()
{
SetTimer(SEVENTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton6()
{
SetTimer(EIGHTHTIMER, 1, NULL);
}

void CDpblDlg::OnButton11()
{
KillTimer(THIRDTIMER);

}

void CDpblDlg::OnButton12()
{
KillTimer(FORTHTIMER);
}

void CDpblDlg::OnButton13()
{
KillTimer(FIFTHTIMER);
}

void CDpblDlg::OnButton14()
{
KillTimer(SIXTHTIMER);

}

void CDpblDlg::OnButton15()
{
KillTimer(SEVENTHTIMER);
}

void CDpblDlg::OnButton16()
{
KillTimer(EIGHTHTIMER);
}

I defined all them in resources:


#define IDC_BUTTON1 1000
#define IDC_BUTTON2 1001
#define FIRSTTIMER 1002
#define IDC_BUTTON3 1003
#define SECONDTIMER 1004
#define IDC_BUTTON4 1005
#define THIRDTIMER 1006
#define IDC_BUTTON5 1007
#define FORTHTIMER 1008
#define IDC_BUTTON6 1009
#define FIFTHTIMER 1010
#define IDC_BUTTON7 1011
#define SIXTHTIMER 1012
#define IDC_BUTTON8 1013
#define SEVENTHTIMER 1014
#define IDC_BUTTON9 1015
#define EIGHTHTIMER 1016
#define IDC_BUTTON10 1017
#define IDC_BUTTON11 1018
#define IDC_BUTTON12 1019
#define IDC_BUTTON13 1020
#define IDC_BUTTON14 1021
#define IDC_BUTTON15 1023
#define IDC_BUTTON16 1024
#define IDC_PICTURE 1025
#define IDC_DRITAR 1026

But when i activate one hack all of them activate. Help please!

P.S. I will thank your post!

sniperheadshot2sniperheadshot2sniperheadshot2

MezeyTrobo
03-11-2009, 06:26 AM
sniperheadshot2sniperheadshot2sniperheadshot2
fuucckk yyoouu nniiggaa2