Solo usuarios registrados pueden comentar y agradecer, Logueate o Registrate

Autor Topic: Fix Cursor Position on NPP/Shop Open  (Visto 4674 veces)

0 Miembros and 1 Guest are viewing this topic.

Offline smiley Posteado: April 28, 2020, 09:39:48 PM | Modificado: May 01, 2020, 10:53:46 AM by smiley

  • C++ Coder
  • 0 puntos por ventas
  • *
  • Rank: Principiante
  • Posts: 23
  • Gracias recibida: 472
  • br
It is me now, this will fix cursor position when open an NPC in game.
To avoid double click and buy item when shop opens.

Tecnically speaking, i get current game window position to calculate where the cursor will be set.
So this fix SetCursorPos from main

Ps.
That fix only works in window mode, since in full screen mouse position is alread fixed!

Someone can post a vídeo with fix and without fix?
Thanks again




 sueno

Gracias:

tutu100, darkes607, angel321, 4312204, KhongGianOL, korron, VikingoMU, douglera21, god_mode, Xenos, carmax, nhantac, Domedica, CorsarioDgx, glmmlg, stopk, xlockee, hide3by, DeilanSasame, rando, KropaPL, e911217, dakosmu, boybudz321, 1732313, alexfy, giveusatan, deathsquad, warrior, Smudevelop, Kosh, llZeuzll, mocorongo, ProTecno, Honghai1992, Shaper, Jarvis, xufqing, lunaticodeveloper, sagamacus, santo12, zekcrom, usersa, walkeny, RifleMaN_, MsotoC, kenh14, nofeara, Shellshock, ledemkhoc, anh1pk, jm2003, Hiếu Đại Ca, okilove23, solar, CezarMaster, mrcomhp, tcbaoanh, herjuni, lstuan, phuongcuongmsqm, thieugiapc, dlawls662, nhanphu200, judakiss21, PS Sistemas, djnansr, beibei, boylasd, victorrz17, vipgale01, Wikka, thesofer, erickmalfoy, jhonhy, haziel, zhujianhui, xiazaipw, JavixFer, samsunggon, waynemartins, mugloves99, kimrubi, ruojing, donciukas14, amitnet1, Erick05, NghienMU, thienthan1117, zhangjianle865, banam8910, Lazarocp2020, barteo, Almdar, animator, GoldSun, OneMU, wiljipa, Djassar, tammadall, tilmur, hinam.97, Dragonvl15, showmax, tiendoanit, Cartman, mattihi1mi, cobyzero, PachoRasta, TheSilencer, dark, Dieguinho, victormvw, nonnan005, Pasa_Pal_Fondo, GabrielDevel, xtestx, Xysad, Liaon, dhaomao, EaglE, realman, 161012, cepo, 423646802, comelon666, Genilson23, Denis Alves, luciferlg, leones55, NoobDK, GabrielDev, sagat202, Karuritoku, TheKing027, mastermcy, thunwa1, alexytoo, Wendigo, MiRoKu, pquintal, Ryuno, gacon201294, InnovateMu, Alexunder, BaTmaaN, OverLoad, Pyke, andreyzz, draco425, wnz5678, smallz170, Zeus, DarkovaX, kayito, esteban, luckydead, stark98, PhantomKr, SetecSoft, Llalex, Keko, allhoy, Peluuca, AZURE, seedmaker, powerpatic, hiep, npt.formu, 183358, Hugo, kind, Yasser, NewGate, kaiocnx, gauyeutho, djagripnos, LTP Team, artem, c4nhsatcodong, Crowley, josecola, Iямαηɗαɗ ☠, kaisudo, muzic25, Lude, wolffrox, EmmaDCG, iggfree, emersonx13, Odisk, GX_KYO, k12leito, dahouzi, takumi12, TzCr4ck, ailsoncost, matheusgom, Shaman, NasLy, knight.php, Luke Strike, Mathi, spartacus, beecubin, cri0, louis, xxmenonxx, SaintZeus, jones1010, RafhaelSouza, mundomuc, axeman192, yhoon, melo920

Offline axeman192 #1 Posteado: April 28, 2020, 10:10:04 PM

  • 3D Maker
  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 287
  • Gracias recibida: 12017
  • vn
Error de no conectarse a Main.exe .


Offline smiley #2 Posteado: April 28, 2020, 10:11:59 PM

  • C++ Coder
  • 0 puntos por ventas
  • *
  • Rank: Principiante
  • Posts: 23
  • Gracias recibida: 472
  • br
Error de no conectarse a Main.exe .

Explain better the problem  lol


Offline axeman192 #3 Posteado: April 28, 2020, 10:20:40 PM

  • 3D Maker
  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 287
  • Gracias recibida: 12017
  • vn

