HeresOtis Posted May 14, 2011 Share Posted May 14, 2011 My cars aren't spawning and I have the NumLock on(using numpad numbers). The script compiled but doesn't spawn the vehicles. {$CLEO .cs}//-------------MAIN---------------thread 'SPAWN' 0000: NOPModel.Load(#COPCARLA)Model.Load(#COPCARRU)Model.Load(#POLMAV)Model.Load(#LAPD1)Model.Load(#LAPDM1)Model.Load(#LAEMT1)Model.Load(#LAFD1)Model.Load(#BMYAP)Model.Load(#VCNMAV)Model.Load(#AMBULAN)Model.Load(#FIRETRUK)[email protected] = 0:SPAWN_1wait 0 if Player.Defined($PLAYER_CHAR)else_jump @SPAWN_1 04C4: store_coords_to [email protected] [email protected] [email protected] from_actor $PLAYER_ACTOR with_offset 0.0 -20.0 0.0 jump @SPAWN_2:SPAWN_2wait 0if 0AB0: key_pressed 97else_jump @SPAWN_3jump @SPAWN_8:SPAWN_3wait 0 if 0AB0: key_pressed 98else_jump @SPAWN_4jump @SPAWN_9:SPAWN_4wait 0 if 0AB0: key_pressed 99else_jump @SPAWN_5jump @SPAWN_10:SPAWN_5wait 0 if 0AB0: key_pressed 100else_jump @SPAWN_6jump @SPAWN_11:SPAWN_6wait 0if0AB0: key_pressed 101else_jump @SPAWN_7jump @SPAWN_12:SPAWN_7wait 0if 0AB0: key_pressed 102else_jump @SPAWN_16jump @SPAWN_13:SPAWN_16wait 0if 0AB0: key_pressed 96else_jump @SPAWN_2jump @SPAWN_17:SPAWN_8wait 0 if Model.Available(#COPCARLA)jf @[email protected] = Car.Create(#COPCARLA, [email protected], [email protected], [email protected])0129: [email protected] = create_actor_pedtype 6 model #LAPD1 in_car [email protected] driverseat0397: enable_car [email protected] siren 1067F: set_car [email protected] lights 2Car.DoorStatus([email protected]) = 1jump @SPAWN_2:SPAWN_9wait 0 if Model.Available(#COPCARRU)jf @[email protected] = Car.Create(#COPCARRU, [email protected], [email protected], [email protected])0129: [email protected] = create_actor_pedtype 6 model #LAPD1 in_car [email protected] driverseat0397: enable_car [email protected] siren 1067F: set_car [email protected] lights 2Car.DoorStatus([email protected]) = 1jump @SPAWN_2:SPAWN_10wait 0 if Model.Available(#FIRETRUK)jf @[email protected] = Car.Create(#FIRETRUK, [email protected], [email protected], [email protected])0129: [email protected] = create_actor_pedtype 19 model #LAFD1 in_car [email protected] driverseat0397: enable_car [email protected] siren 1067F: set_car [email protected] lights 2Car.DoorStatus([email protected]) = 1jump @SPAWN_2:SPAWN_11wait 0 if Model.Available(#AMBULAN)jf @[email protected] = Car.Create(#AMBULAN, [email protected], [email protected], [email protected])0129: [email protected] = create_actor_pedtype 18 model #LAEMT1 in_car [email protected] driverseat0397: enable_car [email protected] siren 1067F: set_car [email protected] lights 2Car.DoorStatus([email protected]) = 1jump @SPAWN_2:SPAWN_12wait 0 if Model.Available(#POLMAV)jf @[email protected] = Car.Create(#POLMAV, [email protected], [email protected], [email protected])0129: [email protected] = create_actor_pedtype 6 model #LAPDM1 in_car [email protected] driverseatCar.DoorStatus([email protected]) = 10780: heli [email protected] hover_above actor $PLAYER_ACTOR car -1 altitude 15.0 170.0jump @SPAWN_2:SPAWN_13wait 0 if Model.Available(#VCNMAV)jf @[email protected] = Car.Create(#VCNMAV, [email protected], [email protected], [email protected])0129: [email protected] = create_actor_pedtype 4 model #BMYAP in_car [email protected] driverseatCar.DoorStatus([email protected]) = 10780: heli [email protected] hover_above actor $PLAYER_ACTOR car -1 altitude 15.0 170.0jump @SPAWN_2:SPAWN_14wait 0 00BF: [email protected] = current_time_hours, [email protected] = current_time_minutes if [email protected] >= 19 6 > [email protected] @SPAWN_15 [email protected] == 0 jf @SPAWN_1506C1: create_searchlight [email protected] on_car [email protected] with_offset 0.0 -1.3 -0.7 radius 0.2 target 0.0 0.0 0.0 radius 15.0 06BF: set_searchlight [email protected] follow_car [email protected] speed [email protected] = 1:SPAWN_15if [email protected] >= 6 19 > [email protected] [email protected] == 1 jf @SPAWN_1406B2: destroy_searchlight [email protected]@ = 0jump @SPAWN_14:SPAWN_17wait 0if Car.Defined([email protected])jf @SPAWN_20158: camera_on_car [email protected] 18 2jump @SPAWN_2 Link to comment Share on other sites More sharing options...
HeresOtis Posted May 14, 2011 Author Share Posted May 14, 2011 nevermind. someone can close. Link to comment Share on other sites More sharing options...
OrionSR Posted May 14, 2011 Share Posted May 14, 2011 So... When you made this script did you write it all at once and then wonder why it isn't working, or did you write a smaller test script and then add to it once you got it working? What happens when CJ moves away from the point where the save was loaded and the coords are stored? Are you loading indoors? What happens if the car model isn't loaded? What happens if the ped model isn't loaded? Have you considered using the opcodes referenced below? 0825: set_helicopter [email protected] instant_rotor_start 01C2: remove_references_to_actor [email protected] // Like turning an actor into a random pedestrian 01C3: remove_references_to_car $IMPORT_CAR // Like turning a car into any random car Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now