A CLEO script I made today for learning purposes.
This script allows you save position and load your last saved position.
Useful in stunt challenges, parkours, etc.
Usage:
Type 'P[' in-game like singleplayer cheat to save position.
Type 'P]' in-game like singleplayer cheat to load position.
Download at attachment:
This script allows you save position and load your last saved position.
Useful in stunt challenges, parkours, etc.
Usage:
Type 'P[' in-game like singleplayer cheat to save position.
Type 'P]' in-game like singleplayer cheat to load position.
Code:
{$CLEO .cs}
0000: NOP
0@ = -65536
1@ = -65536
2@ = -65536
3@ = -65536
:SAVEPOS_1
wait 0
if and
0ADC: test_cheat "P["
Player.Defined($PLAYER_CHAR)
jf @SAVEPOS_2
00A0: store_actor $PLAYER_ACTOR position_to 0@ 1@ 2@
if
Actor.Driving($PLAYER_ACTOR)
then
4@ = Actor.CurrentCar($PLAYER_ACTOR)
3@ = Car.Angle(4@)
else
3@ = Actor.Angle($PLAYER_ACTOR)
end
0ACD: show_text_highpriority "~w~Position ~g~saved!" time 1337
wait 100
jump @SAVEPOS_2
:SAVEPOS_2
wait 0
if and
0ADC: test_cheat "P]"
Player.Defined($PLAYER_CHAR)
not 0@ == -65536
not 1@ == -65536
not 2@ == -65536
not 3@ == -65536
jf @SAVEPOS_1
Actor.PutAt($PLAYER_ACTOR, 0@, 1@, 2@)
if
Actor.Driving($PLAYER_ACTOR)
then
4@ = Actor.CurrentCar($PLAYER_ACTOR)
Car.Angle(4@) = 3@
else
Actor.Angle($PLAYER_ACTOR) = 3@
end
0373: set_camera_directly_behind_player
0ACD: show_text_highpriority "~w~Position ~b~loaded!" time 1337
wait 100
jump @SAVEPOS_1
Download at attachment: