You are not logged in.
Pages: 1
I made some progress please look at script
I need help on a cleo script i am makeing (base came from backup.cs)
ok so you hit the 4 button and it starts the chase
you hit it again and they stop / get out / gun fight
(if you hit it again ie make them stop please make shure they are close and not far from eachother as it WILL crash your game [it does mine])
I made some progress I got it working some what of how i wanted it
if you have any insight on how to make it better please let me know
CODE UPDATED 11/09/08 1:25 pm
also uploaded the cs file (place in your cleo dir)
// This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007
{$VERSION 3.1.0027}
{$CLEO .cs}
//-------------MAIN---------------
thread 'POLCHASE'
:POLCHASE_11
wait 0
if
Player.Defined($PLAYER_CHAR)
else_jump @POLCHASE_11
wait 0
if
0AB0: key_pressed 52
else_jump @POLCHASE_11
Model.Load(#COPCARVG)
Model.Load(#FORTUNE)
Model.Load(#LAPD1)
Model.Load(#BFYPRO)
Model.Load(#SILENCED)
Model.Load(#CELLPHONE)
Model.Load(#MICRO_UZI)
04C4: store_coords_to 1@ 2@ 3@ from_actor $PLAYER_ACTOR with_offset -170.0 0.0 0.0
02C1: store_to 1@ 2@ 3@ car_path_coords_closest_to 1@ 2@ 3@
04C4: store_coords_to 29@ 30@ 31@ from_actor $PLAYER_ACTOR with_offset -150.0 0.0 0.0
02C1: store_to 29@ 30@ 31@ car_path_coords_closest_to 29@ 30@ 31@
04C4: store_coords_to 14@ 15@ 16@ from_actor $PLAYER_ACTOR with_offset 0.0 10.0 0.0
02C1: store_to 14@ 15@ 16@ car_path_coords_closest_to 14@ 15@ 16@
0662: NOP "POLICE CHASE"
0662: NOP "COPYRIGHT 2008 CAKUZMA"
:POLCHASE_196
wait 0
if and
Model.Available(#COPCARVG)
Model.Available(#FORTUNE)
Model.Available(#LAPD1)
Model.Available(#BFYPRO)
Model.Available(#SILENCED)
Model.Available(#CELLPHONE)
Model.Available(#MICRO_UZI)
else_jump @POLCHASE_196
0729: AS_actor $PLAYER_ACTOR hold_cellphone 1
wait 50
0729: AS_actor $PLAYER_ACTOR hold_cellphone 0
01F7: set_player $PLAYER_CHAR ignored_by_cops 1
wait 100
4@ = Car.Create(#COPCARVG, 1@, 2@, 3@)
5@ = Car.Create(#FORTUNE, 29@, 30@, 31@)
03CC: enable_car 4@ stuck_check_distance_to 2.0 time_to 2.0
03CC: enable_car 5@ stuck_check_distance_to 2.0 time_to 2.0
0129: 10@ = create_actor_pedtype 23 model #LAPD1 in_car 4@ driverseat
0129: 11@ = create_actor_pedtype 24 model #BFYPRO in_car 5@ driverseat
0433: set_actor 11@ criminal_flag 1
0982: unknown_actor 11@ flag 1
062F: 27@ = create_group_type 4
0630: put_actor 11@ in_group 27@ as_leader
062F: 28@ = create_group_type 4
0630: put_actor 10@ in_group 28@ as_leader
:POLCHASE_408
Car.DriveTo(4@, 14@, 15@, 16@)
Car.DriveTo(5@, 14@, 15@, 16@)
067F: set_car 4@ lights 2
Car.SetImmunities(4@, 1, 1, 1, 1, 1)
Car.SetImmunities(5@, 1, 1, 1, 1, 1)
00AD: 4@ set_car_max_speed 50.0
00AD: 5@ set_car_max_speed 30.0
00AE: unknown_set_car 4@ to_ignore_traffic_lights 2
00AE: unknown_set_car 5@ to_ignore_traffic_lights 2
0423: car 4@ improve_handling 2.0
0423: car 5@ improve_handling 1.0
0397: enable_car 4@ siren 1
25@ = Marker.CreateAboveCar(4@)
26@ = Marker.CreateAboveCar(5@)
07E0: set_marker 25@ type_to 1
wait 2000
00AE: unknown_set_car 4@ to_ignore_traffic_lights 2
0423: car 4@ improve_handling 3.0
00AE: unknown_set_car 5@ to_ignore_traffic_lights 2
0423: car 5@ improve_handling 2.0
:POLCHASE_410
wait 0
if
00AD: 4@ set_car_max_speed 50.0
00AD: 5@ set_car_max_speed 30.0
0407: store_coords_to 14@ 15@ 16@ from_car 5@ with_offset 0.0 250.0 50.0
02C1: store_to 14@ 15@ 16@ car_path_coords_closest_to 14@ 15@ 16@
0AB0: key_pressed 52
Car.DriveTo(5@, 14@, 15@, 16@)
07F8: car 4@ follow_car 5@ radius 10.0
wait 50
073C: car 4@ damage_component 7 // versionB
wait 200
0A30: repair_car 4@
wait 50
073C: car 4@ damage_component 6 // versionB
wait 200
0A30: repair_car 4@
else_jump @POLCHASE_410
05CD: AS_actor 11@ exit_car 5@
07F8: car 4@ follow_car 5@ radius 3.0
wait 900
05CD: AS_actor 10@ exit_car 4@
Marker.Disable(25@)
Marker.Disable(26@)
Car.SetImmunities(4@, 0, 0, 0, 0, 0)
Car.SetImmunities(5@, 0, 0, 0, 0, 0)
wait 500
01B2: give_actor 10@ weapon 23 ammo 9999 // Load the weapon model before using this
01B2: give_actor 11@ weapon 23 ammo 9999 // Load the weapon model before using this
01B2: give_actor $PLAYER_ACTOR weapon 23 ammo 999999 // Load the weapon model before using this
jump @POLCHASE_411
:POLCHASE_411
0350: set_actor 10@ maintain_position_when_attacked 1
0350: set_actor 11@ maintain_position_when_attacked 1
05E2: AS_actor 10@ kill_actor 11@
05E2: AS_actor 11@ kill_actor 10@
wait 7000
jump @POLCHASE_679
:POLCHASE_679
wait 0
if
06EE: actor 11@ in_group 27@
else_jump @POLCHASE_412
jump @POLCHASE_689
:POLCHASE_689
if
06EE: actor 10@ in_group 28@
else_jump @POLCHASE_512
jump @POLCHASE_411
:POLCHASE_412
if
8118: actor 10@ dead
else_jump @POLCHASE_11
05CB: AS_actor 10@ enter_car 4@ as_driver 10000 ms
0397: enable_car 4@ siren 0
wait 1 1000
0407: store_coords_to 14@ 15@ 16@ from_car 4@ with_offset 0.0 500.0 90.0
02C1: store_to 14@ 15@ 16@ car_path_coords_closest_to 14@ 15@ 16@
0423: car 4@ improve_handling 2.0
Car.DriveTo(4@, 14@, 15@, 16@)
wait 5 1000
01c3: cleanup_car 4@
01c3: cleanup_car 5@
Actor.RemoveReferences(10@)
Actor.RemoveReferences(11@)
01c2: cleanup_actor 10@
01c2: cleanup_actor 11@
jump @POLCHASE_11
:POLCHASE_512
if
8118: actor 11@ dead
else_jump @POLCHASE_11
05CB: AS_actor 11@ enter_car 5@ as_driver -1 ms
wait 2 1000
04C4: store_coords_to 1@ 2@ 3@ from_actor $PLAYER_ACTOR with_offset 0.0 -100.0 0.0
02C1: store_to 1@ 2@ 3@ car_path_coords_closest_to 1@ 2@ 3@
0407: store_coords_to 14@ 15@ 16@ from_car 5@ with_offset 0.0 500.0 90.0
02C1: store_to 14@ 15@ 16@ car_path_coords_closest_to 14@ 15@ 16@
0423: car 5@ improve_handling 2.0
01c3: cleanup_car 4@
Actor.RemoveReferences(10@)
01c2: cleanup_actor 10@
wait 5 1000
4@ = Car.Create(#COPCARVG, 1@, 2@, 3@)
0129: 10@ = create_actor_pedtype 23 model #LAPD1 in_car 4@ driverseat
0630: put_actor 10@ in_group 28@ as_leader
07F8: car 4@ follow_car 5@ radius 10.0
wait 1000
Car.DriveTo(5@, 14@, 15@, 16@)
067F: set_car 4@ lights 2
Car.SetImmunities(4@, 1, 1, 1, 1, 1)
Car.SetImmunities(5@, 1, 1, 1, 1, 1)
00AD: 4@ set_car_max_speed 50.0
00AD: 5@ set_car_max_speed 0.1
00AE: unknown_set_car 4@ to_ignore_traffic_lights 3
00AE: unknown_set_car 5@ to_ignore_traffic_lights 2
0423: car 4@ improve_handling 2.0
0423: car 5@ improve_handling 2.0
0397: enable_car 4@ siren 1
25@ = Marker.CreateAboveCar(4@)
26@ = Marker.CreateAboveCar(5@)
07E0: set_marker 25@ type_to 1
wait 5000
jump @POLCHASE_410
I think i made some progress
now the problem i have is when i get next to a car that is not a police car they respown instead of just driveing by{$VERSION 3.1.0027} {$CLEO .cs} //-------------MAIN--------------- thread 'POLLOC' :POLLOC_1 wait 10 if Actor.DrivingPoliceVehicle($PLAYER_ACTOR) else_jump @POLLOC_1 //jump @POLLOC_2 :POLLOC_2 if 00A0: store actor $PLAYER_ACTOR position to 21@ 22@ 23@ 08E5: get_actor_in_sphere 21@ 22@ 23@ radius 50.0 handle_as 1@ //wait 50 056c: is_actor_driving_policecar 1@ 004D: jump_if_false @POLLOC_3 03C0: 2@ = actor 1@ car if 0ABD: vehicle 2@ siren_on 004D: jump_if_false @POLLOC_4 //jf @POLLOC_2 25@ = Marker.CreateAboveCar(2@) 07E0: set_marker 25@ type_to 1 :POLLOC_3 Actor.RemoveReferences(1@) Car.RemoveReferences(2@) jump @POLLOC_1 :POLLOC_4 Actor.RemoveReferences(1@) Car.RemoveReferences(2@) jump @POLLOC_1
Im giving up...
anyone want a crack at this be my guest
i am just not cut out to do scripting.
by all
I think i made some progress
now the problem i have is when i get next to a car that is not a police car they respown instead of just driveing by
{$VERSION 3.1.0027}
{$CLEO .cs}
//-------------MAIN---------------
thread 'POLLOC'
:POLLOC_1
wait 10
if
Actor.DrivingPoliceVehicle($PLAYER_ACTOR)
else_jump @POLLOC_1
//jump @POLLOC_2
:POLLOC_2
if
00A0: store actor $PLAYER_ACTOR position to 21@ 22@ 23@
08E5: get_actor_in_sphere 21@ 22@ 23@ radius 50.0 handle_as 1@
//wait 50
056c: is_actor_driving_policecar 1@
004D: jump_if_false @POLLOC_3
03C0: 2@ = actor 1@ car
if
0ABD: vehicle 2@ siren_on
004D: jump_if_false @POLLOC_4 //jf @POLLOC_2
25@ = Marker.CreateAboveCar(2@)
07E0: set_marker 25@ type_to 1
:POLLOC_3
Actor.RemoveReferences(1@)
Car.RemoveReferences(2@)
jump @POLLOC_1
:POLLOC_4
Actor.RemoveReferences(1@)
Car.RemoveReferences(2@)
jump @POLLOC_1
well i tryed to work on it but every time i enter the police car the game crashes to desktop
can anyone help
this is what i got so far
{$VERSION 3.1.0027}
{$CLEO .cs}
//-------------MAIN---------------
thread 'POLLOC'
:POLLOC_1
wait 10
if
Actor.DrivingPoliceVehicle($PLAYER_ACTOR)
004D: jump_if_false @POLLOC_1//jf @POLLOC_1
:POLLOC_2
00A0: store actor $PLAYER_ACTOR position to 21@ 22@ 23@
08E5: get_actor_in_sphere 21@ 22@ 23@ radius 50.0 handle_as 1@
wait 50
//00DF: is_actor_driving 1@ // tried this but it does it for every car not only police cars
00dd: is_actor 1@ driving_car_model #COPCARSF OR
00dd: is_actor 1@ driving_car_model #COPCARLA OR
00dd: is_actor 1@ driving_car_model #COPCARVG OR
00dd: is_actor 1@ driving_car_model #COPCARRU OR
//056c: is_actor_driving_policecar 1@ // tried this but it keeps erroring
004D: jump_if_false @POLLOC_2 //jf @POLLOC_2
03C0: 2@ = actor 1@ car
//0ABD: vehicle 2@ siren_on
//004D: jump_if_false @POLLOC_2 //jf @POLLOC_2
25@ = Marker.CreateAboveCar(2@)
07E0: set_marker 25@ type_to 1
jump @POLLOC_1
can anyone please help i attempted to make the script but i am stumped
i dont know how to get if the police siren is on
here is what i got so far.
(didnt compile it yet as its not complete so its not tested)
{$VERSION 3.1.0027}
{$CLEO .cs}
//-------------MAIN---------------
thread 'POLLOC'
:POLLOC_1
wait 10
if and
Actor.Driving($PLAYER_ACTOR)
Actor.DrivingPoliceVehicle($PLAYER_ACTOR)
else jump @POLLOC_1
00A0: store actor $PLAYER_ACTOR position to 21@ 22@ 23@
08E5: get_actor_in_sphere 21@ 22@ 23@ radius 50.0 handle_as 1@
03C0: 2@ = actor 1@ car
some where in here i want to check if car 2@ has its siren on
then if it does it does it does what 25@ says
but i cant find the check for siren
i found check for horn but its for player only
anybody pleas help me
25@ = Marker.CreateAboveCar(2@)
07E0: set_marker 25@ type_to 1
I was Not shure where to put this so move it to the currect location if its in the wrong form...
now for my request
say you enter a police car / bike
you drive for a bit and here sirens but cant c them
can someone make a Cleo mod where if the other cops use there sirens
and your in a cop car you get a blue marker to there location on your mini map
thanks
if Actor.Driving($PLAYER_ACTOR) then 03C0: 25@ = actor $PLAYER_ACTOR car 07F8: car 4@ follow_car 25@ radius 10.0 //Other Code end
thank you verry much
Try to use:
07F8: car 1@ follow_car 2@ radius 50.0
ok i get that car 1 is me but how to i tell the game that car 2 is me every code i use it crashes to desktop
tryed
00da: $PLAYER_CHAR set players car 0@
07F8: car 4@ follow_car 0@ radius 10.0
im trying to replace this
01B0: car 4@ sphere 0 in_sphere 14@ 15@ 16@ radius 5.0 5.0 5.0 stopped
04C4: store_coords_to 14@ 15@ 16@ from_actor $PLAYER_ACTOR with_offset 0.0 -8.0 0.0
02C1: store_to 14@ 15@ 16@ car_path_coords_closest_to 14@ 15@ 16@
this looped but sometimes the 4@ would get stuck
thanks
How do i make a Ped Follow Me in a car ex: the ped in one car and me in a different car
please i need some help
Pages: 1