Pie015 Posted April 14, 2013 Share Posted April 14, 2013 Hey guys, I don't know whats up with my mission but every time I enter the sphere, the game crashes, I looked in my script but couldn't find any error or mistake. Can you guys please help? A really untidy code I know. {$CLEO .cs}//------------MAIN------------thread 'MISSION1':0wait 0ifPlayer.Defined($PLAYER_CHAR)jf @[email protected] = Marker.CreateIconAndSphere(55, 1181.4739, -1362.6329, 14.1687):1wait 0if and0102: actor $PLAYER_ACTOR in_sphere 1181.4739 -1362.6329 14.1687 radius 2.0 2.0 2.0 sphere 0 stopped_on_footnot Actor.Driving($PLAYER_ACTOR)jf @1Marker.Disable([email protected])Player.CanMove($PLAYER_ACTOR) = Falsefade 0 1500wait 2000Actor.PutAt($PLAYER_ACTOR, 1183.8512, -1369.7137, 24.0105)Actor.Angle($PLAYER_ACTOR) = 324.2892wait 5000110: clear_player $PLAYER_CHAR wanted_level04EB: AS_actor $PLAYER_ACTOR crouch 1 [email protected] = Pickup.Create(1240, 15, 1179.2755, -1369.325, 23.9915) [email protected] = Pickup.Create(1242, 15, 1178.4475, -1372.505, 23.9881):2wait 0Model.Load(#SNIPER)Model.Load(#STRETCH)Model.Load(#MP5LNG)Model.Load(#COPCARLA)Model.Load(#MAFBOSS)Model.Load(#ARMY)038B: load_requested_models:3wait 0if ornot Model.Available(#SNIPER)not Model.Available(#STRETCH)not Model.Available(#MP5LNG)not Model.Available(#COPCARLA)not Model.Available(#MAFBOSS)not Model.Available(#ARMY)jf @4wait 0jump @3:4wait 001B2: give_actor $PLAYER_ACTOR weapon 34 ammo 150 // Load the weapon model before using this01B9: set_actor $PLAYER_ACTOR armed_weapon_to 34 0395: clear_area 1 at 1230.9407 -1281.4924 13.0865 radius 20.0wait [email protected] = Car.Create(#STRETCH, 1230.9407, -1281.4924, 13.0865)Car.Angle([email protected]) = [email protected] = Car.Create(#COPCARLA, 1239.9238, -1281.2526, 13.0001)Car.Angle([email protected]) = [email protected] = Car.Create(#COPCARLA, 1222.7098, -1280.7329, 12.9619)Car.Angle([email protected]) = 90.00129: [email protected] = create_actor_pedtype 6 model #ARMY in_car [email protected] driverseat 0129: [email protected] = create_actor_pedtype 6 model #ARMY in_car [email protected] driverseat 0129: [email protected] = create_actor_pedtype 6 model #ARMY in_car [email protected] driverseat01C8: [email protected] = create_actor_pedtype 6 model #ARMY in_car [email protected] passenger_seat 0 01C8: [email protected] = create_actor_pedtype 6 model #ARMY in_car [email protected] passenger_seat 001C8: [email protected] = create_actor_pedtype 4 model #MAFBOSS in_car [email protected] passenger_seat 20350: set_actor [email protected] maintain_position_when_attacked [email protected] = Marker.CreateAboveActor([email protected])Marker.SetColor([email protected], 0)01B2: give_actor [email protected] weapon 29 ammo 150 // Load the weapon model before using this01B9: set_actor [email protected] armed_weapon_to 29 01B2: give_actor [email protected] weapon 29 ammo 150 // Load the weapon model before using this01B9: set_actor [email protected] armed_weapon_to 29 01B2: give_actor [email protected] weapon 29 ammo 150 // Load the weapon model before using this01B9: set_actor [email protected] armed_weapon_to 29 01B2: give_actor [email protected] weapon 29 ammo 150 // Load the weapon model before using this01B9: set_actor [email protected] armed_weapon_to 29 01B2: give_actor [email protected] weapon 29 ammo 150 // Load the weapon model before using this01B9: set_actor [email protected] armed_weapon_to 29 01B2: give_actor [email protected] weapon 29 ammo 150 // Load the weapon model before using this01B9: set_actor [email protected] armed_weapon_to 29 wait 500fade 1 1500Player.CanMove($PLAYER_CHAR) = True05D1: AS_actor [email protected] drive_car [email protected] to 1197.2988 -1376.3077 12.8656 speed 25.0 0 model #NULL 0 07F8: car [email protected] follow_car [email protected] radius 5.007F8: car [email protected] follow_car [email protected] radius 5.0:5wait 0if orActor.Dead($PLAYER_ACTOR)0741: actor $PLAYER_ACTOR busted jf @6wait 0jump @MISFAIL:6wait 0ifActor.Dead([email protected])jf @5wait 0:MISPASSwait 00394: play_music 101E3: show_text_1number_styled GXT 'M_PASS' number 10000 time 5000 style 1 // MISSION PASSED!~n~~w~$~1~Player.Money($PLAYER_CHAR) += 10000Pickup.Destroy([email protected])Pickup.Destroy([email protected])Car.RemoveReferences([email protected]) Car.RemoveReferences([email protected])Car.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Marker.Disable([email protected])0249: release_model #MP5LNG0249: release_model #SNIPER0249: release_model #ARMY0249: release_model #STRETCH0249: release_model #MAFBOSS0249: release_model #COPCARLAwait 1000end_custom_thread:MISFAILwait 000BA: show_text_styled GXT 'M_FAIL' time 5000 style 1Pickup.Destroy([email protected])Pickup.Destroy([email protected])Car.RemoveReferences([email protected]) Car.RemoveReferences([email protected])Car.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Actor.RemoveReferences([email protected])Marker.Disable([email protected])0249: release_model #MP5LNG0249: release_model #SNIPER0249: release_model #ARMY0249: release_model #STRETCH0249: release_model #MAFBOSS0249: release_model #COPCARLAwait 1000jump @0 Link to comment Share on other sites More sharing options...
ZAZ Posted April 14, 2013 Share Posted April 14, 2013 this cause the crash: Player.CanMove($PLAYER_ACTOR) = False in addition do you have to write the code end_custom_thread with opcode 0A93: end_custom_thread or did you insert it in your keywords.txt? CLEO MODS CLEO Script Tutorial 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