Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {$CLEO}
- 0000: NOP
- thread "awalk"
- wait 2000
- 0B34: samp register_client_command "awalk" to_label @awalk
- 19@ = 2150
- 20@ = 2150
- chatmsg "awalk by {28afe0} [TwentyOne]{ffffff}, pentru detalii /ahelp" -1
- :awalk
- if 22@ == 0
- then
- 22@ = 1
- else
- if 22@ == 1
- then
- 22@ = 0
- end
- end
- samp.CmdRet()
- if 22@ == 1
- then
- call @cpexists 0 23@
- if and
- 24@ == 0
- 23@ == 1
- then
- 24@ = 1
- end
- if 23@ == 1
- then
- call @get_cp_pos 0 X 28@ Y 29@ Z 30@
- 00A0: store_actor $PLAYER_ACTOR position_to $px $py $pz
- 0509: 27@ = distance_between_XY $px $py and_XY 28@ 29@
- if 27@ < 100.0
- then
- //0A8C: write_memory 0xB7345B size 1 value 255 virtual_protect 0 // cod de mers
- 0B56: set_game_key 1 state -255
- 0B56: set_game_key 16 state 255
- call @camatpos 5 _XYZ 28@ 29@ 30@ _withCamOffsetAngleX 0.0 _andCamOffsetAngleZ 0.0
- end
- end
- if 23@ == 0
- then
- 22@ = 0
- wait 250
- say "/stopanim"
- if 24@ ==1
- then
- 24@ = 0
- 22@ = 1
- wait 1000
- end
- end
- if 22@ == 0
- then
- chatmsg "Job done!" -1
- 18@ = 0
- end
- end
- wait 0
- :get_cp_pos
- if
- 0AA2: 0@ = load_library "samp.dll" // IF and SET
- then
- 0A8E: 1@ = 0@ + 2203916 // int
- 0A8D: 1@ = read_memory 1@ size 4 virtual_protect 0
- 1@ += 12
- 0A8D: 15@ = read_memory 1@ size 4 virtual_protect 0
- 1@ += 4
- 0A8D: 16@ = read_memory 1@ size 4 virtual_protect 0
- 1@ += 4
- 0A8D: 17@ = read_memory 1@ size 4 virtual_protect 0
- 0AA3: free_library 0@
- end
- 0AB2: ret 3 15@ 16@ 17@
- :cpexists
- if 0AA2: 0@ = load_library "samp.dll" // IF and SET
- then
- 0A8E: 1@ = 0@ + 2203916 // int
- 0A8D: 1@ = read_memory 1@ size 4 virtual_protect 0
- 1@ += 36
- 0A8D: 1@ = read_memory 1@ size 4 virtual_protect 0
- 0AA3: free_library 0@
- end
- 0AB2: ret 1 1@
- :camatpos
- // ~~~~~~~~~~anti auto-vehicle cam movement
- if and
- TIMER = 400
- Actor.Driving($PLAYER_ACTOR)
- then
- 0A8C: write_memory 0xB70118 size 4 value 50.0 virtual_protect 0 // reset camera stabalizer timer, credit to Parazitas
- TIMER = 0
- end
- // ~~~~~~~~~~
- 068D: get_camera_position_to 31@ 30@ 29@
- // ~~~~~~~~~~Camera Z-Angle from our camera towards the target
- 0087: 28@ = 1@ // y2
- 0063: 28@ -= 30@ // y1
- 0087: 27@ = 0@ // x2
- 0063: 27@ -= 31@ // x1
- 0AA5: atan2 | 0x4207C0 2 2 | _X 27@ _Y 28@
- 0AE9: pop_float 28@ // store result from above operation
- 28@ += 3.1415926535897981710616733832795 // Camera Angle Leads 180 degrees respect to Z world coordinats
- 005B: 28@ += 4@ // use the defined camz offset to move the camera leftwards or rightwards
- // ~~~~~~~~~~
- // ~~~~~~~~~~Camera X-Angle from our camera towards the target
- 0087: 27@ = 2@ // z2
- 0063: 27@ -= 29@ // z1
- 0509: 26@ = distance_between_XY 31@ 30@ and_XY 0@ 1@ // adjacent side
- 0AA5: atan2 | 0x4207C0 2 2 | _X 26@ _Y 27@
- 0AE9: pop_float 27@ // store result from above operation
- 005B: 27@ += 3@ // use the defined camx offset to move the camera downwards or upwards
- // ~~~~~~~~~~
- 0A25: set_camera_on_players_X_angle 27@ Z_angle 28@
- ret 0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement