|
|
转载
( p" \( g% }% u& J+ h. g; u( L3 `7 NBY SJ3 q, \; m6 }1 W; P! b
首先你要会搞D2MuitlRes113C.dll与D2MultiResExt.dll(后者我是跟狂三要的)
- N! G# V0 t$ F. {+ ~. E) f$ A/ W1 `* s; I" c1 s7 K+ _
D2Gfx::D2DrawImage-10041
8 S- B" Z3 f( f0 R* l1、修复技能的背景(不需要可以不要)# V# |+ m" S! C$ a2 e
offset = D2Client::GetAddress(0x77AA8);7 F( g" e+ W" D* r& S* v; H
Memory::SetCursor(offset);
' Y% _: D% s% l0 P" |Memory::ChangeCallB((DWORD)D2Gfx::D2DrawImage, (DWORD)caller_SpellBackGroundFix);( t2 [0 r$ a6 _% I5 e$ f
: Z$ c" K: G6 z+ j7 B7 }7 ^ fvoid __stdcall m_NewStatShow_SpellBackGroundFix(sDrawImageInfo* pData, DWORD* nXpos, DWORD* nYpos, DWORD nGamma, DWORD nDrawType, BYTE pPalette[256][256])
3 x& [* W7 B) {{7 b& r3 i/ s& A% t
//Init data for print image2 S8 v# _6 {6 M- q3 A, Q
sDrawImageInfo data;0 d% O/ H1 r8 u4 F* v! u7 H
ZeroMemory(&data, sizeof(data));, G! u9 y; d' d6 W
! E& Q5 v ?) u+ l6 L //print background
0 U: L5 `+ p \" U9 u a setImage(&data, spellBackgroundImages);+ T5 Z3 D2 x% C* s% {0 f# l
setFrame(&data, 0);
1 S! q2 ~4 l' @" w& s; \+ b- k5 j int fixx = 511;
- F, ]9 T8 @$ }1 J% O; T3 k' T int fixy = 9;7 w2 w \: ~# T1 f5 m% f# J4 B
D2Gfx::D2DrawImage(&data, RX(0+ fixx), RY(256 + fixy), -1, 5, 0);
8 V/ {8 f, T! b8 l: c* |, a setFrame(&data, 1);6 k& M. h+ J$ y5 L: t+ e
D2Gfx::D2DrawImage(&data, RX(256 + fixx), RY(256 + fixy), -1, 5, 0);//2564 V* a) P0 V* ?% s
setFrame(&data, 2);' [* g5 ^: H6 ^- F( X
D2Gfx::D2DrawImage(&data, RX(0 + fixx), RY(0 + fixy), -1, 5, 0);//432- |) X' a+ G0 K+ K$ a
setFrame(&data, 3);
4 z& v. k9 L7 O0 `2 V) o! o) m D2Gfx::D2DrawImage(&data, RX(256 + fixx), RY(0 + fixy), -1, 5, 0);; |4 r0 s1 e( q. A1 X
}
- ?# ^- t- V, s& i__declspec(naked) void caller_SpellBackGroundFix()8 M6 m' Y9 |) c- ]8 K
{# e! a; A+ h3 m( V; b
__asm7 B* u: s; E( Z6 A6 y
{
- Q- S/ s# L3 a% c M: P+ s PUSHAD
2 c# g( E+ [" K lea eax, dword ptr ss : [esp + 0x38]' Y* h: V+ g% X7 M
push eax" {( ]% X" o+ S* K
push dword ptr ss : [esp + 0x38]' r9 d1 O" x+ {4 m" x/ ~$ i
push dword ptr ss : [esp + 0x38]; `3 p8 p" o8 C' \' E+ f3 I; z+ J
lea eax, dword ptr ss : [esp + 0x38]
0 f! u1 d/ |; Q# S4 f push eax
3 e' g4 z5 J& k6 d I lea eax, dword ptr ss : [esp + 0x38]
9 i! H1 o4 Y' r' t, z2 W push eax' z$ b3 f3 ^7 x; I% W W
push dword ptr ss : [esp + 0x38]) U6 W! g A. }$ L1 R( _ F$ l
call m_NewStatShow_SpellBackGroundFix0 {8 b9 a) Y8 }! C
POPAD
3 K# H5 | h0 S; p7 P1 k' r JMP D2Gfx::D2DrawImage+ b Q2 r; b3 O1 t$ E
}2 }2 \# r8 ]$ v/ |6 b5 @- i0 D
}& L7 z( k. o8 Y! l3 H. k
4 x' e4 S: q" }( O
2、我们如法炮制小站的背景
1 s0 g) w2 O6 Z6 @4 C- e
6 m( }, m3 [# k1 n% n! Q$ v& Loffset = D2Client::GetAddress(0xAB010);
9 z' a7 R6 ~' v) J6 M8 d2 ]) hMemory::SetCursor(offset);' G( D0 x9 e1 {4 d
Memory::ChangeCallB((DWORD)D2Gfx::D2DrawImage, (DWORD)caller_WayPointBackGroundFix);
, C* q4 [- j1 F% M, _9 Q
& c- Q+ c4 a& ]4 n- xvoid __stdcall m_NewStatShow_WayPointBackGroundFix(sDrawImageInfo* pData, DWORD* nXpos, DWORD* nYpos, DWORD nGamma, DWORD nDrawType, BYTE pPalette[256][256])
- E1 Q. N1 Y% m: v% i( [5 Q' v7 ~{
; _- N7 h6 W& C; n //Init data for print image
- p+ c- @& Z8 B$ \, L5 H" R6 H sDrawImageInfo data;
/ v3 [& x/ X: b ZeroMemory(&data, sizeof(data));3 r. \6 V' Q% Z: B
6 F2 E4 i+ e$ o' D; f9 M
//print background
M9 @& |$ V3 M4 } setImage(&data, waypointBackgroundImages);1 `" S- S# H$ j C& \
setFrame(&data, 0);' F; c- [' J0 B
int fixx = 0;
3 C) C0 @7 B; F, E int fixy = 9;- d( i# r4 E- S. [- m+ L f# E- O. l
D2Gfx::D2DrawImage(&data, RX(0 + fixx), RY(256 + fixy), -1, 5, 0); Q! x3 Y9 j! p1 X; i3 r
setFrame(&data, 1);4 q- S i" Y4 d& A `
D2Gfx::D2DrawImage(&data, RX(256 + fixx), RY(256 + fixy), -1, 5, 0);//256
5 R3 ]( B$ |" L- M+ ~; N setFrame(&data, 2);
3 s. N Y1 v) e3 ?8 o% T7 U D2Gfx::D2DrawImage(&data, RX(0 + fixx), RY(0 + fixy), -1, 5, 0);//432
t1 ?0 B8 I0 Z9 K, w( Z setFrame(&data, 3);
4 C) e& h' ?4 p7 v& v8 v W9 }% N D2Gfx::D2DrawImage(&data, RX(256 + fixx), RY(0 + fixy), -1, 5, 0);) _9 i! W& q& r6 G3 V) q
1 h7 c3 [1 ]+ N4 k
}
8 Q/ Z" n7 K. K4 o( r__declspec(naked) void caller_WayPointBackGroundFix()* v, s4 ]( F. Z. m2 B2 M3 \" m3 e
{2 z. `& n2 n4 g3 S/ b" }( @, J3 c
__asm
2 c3 F) Z2 {- C+ d, I {
7 X V& R6 Y4 T6 F( s% P PUSHAD; P, b9 b' {0 G% p" Y- ~4 D( V
lea eax, dword ptr ss : [esp + 0x38]
; ]4 C- C& W* Z% F; `7 K push eax& n5 j4 \8 o+ K* K
push dword ptr ss : [esp + 0x38]
" u) F! O' @) w0 l* R5 n% ? push dword ptr ss : [esp + 0x38]/ Z7 J% G8 G: D9 L3 l
lea eax, dword ptr ss : [esp + 0x38]6 m9 V9 t& S* a) x" I+ J
push eax
# W, R# [ |) Z5 @) K" c lea eax, dword ptr ss : [esp + 0x38]
' m9 x: f6 O/ D9 t8 F0 l3 J push eax
/ r- g: Z2 G& Z9 ` push dword ptr ss : [esp + 0x38]7 B# M. S0 y" A: n% q
call m_NewStatShow_WayPointBackGroundFix2 E) N% U' I/ _$ h5 c
POPAD
$ U& m7 ^' \* K( | JMP D2Gfx::D2DrawImage
) d7 v# }1 u, W0 k+ C }( S, ^) B% p- r8 q
}6 W2 Y8 k/ F7 S, F, i8 E" L: F" q* t
+ x3 [" d- ^, q' N/ L: W
3、以下可以搞16*16超级箱子-腾出我们需要的边缘
+ ?, z7 Z% n' ]1 h0 f, o/ e腾出我们需要的边缘(事实上可能会出现一些黑边,但是我没有修复)
, b6 P6 s8 x4 V% H {
7 d9 P, d: N: M) j1 v% v class D2MultiRes : public Library<D2MultiRes>- e' g' O$ U% h6 v
{; M) [/ @2 l, w+ q
public:7 e( Y3 `7 i9 s6 ~3 z: c
static void Init()( \. B! X+ Z& L# x) q
{; x% M" X; j8 _
Name = "D2MultiRes.dll";
' t! F3 r" F2 ^* x; F9 q4 F Offset = LoadDiabloLibrary();; l+ q5 b- v/ h. g
}
( s1 e0 u7 m- f' N- `4 b" S };4 K; O; \" j& y- m
D2MultiRes::Init();
7 G+ @% r& t+ b" j! z w/ z5 K4 m D2MultiRes::HookLibrary();
9 A# _. Z/ i* E6 M- `0 I* e1 I
& g: c& A+ d9 e# A- P& |4 p+ P0 ~" c9 Z$ z* t- U9 ^# v$ m
MiscFunctionsOffset = D2MultiRes::GetAddress(0x2468);# R5 n3 C8 w1 ~' Z8 z
Memory::SetCursor(MiscFunctionsOffset);
' ]6 O t/ V0 r F9 R# K; V& d Memory::ChangeDword(0x1b0, 0x200);$ X% @& A# a( C) f
) a7 l8 Y- Y9 P- u! `$ t. ]. U. O: L$ j; i; i& t
MiscFunctionsOffset = D2MultiRes::GetAddress(0x2b0a);
8 U0 c: X! f& u% q$ D9 t Memory::SetCursor(MiscFunctionsOffset);
; H4 {+ x/ `/ f$ i) ?8 [3 \ Memory::ChangeDword(0x140, 0x200);9 G% U0 G2 r5 e9 |
/ ^5 y$ O3 Q, ^% `2 e/ a q Z2 Y
8 F6 E4 @ c3 K$ R% R$ k MiscFunctionsOffset = D2MultiRes::GetAddress(0x2b10);
@8 }/ o% H$ u- t v, A" R Memory::SetCursor(MiscFunctionsOffset);
|# q4 i h7 D* }1 e) t Memory::ChangeDword(-0x234, -0x299);//280-295 290是上面多一块 310是下面多一块0 f& o& u2 ~3 ?
- y4 q. g$ ^- W5 d& H! a1 D MiscFunctionsOffset = D2MultiRes::GetAddress(0x2bfe);% Z% T; H7 u) t4 ]; d$ v. ~* Q
Memory::SetCursor(MiscFunctionsOffset);
" Z1 r7 }6 p; M; ~5 ~: P# s. \ Memory::ChangeDword(0x200,0x299);//下边缘 299最大# x" w9 A( `! E$ R" Z) Y; [
' W& X' Q- f9 O* z: X MiscFunctionsOffset = D2MultiRes::GetAddress(0x3301);8 J5 A [ y6 A% @& W3 \* }' `% u) u
Memory::SetCursor(MiscFunctionsOffset);% P" W. n$ B% L) P# g3 v; O2 ]
Memory::ChangeDword(-0x280, -0x400);//这个不要动1 Q. v: a( \- f" E% @
}
1 M$ u9 C; V7 p6 N2 u! u; e2 y, o6 N; ?$ h/ K. H% m" O8 A
4、快完成了,是不是发现金币啥的位置不对?? W2 }5 F* V* N1 G* S' U
# i) a" q2 q- j7 d: w# O
//这里修正我们的装备栏2 k0 A9 M) y0 ^' X' R/ D W$ P
offset = D2Client::GetAddress(0x99B6C);
; w1 K7 ?3 N3 f( t% N Memory::SetCursor(offset);
" S* s z+ O8 k6 o5 `4 G) d+ v" `6 _ Memory::ChangeCallB((DWORD)D2Gfx::D2DrawImage, (DWORD)caller_Char6Fix);) X. {- j- g4 T; L7 O) y8 ]% G% N
" [/ U0 D6 O) B2 w! O: z n2 P( T
offset = D2Client::GetAddress(0x99BA7);4 U4 A( k9 A3 W; ~) [% ?
Memory::SetCursor(offset);" X& c! s3 @( Y( I) b: `$ }
Memory::ChangeCallB((DWORD)D2Gfx::D2DrawImage, (DWORD)caller_Char6Fix);
4 Q* n+ \0 g- D* @' F! F8 C% i5 Q7 E
offset = D2Client::GetAddress(0x99BE2);
+ h. |- t( `/ S3 Y4 h! m Memory::SetCursor(offset);
/ q; g; p4 V" p Memory::ChangeCallB((DWORD)D2Gfx::D2DrawImage, (DWORD)caller_Char6Fix);& W. e* f, B. Y, K ?3 R1 H
% V# T, Z; u" ]- l' z1 f+ C
offset = D2Client::GetAddress(0x99C1C);( c+ b/ O- L3 s7 ^
Memory::SetCursor(offset);+ g" e$ i' @9 T$ a) x9 G8 W
Memory::ChangeCallB((DWORD)D2Gfx::D2DrawImage, (DWORD)caller_Char6Fix);
9 \3 l" T: D3 Z5 n+ W
- S1 L& T: P) c //取消两个popup,偷偷懒不过分
0 z9 [3 I# }: R& a" X offset = D2Client::GetAddress(0x9386d); v; M! z! b% ]1 M
Memory::SetCursor(offset);% e% I* H7 J4 N
Memory::ChangeByte(0x8b, 0x33);
/ ~: S$ v$ l8 Z* R& ?: K- o( F Memory::ChangeByte(0xc8, 0xC9);
5 h7 t2 Y( M& p* O3 ~, Y& r6 t offset = D2Client::GetAddress(0x9390b);
# n4 _- O g' D- R/ c/ P Memory::SetCursor(offset);$ z0 Y) e& d" l, c# m) D# i
Memory::ChangeByte(0x8b, 0x33);
" O' s* k) e3 X, y! K* ?! K9 `, u& L Memory::ChangeByte(0xc8, 0xC9);
+ Y# ^/ [9 N% o# g
! v$ R9 p% V6 p/ h w) D P3 O //修正提取金币
1 j8 t' V9 M( D: E3 j offset = D2Client::GetAddress(0x8D3E5);7 v7 D4 M/ f$ d/ F% X1 X
Memory::SetCursor(offset);
$ ~, s" B+ t" e3 c! \, G* H0 Q Memory::ChangeByte(0xA1, 0xE9);1 n7 W6 `; x% a( p/ ^" w) Y
Memory::ChangeCallA((DWORD)D2Client::ptNegWindowStartY, (DWORD)caller_goldcoin);2 v) A3 }; K9 B3 q+ F2 ~
6 f( I) H( }! e2 L: q
offset = D2Client::GetAddress(0x6FB3D2E0-0x6FAB0000);4 b$ ^9 n2 w) ~
Memory::SetCursor(offset);4 P; o! l% L$ T$ U4 ~, B
Memory::ChangeCallB((DWORD)D2Gfx::D2DrawImage, (DWORD)caller_goldcoinimg);
- p& S+ _0 i5 z) v5 U! ?! b. h2 `
offset = D2Client::GetAddress(0x6FB3D267 - 0x6FAB0000);. Y% n4 E% v% F' G. w0 Y
Memory::SetCursor(offset);) {( [ S! K S$ O. n( m0 h$ s3 Z
Memory::ChangeCallB((DWORD)D2Win::D2PrintString, (DWORD)caller_goldcointext);' y2 H; S y/ i* m' B; o9 V( r
( [: o Y |7 Z3 o+ |5 @9 V //修正关闭按钮
, o9 b2 E. ~1 @0 ?& D5 s. d offset = D2Client::GetAddress(0x8BD90);5 s8 m& H1 E4 S \ M
Memory::SetCursor(offset); Q; g/ ?1 g4 n+ p# l4 [
Memory::ChangeByte(0xA1, 0xE9);
0 c- `& F# L6 S8 S6 t2 P Memory::ChangeCallA((DWORD)D2Client::ptScreenSize, (DWORD)caller_close);3 k2 ^/ r- j- [/ S K8 h
- x1 [9 q# R2 _: i: z7 Y- l
offset = D2Client::GetAddress(0x6FB4A721 - 0x6FAB0000);0 w" `) g' E* r
Memory::SetCursor(offset);
) Y2 T* r# l+ f6 B8 t/ G Memory::ChangeCallB((DWORD)D2Gfx::D2DrawImage, (DWORD)caller_closeimg);0 ~+ `" z$ q+ Q% N; b- T) o7 Z; L
7 [$ s7 s2 a5 S3 I
) n6 ~2 W1 R9 A2 l( w( p: }9 U+ y. \//以下是细节
! i7 q, a8 v. n& t* n6 P#define getXGoldCoinFixBtn() RX(0x2d0)
# b; G/ m! y$ Q#define getLGoldCoinFixBtn() 32
3 B3 }6 a2 S0 b; F J8 m#define getYGoldCoinFixBtn() RY(-0x59)+ X4 g3 Z2 f/ l: [) a1 O7 v2 e
#define getHGoldCoinFixBtn() 324 O5 t0 y7 p4 [4 F9 q& G
#define isOnGoldCoinFixBtn(x,y) isOnRect(x, y, getXGoldCoinFixBtn(), getYGoldCoinFixBtn(), getLGoldCoinFixBtn(), getHGoldCoinFixBtn())
, n- l5 \& ~9 r0 Y
) K3 ~! J' L) x- B#define getXInvCloseFixBtn() RX(0x3db)2 M( d8 h/ k& _3 U8 i) Y" e9 P, y2 {
#define getLInvCloseFixBtn() 32; A8 s3 ^3 E4 B8 @- u
#define getYInvCloseFixBtn() RY(-0x63)
5 m4 ?* ]( G7 h6 G$ a- ^& ?7 W#define getHInvCloseFixBtn() 32) q! S+ B, M; H3 I
#define isOnInvCloseFixBtn(x,y) isOnRect(x, y, getXInvCloseFixBtn(), getYInvCloseFixBtn(), getLInvCloseFixBtn(), getHInvCloseFixBtn())
+ `5 s. I1 L8 W1 L
9 m# q# }3 c8 \1 VBOOL __fastcall m_NewStatShow_goldcoin(DWORD x,DWORD y)7 `/ Y& U$ z- R' X9 h
{0 G8 W# |) x6 @" C" f& y! X
DWORD mx = *D2Client::ptMouseX;
7 k; e* b8 Y' w8 r DWORD my = *D2Client::ptMouseY;4 X1 r" m4 y" Z2 o9 k$ g* ?/ i
if(isOnGoldCoinFixBtn(mx, my))5 F6 Z& D4 W% t$ i$ W# c2 B2 W
return TRUE;
6 S9 r0 x7 @9 G% E3 J/ Z! _$ q5 o return FALSE;
$ Z# C4 {+ o( P5 z: k$ |}: Z& L1 f5 Q! o0 j: ]
__declspec(naked) void caller_goldcoin()
* s: V" m1 ^% x) o3 n; e/ k{6 k" |( C; v, d
__asm2 y' L/ D0 V3 n1 B- m/ r5 L/ I
{; X' B7 e4 y9 [0 _
push ebx5 s) H# j' K9 M1 [9 t) n
mov ecx, esi
6 r) m8 w7 f5 y) A& v mov edx, edi" g- l, g5 D* n; G9 D
call m_NewStatShow_goldcoin8 y& V! }" _& S5 y; t) |; T& }% b
pop ebx
2 p3 h/ F' y; @6 u' ~- A5 \0 O% y pop esi+ Z& v$ r* W- \! s0 f3 x
retn
9 Z/ ]7 i0 B. O7 G }: Q5 m# e3 a/ x9 V0 `9 A* B
}
' R# n @4 C) I! ivoid __stdcall m_NewStatShow_goldcoinimg(sDrawImageInfo* pData, DWORD* nXpos, DWORD* nYpos, DWORD nGamma, DWORD nDrawType, BYTE pPalette[256][256])
0 ]- p( Z! v- ~0 @{4 |. G6 z) x8 t7 R3 Y
if (*nXpos > D2Client::ptScreenSize->x / 2). E/ Z( u/ w4 l4 w" T; T
{
$ Q! v# u* C, z3 e7 L *nXpos = getXGoldCoinFixBtn();" m, Q1 p/ t0 K- k+ k% M
*nYpos = getYGoldCoinFixBtn();( a5 C1 S4 c) W
}
8 Z) r# u5 w' {7 N1 f( N& n}
8 [) ^& u, s4 w& d: I# x) c__declspec(naked) void caller_goldcoinimg()
7 F) t u8 A+ `& V+ |- X0 b4 r{8 f* t2 X+ i5 e
__asm1 Y2 M0 C. ?& I/ c4 j
{
' W$ V0 G! `$ s, Y1 g# I7 C PUSHAD3 X a/ {+ I |% G1 m( c
lea eax, dword ptr ss : [esp + 0x38]% U- `' e s p5 Z: `% |8 h+ w
push eax. | _; E' L9 S9 k) F
push dword ptr ss : [esp + 0x38] U. a4 q1 O! j9 l/ B, Q
push dword ptr ss : [esp + 0x38]
" q* L/ Q R9 B' R4 g ~" v. e lea eax, dword ptr ss : [esp + 0x38], u3 L( l ?) X2 g0 f- F
push eax! f. L# D! c( M+ l! S. V5 k
lea eax, dword ptr ss : [esp + 0x38]
5 D2 Z# e; _8 n5 |" ?) h2 \ push eax
, T- Z7 P5 L" D push dword ptr ss : [esp + 0x38]
6 a( `/ p: A% g2 ~ call m_NewStatShow_goldcoinimg3 v& p# h: k1 t! B0 l8 j) {
POPAD; Z. N7 I! y" B
JMP D2Gfx::D2DrawImage
* p3 o8 y/ f s7 H( k8 E }
: F1 ?2 n5 L# f z, `/ y* {, C}
0 n9 u( F: C0 C) v* BDWORD __fastcall m_NewStatShow_goldcointext(DWORD x,DWORD* y)//返回x坐标3 ~+ `3 a: I8 E4 _4 W
{1 ^ L6 M' G, k2 X! R
if (x > D2Client::ptScreenSize->x / 2)0 c/ x# P F! g& W* F9 t6 B9 A
{4 u6 ?& E4 D- ?% ^0 g/ I' Z2 \
*y = getYGoldCoinFixBtn();
0 Q- K: X% Z' v$ Z1 a return getXGoldCoinFixBtn() + 32;; C' x! G3 Z( x+ b7 O& {* l
}0 _* D& n5 [6 Q9 m) X \+ ?! \
return x;( I' ?) h9 q2 ~0 v8 H0 I
}1 S! j8 T( {1 @
__declspec(naked) void caller_goldcointext()
5 {$ I4 J+ F P' n$ G{
! `( p: w6 G- r+ y- Y5 R __asm
/ I+ |, H1 {6 C7 L6 A9 G {
* o' H3 R; N" N) Q2 p PUSH ECX
; J- ^+ _ H7 t+ F+ B! P PUSH EDI+ b+ D+ Z- ?1 V: c! I$ |6 O
PUSH ESI) k9 l j3 \/ T, c) |) g8 H
PUSH EAX
+ N* `+ _+ H: j0 m! b MOV ECX, EDX% S! x; m5 w+ Q% a6 r" B& Z
LEA EDX,[ESP+0X4+0X10]
! f; G% Z1 Y. q2 L) G CALL m_NewStatShow_goldcointext
2 I c8 z2 R$ w5 \3 ` MOV EDX,EAX+ h/ m) U p1 \6 Q) P; O: c
POP EAX" S& V0 c V8 }$ A1 d9 Z
POP ESI
; d4 }* _) h8 N2 q' Y) p- i% e; o POP EDI
" Y+ H/ B9 Q: i3 u POP ECX
4 Y5 T6 n; n4 z6 s8 }/ C jmp D2Win::D2PrintString;
% S$ D( L- [ ]8 ?( y8 Z5 O% o8 J5 q9 A }( x8 F+ V5 `0 \. R" m
}, l9 H- I6 [" V9 }/ f7 s7 K b3 a; o
4 M9 w' e# N: S9 V+ o
BOOL __fastcall m_NewStatShow_close(DWORD x, DWORD y)$ ?2 U0 {9 g4 T% Q6 y: [+ ~0 R
{) E1 T4 e8 I9 @0 b. m
DWORD mx = *D2Client::ptMouseX;7 h1 ]+ k1 V: O; @ o: T( p
DWORD my = *D2Client::ptMouseY;& z1 M/ y' ?" O% L/ I: Q$ U W6 |
if (isOnInvCloseFixBtn(mx, my)), |+ `2 @, V3 W8 j/ {6 r- a
return TRUE;1 q; v b4 Q) D s$ y2 Q' ?
return FALSE;6 G( b [, a7 ?6 ]
}7 i4 [, T C& I p3 L0 }5 Q1 [6 T j
__declspec(naked) void caller_close()
( a8 G _7 j7 N* O{# ~7 C! g7 z# y# a
__asm8 O+ C: b- J+ p% |' B
{
( A5 Q( Y9 P( ]# c! a1 V' N PUSH ESI& }4 q+ ]0 e( x$ _$ B
push ebx
) V) ~, \( w2 G& e call m_NewStatShow_close( }1 u7 `6 |- S& `+ F
pop ebx
( t& |5 |! b1 L' R1 d pop esi* O* h" q* }$ P' _5 n7 N
retn8 t+ F; k% g7 H% j& v
}
' x: H/ U. ?7 h9 R% I# i}+ N* _8 Y. { y7 ?" H. L
void __stdcall m_NewStatShow_closeimg(sDrawImageInfo* pData, DWORD* nXpos, DWORD* nYpos, DWORD nGamma, DWORD nDrawType, BYTE pPalette[256][256])
0 s# F" @9 ]1 G# u: A+ z& s{0 q4 I }6 Q8 V' t
*nXpos = getXInvCloseFixBtn();0 N4 Y$ @8 D0 N2 X
*nYpos = getYInvCloseFixBtn();( {& ?1 H- y, D' V6 y P, S Q
}
8 h9 X; s: g% P__declspec(naked) void caller_closeimg()
! v3 P0 P7 t2 s. W% Z- U& N{
: A0 s$ ?& ]$ }+ N. l3 z; y6 b* u __asm& @$ s# D! s/ H X
{- D* ]3 A4 ~* Q; K! K3 J
PUSHAD7 O; R" t9 V p j$ o% K6 U2 N
lea eax, dword ptr ss : [esp + 0x38] s# G5 Q" G9 `' H2 j4 ?+ Y
push eax$ Q Y5 W' C* U
push dword ptr ss : [esp + 0x38]
9 }, [) |: P$ ]0 I* l6 f: g' @ push dword ptr ss : [esp + 0x38]
# r( h$ L( c+ i. s6 @9 J lea eax, dword ptr ss : [esp + 0x38]
$ _9 a! Z2 R! ]; h push eax
, c( h! C5 P' R% M' g7 s3 {' x6 P( B+ P lea eax, dword ptr ss : [esp + 0x38]0 {3 N! Z V- f( J2 U3 G) h' F
push eax
! C6 F) A: k$ M3 K push dword ptr ss : [esp + 0x38], h+ d6 z$ H) w1 L
call m_NewStatShow_closeimg
+ }( g3 N# P) D3 c POPAD/ O( l( m& n2 x, p& r
JMP D2Gfx::D2DrawImage4 M0 c- j) h4 t1 w2 P
}4 v q+ l" y+ i* j; x9 k4 b
}
# X; I+ f) {! g! Y/ O9 w9 C0 c' l) g8 S5 K$ P
8 m' h* z8 |* e2 r! v
|
|