CLEO HELP Cam restore in sniperzoom needed

SS041

New Member
Joined
Apr 1, 2020
Messages
1
Likes
0
Points
1
Location
EARTH
1
#1
Hello This is the code with sniperzoom and cam restore, but I want cam restore only, so, can someone edit for it please, Will be grateful if you make a normal .cs file for it, Thx
( Credits will be given)


// This file was decompiled using SASCM.ini published by GTAG (http://gtag.gtagaming.com/opcode-database) on 14.6.2013
{$CLEO .cs}

//-------------MAIN---------------
thread "ExtraWS"
0662: printstring "Made by FYP"
0662: printstring "BlastHack.Net"
gosub @ExtraWS_817
[email protected] = 0
[email protected] = 0
[email protected] = 0
0B34: samp register_client_command "ws" to_label @cmd

:ExtraWS_71
wait 0
if
Player.Defined(0)
jf @ExtraWS_810
if and
[email protected] == true
not Actor.Driving($PLAYER_ACTOR)
not Actor.Dead($PLAYER_ACTOR)
jf @ExtraWS_810
0470: [email protected] = actor $PLAYER_ACTOR current_weapon
0A96: [email protected] = actor $PLAYER_ACTOR struct
[email protected] += 1816
0A8D: [email protected] = read_memory [email protected] size 1 virtual_protect 0
[email protected] += 1
if and
[email protected] >= 3
not [email protected] > 7
jf @ExtraWS_810
if
not [email protected] == 34
jf @ExtraWS_810
if
00E1: player 0 pressed_key 6
jf @ExtraWS_465
if
[email protected] == 0
jf @ExtraWS_299
0A8D: [email protected] = read_memory 5379741 size 4 virtual_protect 1
0A8D: [email protected] = read_memory 5379745 size 2 virtual_protect 1
0A8C: write_memory 5379741 size 4 value -1869574000 virtual_protect 1
0A8C: write_memory 5379745 size 2 value 37008 virtual_protect 1
[email protected] = 1

:ExtraWS_299
if
[email protected] == 0
jf @ExtraWS_458
if or
[email protected] == 6
[email protected] == 7
jf @ExtraWS_458
0A8D: [email protected] = read_memory 11989584 size 4 virtual_protect 0
if or
not [email protected] > 50.0
[email protected] == 1
jf @ExtraWS_458
0A8D: [email protected] = read_memory 5379774 size 4 virtual_protect 1
0A8D: [email protected] = read_memory 5379778 size 2 virtual_protect 1
0A8C: write_memory 5379774 size 4 value -1869574000 virtual_protect 1
0A8C: write_memory 5379778 size 2 value 37008 virtual_protect 1
[email protected] = 1
[email protected] = 0

:ExtraWS_458
goto @ExtraWS_571

:ExtraWS_465
if
[email protected] == 1
jf @ExtraWS_518
0A8C: write_memory 5379741 size 4 value [email protected] virtual_protect 1
0A8C: write_memory 5379745 size 2 value [email protected] virtual_protect 1
[email protected] = 0

:ExtraWS_518
if
[email protected] == 1
jf @ExtraWS_571
0A8C: write_memory 5379774 size 4 value [email protected] virtual_protect 1
0A8C: write_memory 5379778 size 2 value [email protected] virtual_protect 1
[email protected] = 0

:ExtraWS_571
if
00E1: player 0 pressed_key 6
jf @ExtraWS_810
if
00E1: player 0 pressed_key 5
jf @ExtraWS_699
0A8D: [email protected] = read_memory 11989584 size 4 virtual_protect 0
[email protected] += 2.0
if
[email protected] > 70.0
jf @ExtraWS_660
[email protected] = 70.0

:ExtraWS_660
0A8C: write_memory 11989584 size 4 value [email protected] virtual_protect 0
if
[email protected] == 0
jf @ExtraWS_699
[email protected] = 1

:ExtraWS_699
if
00E1: player 0 pressed_key 7
jf @ExtraWS_810
0A8D: [email protected] = read_memory 11989584 size 4 virtual_protect 0
[email protected] -= 2.0
if
not [email protected] >= 4.0
jf @ExtraWS_771
[email protected] = 4.0

:ExtraWS_771
0A8C: write_memory 11989584 size 4 value [email protected] virtual_protect 0
if
[email protected] == 0
jf @ExtraWS_810
[email protected] = 1

:ExtraWS_810
goto @ExtraWS_71

:cmd
if
[email protected] == false
then
[email protected] = true
chatmsg "+" -1
else
[email protected] = false
chatmsg "-" -1
end
0B43: samp cmd_ret


:ExtraWS_817
0A8C: write_memory 5310892 size 1 value 235 virtual_protect 1
0A8C: write_memory 5310917 size 1 value 235 virtual_protect 1
0A8C: write_memory 5386662 size 1 value 235 virtual_protect 1
0A8C: write_memory 5386797 size 1 value 235 virtual_protect 1
0A8C: write_memory 5387194 size 1 value 235 virtual_protect 1
return
 
Last edited:

ajom

Well-Known Member
Joined
Apr 14, 2020
Messages
71
Likes
36
Points
18
Location
Pluto
#2
Hello This is the code with sniperzoom and cam restore, but I want cam restore only, so, can someone edit for it please, Will be grateful if you make a normal .cs file for it, Thx
( Credits will be given)


// This file was decompiled using SASCM.ini published by GTAG (http://gtag.gtagaming.com/opcode-database) on 14.6.2013
{$CLEO .cs}

