CLEO Help 056E: does_vehicle_exist not working

CLEO related
Status
Not open for further replies.

GeorgeMor

Member
Joined
Apr 15, 2020
Messages
9
Reaction score
0
Location
Scotland
Hi,

I have made this script but it seems like the function 056E: does_vehicle_exist is never true

Code:
{$CLEO}                               
0000: NOP


//-------------MAIN---------------
thread "GREENSHxOOTER"


0AC8: 7@ = allocate_memory_size 1024
0AD3: 7@ = format "/opx"

:caricamento
if
    Player.Defined($PLAYER_CHAR)
else_jump @caricamento

:GREENSHOOTER_14
wait 50
    if
        0AB0:   key_pressed 70
    else_jump @GREENSHOOTER_14

    0AB5: store_actor $PLAYER_ACTOR closest_vehicle_to 2@ closest_ped_to 16@
    0AD1: show_formatted_text_highpriority "THIS POINT IS REACHED" time 1000
    if
        056E: does_vehicle_exist 2@
    else_jump @GREENSHOOTER_14
    0AD1: show_formatted_text_highpriority "THIS POINT IS NEVER REACHED" time 1000

    Actor.StorePos($PLAYER_ACTOR, 5@, 6@, 7@)
    Car.StorePos(2@, 11@, 12@, 13@)
    050A: 9@ = get_distance_between_coords_3d 11@ 12@ 13@ and 5@ 6@ 7@

jump @GREENSHOOTER_14

Which is the problem?


And if I remove this:

Code:
    if
        056E: does_vehicle_exist 2@
    else_jump @GREENSHOOTER_14
The game crashes
 
Last edited:

GeorgeMor

Member
Joined
Apr 15, 2020
Messages
9
Reaction score
0
Location
Scotland
I have found that the problem is behind:
Code:
0AB5: store_actor $PLAYER_ACTOR closest_vehicle_to 2@ closest_ped_to 16@
This doesn't seem to work (0.3dl cleo 4.3), is there any alternative?
 
Status
Not open for further replies.
Top