Offline cri0 #4 Posteado: April 28, 2020, 11:01:48 PM

  • 0 puntos por ventas
  • *
  • Rank: Dedicado
  • Posts: 39
  • Gracias recibida: 597
  • br

Gracias:


Offline smiley #5 Posteado: April 29, 2020, 12:13:18 AM

  • C++ Coder
  • 0 puntos por ventas
  • *
  • Rank: Principiante
  • Posts: 23
  • Gracias recibida: 472
  • br
It is for 1.04E main, i do not have sure if it will work in other verions.


Offline axeman192 #6 Posteado: April 29, 2020, 12:24:57 AM

  • 3D Maker
  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 287
  • Gracias recibida: 12017
  • vn
It is for 1.04E main, i do not have sure if it will work in other verions.
Uso 1.04e, entro en Main.exe cuando desactivo el código.
Code: [Select]
		// Bypass Window Mode Checks (Move to offset.h)
//gToolKit.SetNop(0x005A3E31,2); // Allow fix on NPC
//gToolKit.SetNop(0x0064C3BE,2); // Allow fix on Shop
¿Hay alguna solución para mí?


Offline TzCr4ck #7 Posteado: April 29, 2020, 01:04:36 AM

  • 0 puntos por ventas
  • *
  • Rank: Liga mayor
  • Posts: 185
  • Gracias recibida: 71
  • ve
Yo tengo el siguiente error:

Code: [Select]
WinApiHook.cpp(26): error C2065: 'gToolkit' : identificador no declarado

1>WinApiHook.cpp(26): error C2228: el operando izquierdo de '.SetNop' debe tener class/struct/union
1>          el tipo es ''unknown-type''


Offline artem #8 Posteado: April 29, 2020, 04:30:24 AM | Modificado: April 29, 2020, 04:55:55 AM by artem

  • 0 puntos por ventas
  • *
  • Rank: Sup. destacado
  • Posts: 108
  • Gracias recibida: 17
  • ua

Offline LTP Team #9 Posteado: April 29, 2020, 08:42:47 AM | Modificado: April 29, 2020, 08:45:34 AM by LTP Team

  • C++ Coder
  • 0 puntos por ventas
  • *
  • *
  • Rank: Puto amo
  • Posts: 200
  • Gracias recibida: 3159
  • ru
Problem not in main.exe. You need add some checks in GameServer.exe

Add
Code: [Select]
if (PacketCheckTime(&gObj[aIndex]) == 0)
{
DataSend(aIndex,(BYTE*)&pMsg,pMsg.header.size);
return;
}

in void CItemManager::CGItemBuyRecv(PMSG_ITEM_BUY_RECV* lpMsg,int aIndex)

How it work you can check in zTeam sources or IGCN.


Offline c4nhsatcodong #10 Posteado: April 29, 2020, 08:48:12 AM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 360
  • Gracias recibida: 1878
  • vn
Gracias, funciona para mí 1.04D como 1.04E


Publicar un anuncio Mu Online gratis - Mu Online Community GRATIS.
Post free Mu Online ads - FREE Mu Online Community
https://www.facebook.com/groups/274190243227367/


Offline smiley #11 Posteado: April 29, 2020, 10:29:37 AM

  • C++ Coder
  • 0 puntos por ventas
  • *
  • Rank: Principiante
  • Posts: 23
  • Gracias recibida: 472
  • br
Problem not in main.exe. You need add some checks in GameServer.exe

Add
Code: [Select]
if (PacketCheckTime(&gObj[aIndex]) == 0)
{
DataSend(aIndex,(BYTE*)&pMsg,pMsg.header.size);
return;
}

in void CItemManager::CGItemBuyRecv(PMSG_ITEM_BUY_RECV* lpMsg,int aIndex)

How it work you can check in zTeam sources or IGCN.

Problem is in main, since this is fixed when use at full screen. Soo why webzen put this on full screen? and not in normal window?
Also why you fix in gs since you can avoid send anormal packet to gs??

Yes packet time fix it, but is not only a way to do that fix correctly.


Offline AZURE #12 Posteado: April 29, 2020, 11:40:30 AM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 267
  • Gracias recibida: 3049
  • cl
hola amigo que hace precisamente esa source?


Offline smiley #13 Posteado: April 29, 2020, 12:25:14 PM

  • C++ Coder
  • 0 puntos por ventas
  • *
  • Rank: Principiante
  • Posts: 23
  • Gracias recibida: 472
  • br
hola amigo que hace precisamente esa source?

Check the vídeo is exaclty to fix cursor when open shop to avoid miss click .


Offline TzCr4ck #14 Posteado: April 29, 2020, 02:54:29 PM

  • 0 puntos por ventas
  • *
  • Rank: Liga mayor
  • Posts: 185
  • Gracias recibida: 71
  • ve
Yo tengo el siguiente error:

