CLEO Help SAMPFUNCS' 0B21/0B4C offset

CLEO related
Status
Not open for further replies.

mpol77

Active member
Joined
Oct 24, 2018
Messages
66
Reaction score
6
title says pretty much everything

0B21: samp is_chat_opened
0B4C: samp is_dialog_active 0@

overall it's just to add these conditions:
if and
not samp.ChatInputOpened()
not samp.IsDialogActive(-1)

thx by advance
 

mpol77

Active member
Joined
Oct 24, 2018
Messages
66
Reaction score
6
http://ugbase.eu/index.php?threads/snippet-is-chat-dialog-open.8121/

:isChatOpen
0AA2: 1@ = "samp.dll"
1@ += 0x2ACA24
0A8D: 1@ = readMem 1@ sz 4 vp 0
1@ += 8
0A8D: 1@ = readMem 1@ sz 4 vp 0
1@ += 4
0A8D: 1@ = readMem 1@ sz 1 vp 0
if
1@ <> 0
then
30@ = 1
else
30@ = 0
end
0AB2: ret 1 30@

i tried to edit this a bit with the right offsets, but it isn't working
it always return 1 for some reason
 

Parazitas

God
Joined
Jan 2, 2017
Messages
3,112
Solutions
5
Reaction score
878
Location
Lithuania

Parazitas

God
Joined
Jan 2, 2017
Messages
3,112
Solutions
5
Reaction score
878
Location
Lithuania
PHP:
{$CLEO .cs}

0000:

wait 8500

while true
wait 0

if
0AB1:  @isChatOpen 0
then
    // do something..
end

end

:isChatOpen
0AA2: 1@ = "samp.dll"
1@ += 0x2ACA14
0A8D: 1@ = readMem 1@ sz 4 vp 0
1@ += 0x14E0
0A8D: 1@ = readMem 1@ sz 4 vp 0
if 1@ <> 0
then
    0485: chat_open
else
    059A: chat_closed
end
0AB2: ret 0
 
Status
Not open for further replies.
Top