CLEO Help Put Activation

CLEO related
Status
Not open for further replies.

Badonga

Active member
Joined
Aug 5, 2013
Messages
71
Reaction score
0
Hello, can someone tell me how to put activation key F1 (key 112) for toggle on and off for this script:

Code:
// This file was decompiled using SASCM.INI published by GTAG (http://gtag.gtagaming.com/opcode-database) on 14.6.2013

{$VERSION 3.1.0000}
{$CLEO .cs}

//-------------MAIN---------------
0662: printstring "SPRINT" 

:Noname_11
wait 0 
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined 
jf @Noname_11

wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
goto @Noname_11 
end
 

blackHat

Expert
Joined
Jul 28, 2013
Messages
930
Reaction score
2
Code:
{$CLEO}

//-------------MAIN---------------
0662: printstring "SPRINT" 

:start
wait 0 
if
056D:   actor $PLAYER_ACTOR defined
jf @start
if 
044B:   actor $PLAYER_ACTOR on_foot 
Key_down 112
then 0B12: 0@ = 0@ XOR 1 
if  
0@ == 1  
then 
wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
end
end
Jump @start
 

MrChristmas

Expert
Joined
Jul 29, 2014
Messages
563
Reaction score
26
What does this script do anyway ?


Try this: (didn't test it)



Code:
{$CLEO .cs}

0662: printstring "SPRINT" 

:ON
wait 5 
if 
key_down 112 
else_jump @ON
print "~W~SPRINT ~G~ON" 1500
goto @ON_2 

:ON_2
wait 0 
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined 
goto @ON_3

:ON_3
wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
goto @ON_2

:OFF
wait 5
if
key_down 112
else_jump @OFF
print "~W~SPRINT ~G~OFF" 1500
goto @OFF_1

:OFF_1
wait 5
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined
goto @OFF_2 

:OFF_2
wait 400 
0A8C: write_memory 12006520 size 0 value 0 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 0 value 0 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 0 value 0 virtual_protect 0 
goto @ON
 

Badonga

Active member
Joined
Aug 5, 2013
Messages
71
Reaction score
0
BlackHat link said:
Code:
{$CLEO}

//-------------MAIN---------------
0662: printstring "SPRINT" 

:start
wait 0 
if
056D:   actor $PLAYER_ACTOR defined
jf @start
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined 
Key_down 112
then 0B12: 0@ = 0@ XOR 1 
if  
0@ == 1  
then 
wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
end
end
Jump @start

Non-stop opcode spam :X
 

TheZeRots

Expert
Joined
Dec 21, 2013
Messages
1,247
Reaction score
1
BlackHat link said:
Code:
{$CLEO}

//-------------MAIN---------------
0662: printstring "SPRINT" 

:start
wait 0 
if
056D:   actor $PLAYER_ACTOR defined
jf @start
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined 
Key_down 112
then 0B12: 0@ = 0@ XOR 1 
if  
0@ == 1  
then 
wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
end
end
Jump @start
XOR won't work with this  :face_palm:
 

MrChristmas

Expert
Joined
Jul 29, 2014
Messages
563
Reaction score
26
BlackHat link said:
Then your memory codes is wrong


Code:
:Noname_11
wait 0 
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined 
goto @Noname_11


From what I know, this line makes that script check if player is defined and he's on foot and then go to "@Noname_11" which again checks if player is on foot and defined. By this next lines

Code:
wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
goto @Noname_11 
end

won't work...
 

Badonga

Active member
Joined
Aug 5, 2013
Messages
71
Reaction score
0
Mr.Christmas link said:
Code:
:Noname_11
wait 0 
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined 
goto @Noname_11


From what I know, this line makes that script check if player is defined and he's on foot and then go to "@Noname_11" which again checks if player is on foot and defined. By this next lines

Code:
wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
goto @Noname_11 
end

won't work...

Fixed the code on first post, just need to put an activation. It works, you can test it if you don't believe me. This is auto sprint.
 

MrChristmas

Expert
Joined
Jul 29, 2014
Messages
563
Reaction score
26
Mr.Christmas link said:
What does this script do anyway ?


Try this: (didn't test it)



Code:
{$CLEO .cs}

0662: printstring "SPRINT" 

:ON
wait 5 
if 
key_down 112 
else_jump @ON
print "~W~SPRINT ~G~ON" 1500
goto @ON_2 

:ON_2
wait 0 
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined 
goto @ON_3

:ON_3
wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
goto @ON_2

:OFF
wait 5
if
key_down 112
else_jump @OFF
print "~W~SPRINT ~G~OFF" 1500
goto @OFF_1

:OFF_1
wait 5
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined
goto @OFF_2 

:OFF_2
wait 400 
0A8C: write_memory 12006520 size 0 value 0 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 0 value 0 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 0 value 0 virtual_protect 0 
goto @ON
 

Badonga

Active member
Joined
Aug 5, 2013
Messages
71
Reaction score
0

Same, opcode spam and game is fucked :X

I think it is not possible to put activation on this script.
Thank you for trying  :yesyes:
 

ThermaL

Expert
Joined
Oct 23, 2013
Messages
1,593
Reaction score
3
Mr.Ze link said:
It is possible to to put activation, but it cannot be deactivated because it is not rewritable.
Oh, rly?
Code:
{$CLEO .cs}

0000: NOP
0@ = 0
1@ = false
2@ = false

:ON
wait 0 
if
0AB0: 112
jf @ON
print "on" 2000
wait 500
goto @400

:400
wait 0
if
1@ == false
jf @100
if
0@ == 40
jf @P
0@ = 0
1@ = true
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:100
if
2@ == false
jf @50
if
0@ == 10
jf @P
0@ = 0
2@ = true
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:50
if
0@ == 5
jf @P
0@ = 0
1@ = false
2@ = false
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:OFF
if
0AB0: 112
jf @400
print "off" 2000
wait 500
goto @ON

:P
000A: 0@ += 1
goto @OFF
 

TheZeRots

Expert
Joined
Dec 21, 2013
Messages
1,247
Reaction score
1
TH3RM4L link said:
Oh, rly?
Code:
{$CLEO .cs}

0000: NOP
0@ = 0
1@ = false
2@ = false

:ON
wait 0 
if
0AB0: 112
jf @ON
print "on" 2000
wait 500
goto @400

:400
wait 0
if
1@ == false
jf @100
if
0@ == 40
jf @P
0@ = 0
1@ = true
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:100
if
2@ == false
jf @50
if
0@ == 10
jf @P
0@ = 0
2@ = true
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:50
if
0@ == 5
jf @P
0@ = 0
1@ = false
2@ = false
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:OFF
if
0AB0: 112
jf @400
print "off" 2000
wait 500
goto @ON

:P
000A: 0@ += 1
goto @OFF
Haha doesnt work m3^2-1
 

blackHat

Expert
Joined
Jul 28, 2013
Messages
930
Reaction score
2
Mr.Christmas link said:
Code:
:Noname_11
wait 0 
if and
044B:   actor $PLAYER_ACTOR on_foot 
056D:   actor $PLAYER_ACTOR defined 
goto @Noname_11


From what I know, this line makes that script check if player is defined and he's on foot and then go to "@Noname_11" which again checks if player is on foot and defined. By this next lines

Code:
wait 400 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 100 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
wait 50 
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 
goto @Noname_11 
end

won't work...

lel , just remove the second define check , i forgot to remove it
 

TheZeRots

Expert
Joined
Dec 21, 2013
Messages
1,247
Reaction score
1
Your activation doesn't work at all, now, my dear student, go over your code and learn from your mistakes!  :trollface:
 

ThermaL

Expert
Joined
Oct 23, 2013
Messages
1,593
Reaction score
3
Code:
{$CLEO .cs}

0000: NOP
0@ = 0
1@ = false
2@ = false

:ON
wait 0 
if
0AB0: 112
jf @ON
print "on" 2000
wait 500
goto @400

:400
wait 0
if
1@ == false
jf @100
if
0@ == 40
jf @P
0@ = 0
1@ = true
print "1/3 working" 3000
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:100
if
2@ == false
jf @50
if
0@ == 10
jf @P
0@ = 0
2@ = true
print "2/3 working" 3000
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:50
if
0@ == 5
jf @P
0@ = 0
1@ = false
2@ = false
print "3/3 working" 3000
0A8C: write_memory 12006520 size 2 value 255 virtual_protect 0 

:OFF
if
0AB0: 112
jf @400
print "off" 2000
wait 500
goto @ON

:P
000A: 0@ += 1
goto @OFF
I put a print before every write memory to check if everything works ok.
And, it works, video:

https://www.youtube.com/watch?v=Tp96ViMUlTY&feature=youtu.be

Now Mr.Ze is like :table_flip: and TH3RM4L is like :fuck_yea:
 
Status
Not open for further replies.
Top