Code: [Select]
WinApiHook.cpp(26): error C2065: 'gToolkit' : identificador no declarado

1>WinApiHook.cpp(26): error C2228: el operando izquierdo de '.SetNop' debe tener class/struct/union
1>          el tipo es ''unknown-type''
@smiley me ayudas con esto por favor? Tengo el código agregado correctamente.


Offline stark98 #15 Posteado: April 30, 2020, 01:14:09 PM

  • 0 puntos por ventas
  • *
  • Rank: Avanzado
  • Posts: 124
  • Gracias recibida: 1770
  • fr
Yo tengo el siguiente error:

Code: [Select]
WinApiHook.cpp(26): error C2065: 'gToolkit' : identificador no declarado

1>WinApiHook.cpp(26): error C2228: el operando izquierdo de '.SetNop' debe tener class/struct/union
1>          el tipo es ''unknown-type''

+++++
@smiley me ayudas con esto por favor? Tengo el código agregado correctamente.

Be cool, and all will be ok))
Skype: sky.hack2
Discord: bonny9

Offline Llalex #16 Posteado: April 30, 2020, 04:52:40 PM | Modificado: May 01, 2020, 11:04:30 AM by Llalex

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 337
  • Gracias recibida: 397
  • ve
Aca le dejo una guia de como agregar esta source completamente y aparte le colocoque este nombre "FixWindowMode", espero que @smiley no se moleste.

crear FixWindowMode.h
Code: [Select]
#pragma once

#define g_bUseWindowMode *(DWORD*)0xE60974

class cWinApiHook
{
public:
void Load();

static BOOL WINAPI Mine_SetCursorPos(int X,int Y);
};

extern cWinApiHook gWinApiHook;

Crear FixWindowMode.cpp
Code: [Select]
#include "stdafx.h"
#include "FixWindowMode.h"
#include "Util.h"

cWinApiHook gWinApiHook;

BOOL (WINAPI *Real_SetCursorPos)(int X,int Y) = SetCursorPos;

BOOL WINAPI cWinApiHook::Mine_SetCursorPos(int X,int Y)
{
RECT Rect;
if(GetWindowRect(GetActiveWindow(),&Rect))
{
X += Rect.left;
Y += Rect.top;
}

return Real_SetCursorPos(X,Y);
}

void cWinApiHook::Load()
{
if(g_bUseWindowMode)
{
// Bypass Window Mode Checks (Move to offset.h)
MemorySet(0x005A3E31,0x90,2); // Allow fix on NPC
MemorySet(0x0064C3BE,0x90,2); // Allow fix on Shop

DetourTransactionBegin();
DetourUpdateThread(GetCurrentThread());
DetourAttach(&(PVOID&)Real_SetCursorPos,gWinApiHook.Mine_SetCursorPos);
DetourTransactionCommit();
}
}

En Main.cpp agregar al inicio #include "FixWindowMode.h"
Buscar "gInterface.Load();" y agregar esto antes

Code: [Select]
gWinApiHook.Load(); //FixWondowsMode
Actualizacion 01/05/2020 Ahora si esta trabajando al 100%

Gracias:


Offline stark98 #17 Posteado: April 30, 2020, 06:31:07 PM

  • 0 puntos por ventas
  • *
  • Rank: Avanzado
  • Posts: 124
  • Gracias recibida: 1770
  • fr
gToolKit.SetNop(0x005A3E31,2); // Allow fix on NPC
      gToolKit.SetNop(0x0064C3BE,2); // Allow fix on Shop

If i delete this game is started if not delete game not start((((((

Be cool, and all will be ok))
Skype: sky.hack2
Discord: bonny9

Offline smiley #18 Posteado: April 30, 2020, 07:17:38 PM

  • C++ Coder
  • 0 puntos por ventas
  • *
  • Rank: Principiante
  • Posts: 23
  • Gracias recibida: 472
  • br
This fix is for 1.04E main other versions will crash.


Offline Llalex #19 Posteado: April 30, 2020, 07:30:03 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 337
  • Gracias recibida: 397
  • ve
This fix is for 1.04E main other versions will crash.
My Main is 1.04E and it also crashes me.


Solo usuarios registrados pueden comentar y agradecer, Logueate o Registrate


 

Related Topics

  Subject / Started by Replies Last post
6 Replies
7782 Views
Last post April 03, 2019, 03:43:47 PM
by Alexsupra0
0 Replies
661 Views
Last post January 31, 2019, 10:18:08 AM
by LeeHenry
0 Replies
1513 Views
Last post October 19, 2020, 02:50:12 PM
by emersonx13
1 Replies
1631 Views
Last post December 23, 2020, 07:05:34 AM
by Smith200
6 Replies
6578 Views
Last post August 10, 2023, 10:46:51 PM
by Rindy