//-------------MAIN---------------
thread "ExtraWS"
0662: printstring "Made by FYP"
0662: printstring "BlastHack.Net"
gosub @ExtraWS_817
[email protected] = 0
[email protected] = 0
[email protected] = 0
0B34: samp register_client_command "ws" to_label @cmd

:ExtraWS_71
wait 0
if
Player.Defined(0)
jf @ExtraWS_810
if and
[email protected] == true
not Actor.Driving($PLAYER_ACTOR)
not Actor.Dead($PLAYER_ACTOR)
jf @ExtraWS_810
0470: [email protected] = actor $PLAYER_ACTOR current_weapon
0A96: [email protected] = actor $PLAYER_ACTOR struct
[email protected] += 1816
0A8D: [email protected] = read_memory [email protected] size 1 virtual_protect 0
[email protected] += 1
if and
[email protected] >= 3
not [email protected] > 7
jf @ExtraWS_810
if
not [email protected] == 34
jf @ExtraWS_810
if
00E1: player 0 pressed_key 6
jf @ExtraWS_465
if
[email protected] == 0
jf @ExtraWS_299
0A8D: [email protected] = read_memory 5379741 size 4 virtual_protect 1
0A8D: [email protected] = read_memory 5379745 size 2 virtual_protect 1
0A8C: write_memory 5379741 size 4 value -1869574000 virtual_protect 1
0A8C: write_memory 5379745 size 2 value 37008 virtual_protect 1
[email protected] = 1

:ExtraWS_299
if
[email protected] == 0
jf @ExtraWS_458
if or
[email protected] == 6
[email protected] == 7
jf @ExtraWS_458
0A8D: [email protected] = read_memory 11989584 size 4 virtual_protect 0
if or
not [email protected] > 50.0
[email protected] == 1
jf @ExtraWS_458
0A8D: [email protected] = read_memory 5379774 size 4 virtual_protect 1
0A8D: [email protected] = read_memory 5379778 size 2 virtual_protect 1
0A8C: write_memory 5379774 size 4 value -1869574000 virtual_protect 1
0A8C: write_memory 5379778 size 2 value 37008 virtual_protect 1
[email protected] = 1
[email protected] = 0

:ExtraWS_458
goto @ExtraWS_571

:ExtraWS_465
if
[email protected] == 1
jf @ExtraWS_518
0A8C: write_memory 5379741 size 4 value [email protected] virtual_protect 1
0A8C: write_memory 5379745 size 2 value [email protected] virtual_protect 1
[email protected] = 0

:ExtraWS_518
if
[email protected] == 1
jf @ExtraWS_571
0A8C: write_memory 5379774 size 4 value [email protected] virtual_protect 1
0A8C: write_memory 5379778 size 2 value [email protected] virtual_protect 1
[email protected] = 0

:ExtraWS_571
if
00E1: player 0 pressed_key 6
jf @ExtraWS_810
if
00E1: player 0 pressed_key 5
jf @ExtraWS_699
0A8D: [email protected] = read_memory 11989584 size 4 virtual_protect 0
[email protected] += 2.0
if
[email protected] > 70.0
jf @ExtraWS_660
[email protected] = 70.0

:ExtraWS_660
0A8C: write_memory 11989584 size 4 value [email protected] virtual_protect 0
if
[email protected] == 0
jf @ExtraWS_699
[email protected] = 1

:ExtraWS_699
if
00E1: player 0 pressed_key 7
jf @ExtraWS_810
0A8D: [email protected] = read_memory 11989584 size 4 virtual_protect 0
[email protected] -= 2.0
if
not [email protected] >= 4.0
jf @ExtraWS_771
[email protected] = 4.0

:ExtraWS_771
0A8C: write_memory 11989584 size 4 value [email protected] virtual_protect 0
if
[email protected] == 0
jf @ExtraWS_810
[email protected] = 1

:ExtraWS_810
goto @ExtraWS_71

:cmd
if
[email protected] == false
then
[email protected] = true
chatmsg "+" -1
else
[email protected] = false
chatmsg "-" -1
end
0B43: samp cmd_ret


:ExtraWS_817
0A8C: write_memory 5310892 size 1 value 235 virtual_protect 1
0A8C: write_memory 5310917 size 1 value 235 virtual_protect 1
0A8C: write_memory 5386662 size 1 value 235 virtual_protect 1
0A8C: write_memory 5386797 size 1 value 235 virtual_protect 1
0A8C: write_memory 5387194 size 1 value 235 virtual_protect 1
return
That codes was ancient already, that script simulates opcode 0922 . It is easier to use modern opcodes than relying on that complex coding stuff...

To restore sniper camera, use the opcode like this:
Code:
{
1.0 - normal/restore zoom(100%)
0.5 - x2 zoom(200%)
0.25 - x4 zoom(400%)
}
0922: set_camera_zoom_from 1.0 to 1.0 timelimit 1 smooth_transition true
 

ajom

Well-Known Member
Joined
Apr 14, 2020
Messages
71
Likes
36
Points
18
Location
Pluto
#3
I have not tested this yet, you can improve it if you like to:
Code:
{$CLEO .cs}
0000: camera zoom restore by ajom

While true
 wait 0
 If 0AB0:  key_pressed 88 // key X
 then 0922: set_camera_zoom_from 1.0 to 1.0 timelimit 1 smooth_transition true
 end
End
 
Top