OldSchoolHack

Register / Login English

error LNK2001

icon Thread: [Help] error LNK2001

Join Date: Sep 2013

Posts: 5

User-Rating:

1 positive
0 negative
Quote from
Please dont include CPP files. Add them to your project files in Visual Studio.
understand new question

TEXT Code:
  1. HRESULT APIENTRY myEndScene(LPDIRECT3DDEVICE9 pDevice)
  2. {
  3. if (Create)
  4. {
  5. D3DVIEWPORT9 viewP;
  6. pDevice->GetViewport(&viewP);
  7. POINT cpos;
  8. GetCursorPos(&cpos);
  9. ScreenToClient(GetForegroundWindow(), &cpos); // Coors Relative to Foreground Windows
  10.  
  11.  
  12. static bool initGui = true;
  13. if (initGui)
  14. {
  15. initGui = false;
  16. Application::Instance()->Create(new Drawing::RendererDX9(pDevice)); //create Application
  17. Application::Instance()->Run(std::shared_ptr<Form>(new MainForm())); //set our mainform
  18. Application::Instance()->Enable(); //enable GUI
  19. }
  20.  
  21. if (GetAsyncKeyState(VK_INSERT) & 1) {
  22. if (!MenuActive) {
  23. Application::Instance()->Enable();
  24. MenuActive = true;
  25. }
  26. else {
  27. Application::Instance()->Disable();
  28. MenuActive = false;
  29. }
  30. }
  31. HWND hwnd=FindWindow(0,"Warface");
  32.  
  33. ShowWindow(hwnd,SW_SHOWDEFAULT);
  34. UpdateWindow(hwnd);
  35. MSG msg;
  36. ZeroMemory(&msg, sizeof(msg));
  37. if (PeekMessage(&msg, 0, 0, 0, PM_REMOVE))
  38. {
  39. input.ProcessMessage(&msg);
  40. if (msg.message == WM_QUIT)
  41. return pEndScene(pDevice);
  42. TranslateMessage(&msg);
  43. DispatchMessage(&msg);
  44. }
  45. else
  46. {
  47. Application::Instance()->GetRenderer()->Begin(); //begin rendering
  48. Application::Instance()->Render(); //render gui
  49. Application::Instance()->GetRenderer()->End(); //end rendering
  50. }
  51.  
  52.  
  53. }
  54. return pEndScene(pDevice);
  55. }
Here is the code,Can Draw the MENU now.
but i can move my mouse。。。。。
http://puu.sh/7w0UB.jpg