CLEO Help Help me with On/Off

CLEO related
Status
Not open for further replies.

Monstercat

Well-known member
Joined
Feb 26, 2013
Messages
281
Reaction score
5
Hey how i can make a On/Off function on this script

Code:
wait 0
repeat
wait 0
until player.Defined(0)
0A96: 0@ = actor $PLAYER_ACTOR struct
0@ += 66
while true
wait 0
0A8C: write_memory 0@ size 1 value 0xCC virtual_protect 0
end
 

Zin

Expert
Joined
Aug 1, 2013
Messages
1,690
Reaction score
103
arent at the start of a cleo script you need

Code:
{$CLEO .cs}
THREAD 'IDK'
:Something
wait 0
if
key_pressed or 0ADC test_cheat 'Activation'

I think you know that

and at the bottom

Code:
if
key_pressed or test_cheat 'Activation
jump @Something

I dont know depends on what script it is sometimes its if and oh yeah im not 100% sure its 0ADC test_cheat just hit Alt gr 2 and search test_cheat
 
Joined
Feb 18, 2005
Messages
2,963
Reaction score
267
Code:
{$CLEO}
wait 0
repeat
wait 0
until player.Defined(0)

:1
wait 0
if 
0AB0: 49 // your key ON (1)
jf @1
0A96: 0@ = actor $PLAYER_ACTOR struct
0@ += 66
0A8D: 1@ = read_memory 0@ size 1 virtual_protect 0
0A8C: write_memory 0@ size 1 value 0xCC virtual_protect 0
jump @2

:2
wait 0 ms
if
0AB0: 50 // off key (2)
jf @2 
0A8C: write_memory 0@ size 1 value 1@ virtual_protect 0
jump @1

Try this :-? :-?:-?
 

Monstercat

Well-known member
Joined
Feb 26, 2013
Messages
281
Reaction score
5
Nope dont work :/
I do not get it

This one works perfect
Code:
{$CLEO}
wait 0
repeat
wait 0
until player.Defined(0)
0A96: 0@ = actor $PLAYER_ACTOR struct
0@ += 66
while true
wait 0
0A8C: write_memory 0@ size 1 value 0xCC virtual_protect 0
end

But if i try to make a On/Off func it stop working :fu: :fu::fu:
 

xzytro

God
Joined
Apr 1, 2013
Messages
2,294
Reaction score
7
Okay, compile this and try then :derp: :derp::derp:
Code:
// This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007

{$VERSION 3.1.0027}
{$CLEO .cs}

//-------------MAIN---------------
thread 'WHATS_MY_NAME' 

:MAIN_ACTIVATION
wait 0
if
0ADC:   test_cheat "ENABLE"
else_jump @MAIN_ACTIVATION
0ACD: show_text_highpriority "ACTIVATED" time 1500

:GO
wait 0
repeat
wait 0
until player.Defined(0)
0A96: 0@ = actor $PLAYER_ACTOR struct
0@ += 66
while true
wait 0
if
0ADC:   test_cheat "DISABLE"
else_jump @CONTINUE
0ACD: show_text_highpriority "DEACTIVATED" time 1500
0A8C: write_memory 0@ size 1 value 0 virtual_protect 0
jump @MAIN_ACTIVATION

:CONTINUE
0A8C: write_memory 0@ size 1 value 0xCC virtual_protect 0
end
I hope it will work :catface: :catface::catface:
 
Status
Not open for further replies.
Top