|
 |
|
|
|
|
|
GTA Modification Forums
spawning a sphere only after mission is completed please help
 |
|
 |
| |
spidermight  |
Posted: Saturday, Apr 7 2012, 00:40
|
Cleo Modder

Group: Members
Joined: Aug 14, 2008


|
i am having trouble getting a red sphere to spawn right after a custom mission is completed here is the scripts i am using : | CODE | {$CLEO .cs}
:Test_M_Start_1 03A4: name_thread 'Mission1starter'
:Start_load wait 0 if Player.Defined($PLAYER_CHAR) else_jump @Start_load if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 //done else_jump @Start_load Model.Load(#ARMY)
:army_guy1 wait 0 if Model.Available(#ARMY) else_jump @army_guy1 1@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) //done //Cutscene talking guy Actor.Angle(1@) = 173.9185 Actor.WeaponAccuracy(1@) = 100 0446: set_actor 1@ immune_to_headshots 1 07DD: set_actor 1@ temper_to 100 // see pedstats.dat 03FE: set_actor 1@ money 0 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(1@) = 600 Model.Destroy(#ARMY)
:not_base_sphere wait 0 if 80EC: not actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @dead_check wait 0 actor.DestroyInstantly(1@) 03BD: destroy_sphere 2@ jump @Start_load
:dead_check wait 0 if Actor.Dead(1@) jf @Test_M_Start_2 jump @end_all
:end_all actor.DestroyInstantly(1@) jump @Start_load
:Test_M_Start_2 03BD: destroy_sphere 2@ 0001: wait 0 ms 00D6: if 0 0256: player $PLAYER_CHAR defined 004D: jump_if_false @Test_M_Start_2 00D6: if 0 0038: $ONMISSION == 0 // integer values 004D: jump_if_false @Test_M_Start_2
:check_mission_passed wait 0 if 0595: mission_complete 'Mission1' jf @Test_M_Start_6 03BC: 5@ = create_sphere_at 211.2203 82.6193 3.8906 radius 2.0 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 211.2203 82.6193 3.8906 radius 1.0 1.0 1.0 on_foot //this sphere will not spawn even after custom "mission1" is completed jf @check_mission_passed 00BA: text_styled 'MSAC' 1000 ms 2 jump @Test_M_Start_2
:Test_M_Start_6 03BC: 2@ = create_sphere_at 240.6784 57.4507 2.5064 radius 2.0 00D6: if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 240.6784 57.4507 2.5064 radius 1.0 1.0 1.0 on_foot 004D: jump_if_false @not_base_sphere 00BA: text_styled 'MSAB' 1000 ms 2 actor.DestroyInstantly(1@) 0004: $ONMISSION = 1 // integer values 0A94: start_custom_mission "Mission1" jump @Test_M_Start_2 |
and this one is the custom mission1 : | CODE | {$CLEO .cm} :TestMiss_1 03A4: name_thread "Mission1" 0050: gosub @TestMiss_main_1 00D6: if 0 0112: wasted_or_busted 004D: jump_if_false @TestMiss_end_1 0050: gosub @TestMiss_fail_1
:TestMiss_end_1 0050: gosub @TestMiss_clep_1 004E: end_thread
:TestMiss_main_1 0317: increment_mission_attempts//here starts the missionscript 0004: $ONMISSION = 1
016A: fade 0 time 500
:load_army_guytalk wait 0 if Player.Defined($PLAYER_CHAR) else_jump @load_army_guytalk if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @load_army_guytalk Player.CanMove($PLAYER_CHAR, false) Model.Load(#ARMY) Model.Load(#m4) model.Load(#CELLPHONE) Model.Load(#WMYPLT) model.Load(#micro_uzi) 04ED: load_animation "GANGS"
:army_guy_talker wait 2000 if Model.Available(#ARMY) else_jump @army_guy_talker 1@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) // done Actor.Angle(1@) = 173.9185 Actor.WeaponAccuracy(1@) = 100 0446: set_actor 1@ immune_to_headshots 0 07DD: set_actor 1@ temper_to 100 // see pedstats.dat 03FE: set_actor 1@ money 0 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(1@) = 1100 Model.Destroy(#ARMY)
wait 9000 016A: fade 1 time 1000
:animation_talk2 wait 0 if 04EE: animation "GANGS" loaded else_jump @animation_talk2
0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIA' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJTMO' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIB' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJTMT' time 5500 flag 1 //6 letters max in name wait 5600 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIC' time 9000 flag 1 //6 letters max in name wait 9100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" wait 100 0729: AS_actor 1@ hold_cellphone 1 // requires to load first the model #cellphone wait 2000 00BC: show_text_highpriority GXT 'BMKID' time 7000 flag 1 //6 letters max in name wait 7100 00BC: show_text_highpriority GXT 'BMKIE' time 2500 flag 1 //6 letters max in name wait 2600 0729: AS_actor 1@ hold_cellphone 0 0249: release_model #CELLPHONE 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIF' time 8500 flag 1 //6 letters max in name wait 8600 00BC: show_text_highpriority GXT 'BMKIG' time 8500 flag 1 //6 letters max in name wait 8600 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" Player.CanMove($PLAYER_CHAR, true) 02A8: $terroristhouse = create_marker 0 at 766.5538 -555.8936 18.0129 00BC: show_text_highpriority GXT 'GTOTH' time 7000 flag 1 //6 letters max in name 03E5: show_text_box 'BINFOF'
:dead_check wait 0 if Actor.Dead(1@) else_jump @not_in_sphere_check jump @TestMiss_fail_1
:not_in_sphere_check wait 0 if 80EC: not actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @dead_check actor.DestroyInstantly(1@) jump @teleport_to_terrorist_house
:teleport_to_terrorist_house wait 0 if Player.Defined($PLAYER_CHAR) else_jump @teleport_to_terrorist_house if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 766.5538 -555.8936 18.0129 radius 2.0 2.0 2.0 on_foot //done else_jump @teleport_to_terrorist_house 0164: disable_marker $terroristhouse 016A: fade 0 time 1000 0001: wait 1000 ms 04BB: select_interior 1 04E4: unknown_refresh_game_renderer_at 223.1581 1289.0724 03CB: set_rendering_origin_at 223.1581 1289.0724 1082.1328 0860: link_actor $PLAYER_ACTOR to_interior 1 00A1: put_actor $PLAYER_ACTOR at 223.1581 1289.0724 1082.1328 0173: set_actor $PLAYER_ACTOR Z_angle_to 6.9519 0001: wait 500 ms 016A: fade 1 time 1000
:intel_pickup 0213: $PICKUP_INTEL_BM = create_pickup #BRIEFCASE type 3 at 232.0651 1287.4071 1082.1406 wait 0 if 0214: pickup $PICKUP_INTEL_BM picked_up else_jump @intel_pickup 00BC: show_text_highpriority GXT 'GNEWSO' time 4000 flag 1 //6 letters max in name wait 4100 jump @tele_out
:tele_out 016A: fade 0 time 1000 0001: wait 1000 ms 04BB: select_interior 0 04E4: unknown_refresh_game_renderer_at 766.5538 -555.8936 03CB: set_rendering_origin_at 766.5538 -555.8936 18.0129 0860: link_actor $PLAYER_ACTOR to_interior 0 00A1: put_actor $PLAYER_ACTOR at 766.5538 -555.8936 18.0129 0173: set_actor $PLAYER_ACTOR Z_angle_to 358.6452 0001: wait 500 ms 016A: fade 1 time 1000
:bad_guy wait 1000 if Model.Available(#WMYPLT) else_jump @bad_guy 0860: link_actor $PLAYER_ACTOR to_interior 0 2@ = Actor.Create(Mission1, #WMYPLT, 768.6641, -543.2671, 16.5837) // done 0860: link_actor $PLAYER_ACTOR to_interior 0 Actor.Angle(2@) = 165.4577 Actor.WeaponAccuracy(2@) = 100 0446: set_actor 2@ immune_to_headshots 1 07DD: set_actor 2@ temper_to 100 // see pedstats.dat 03FE: set_actor 2@ money 0 01B2: give_actor 2@ weapon 28 ammo 30000 // Load the weapon model before using this Actor.Health(2@) = 400 Model.Destroy(#WMYPLT) 05E2: AS_actor 2@ kill_actor $PLAYER_ACTOR 00BC: show_text_highpriority GXT 'KLLTO' time 7000 flag 1 //6 letters max in name
:dead_check2 wait 0 if Actor.Dead(2@) else_jump @dead_check2 actor.RemoveReferences(2@) 00BC: show_text_highpriority GXT 'GTORT' time 7000 flag 1 //6 letters max in name player.ClearWantedLevel($PLAYER_CHAR) 02A8: $btoport = create_marker 0 at 240.6784 57.4507 2.5064 jump @load_army_guytalk2
:load_army_guytalk2 wait 0 if Player.Defined($PLAYER_CHAR) else_jump @load_army_guytalk2 if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @load_army_guytalk2 jump @army_guy_talker2
:army_guy_talker2 wait 0 if Model.Available(#ARMY) else_jump @army_guy_talker2 3@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) // done Actor.Angle(3@) = 173.9185 Actor.WeaponAccuracy(3@) = 100 0446: set_actor 3@ immune_to_headshots 0 07DD: set_actor 3@ temper_to 100 // see pedstats.dat 03FE: set_actor 3@ money 0 01B2: give_actor 3@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(3@) = 1100 Model.Destroy(#ARMY)
:go_back_to_report wait 0 if Player.Defined($PLAYER_CHAR) else_jump @go_back_to_report if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 240.6784 57.4507 2.5064 radius 2.0 2.0 2.0 on_foot //done else_jump @go_back_to_report Player.CanMove($PLAYER_CHAR, false) 0164: disable_marker $btoport 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJFMON' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 3@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIH' time 7000 flag 1 //6 letters max in name wait 7100 jump @TestMiss_pass_1
:TestMiss_pass_1 0394: play_music 1 player.ClearWantedLevel($PLAYER_CHAR) Player.CanMove($PLAYER_CHAR, true) 0998: add_respect 10 00BA: text_styled 'MBPASS' 1000 ms 2 03E5: show_text_box 'BINFOF' 0318: set_latest_mission_passed 'Mission1' // Big Smoke jump @TestMiss_clep_1
:TestMiss_fail_1 00BA: text_styled 'MBFAIL' 1000 ms 1 jump @TestMiss_clep_1
:TestMiss_clep_1 0004: $ONMISSION = 0 00D8: mission_cleanup 0051: return |
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
Ashwin the new boy  |
Posted: Saturday, Apr 7 2012, 03:26
|
I am The Most Confused Person

Group: Members
Joined: Nov 14, 2010


|
before you proceed Next, you need to learn some Basics, like no need to use Jump in this type of case | CODE | //// script jump @1
:1
|
------------------- use "if and" in this type of case | CODE | :1 wait 0 if /// condition jf @1 if /// condition jf @1
|
use it like this | CODE | :1 wait 0 if and /// condition /// condition /// upto 7 condition jf @1
|
i hope you Understand what i meant to say anyway here is you Solution | CODE | {$CLEO .cm} :TestMiss_1 03A4: name_thread "Mission1" 0050: gosub @TestMiss_main_1 00D6: if 0 0112: wasted_or_busted 004D: jump_if_false @TestMiss_end_1 0050: gosub @TestMiss_fail_1
:TestMiss_end_1 0050: gosub @TestMiss_clep_1 004E: end_thread
:TestMiss_main_1 0317: increment_mission_attempts//here starts the missionscript 0004: $ONMISSION = 1
016A: fade 0 time 500
:load_army_guytalk wait 0 if Player.Defined($PLAYER_CHAR) else_jump @load_army_guytalk if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @load_army_guytalk Player.CanMove($PLAYER_CHAR, false) Model.Load(#ARMY) Model.Load(#m4) model.Load(#CELLPHONE) Model.Load(#WMYPLT) model.Load(#micro_uzi) 04ED: load_animation "GANGS"
:army_guy_talker wait 2000 if Model.Available(#ARMY) else_jump @army_guy_talker 1@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) // done Actor.Angle(1@) = 173.9185 Actor.WeaponAccuracy(1@) = 100 0446: set_actor 1@ immune_to_headshots 0 07DD: set_actor 1@ temper_to 100 // see pedstats.dat 03FE: set_actor 1@ money 0 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(1@) = 1100 Model.Destroy(#ARMY)
wait 9000 016A: fade 1 time 1000
:animation_talk2 wait 0 if 04EE: animation "GANGS" loaded else_jump @animation_talk2
0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIA' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJTMO' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIB' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJTMT' time 5500 flag 1 //6 letters max in name wait 5600 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIC' time 9000 flag 1 //6 letters max in name wait 9100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" wait 100 0729: AS_actor 1@ hold_cellphone 1 // requires to load first the model #cellphone wait 2000 00BC: show_text_highpriority GXT 'BMKID' time 7000 flag 1 //6 letters max in name wait 7100 00BC: show_text_highpriority GXT 'BMKIE' time 2500 flag 1 //6 letters max in name wait 2600 0729: AS_actor 1@ hold_cellphone 0 0249: release_model #CELLPHONE 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIF' time 8500 flag 1 //6 letters max in name wait 8600 00BC: show_text_highpriority GXT 'BMKIG' time 8500 flag 1 //6 letters max in name wait 8600 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" Player.CanMove($PLAYER_CHAR, true) 02A8: $terroristhouse = create_marker 0 at 766.5538 -555.8936 18.0129 00BC: show_text_highpriority GXT 'GTOTH' time 7000 flag 1 //6 letters max in name 03E5: show_text_box 'BINFOF'
:dead_check wait 0 if Actor.Dead(1@) else_jump @not_in_sphere_check jump @TestMiss_fail_1
:not_in_sphere_check wait 0 if 80EC: not actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @dead_check actor.DestroyInstantly(1@) jump @teleport_to_terrorist_house
:teleport_to_terrorist_house wait 0 if Player.Defined($PLAYER_CHAR) else_jump @teleport_to_terrorist_house if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 766.5538 -555.8936 18.0129 radius 2.0 2.0 2.0 on_foot //done else_jump @teleport_to_terrorist_house 0164: disable_marker $terroristhouse 016A: fade 0 time 1000 0001: wait 1000 ms 04BB: select_interior 1 04E4: unknown_refresh_game_renderer_at 223.1581 1289.0724 03CB: set_rendering_origin_at 223.1581 1289.0724 1082.1328 0860: link_actor $PLAYER_ACTOR to_interior 1 00A1: put_actor $PLAYER_ACTOR at 223.1581 1289.0724 1082.1328 0173: set_actor $PLAYER_ACTOR Z_angle_to 6.9519 0001: wait 500 ms 016A: fade 1 time 1000
:intel_pickup 0213: $PICKUP_INTEL_BM = create_pickup #BRIEFCASE type 3 at 232.0651 1287.4071 1082.1406 wait 0 if 0214: pickup $PICKUP_INTEL_BM picked_up else_jump @intel_pickup 00BC: show_text_highpriority GXT 'GNEWSO' time 4000 flag 1 //6 letters max in name wait 4100 jump @tele_out
:tele_out 016A: fade 0 time 1000 0001: wait 1000 ms 04BB: select_interior 0 04E4: unknown_refresh_game_renderer_at 766.5538 -555.8936 03CB: set_rendering_origin_at 766.5538 -555.8936 18.0129 0860: link_actor $PLAYER_ACTOR to_interior 0 00A1: put_actor $PLAYER_ACTOR at 766.5538 -555.8936 18.0129 0173: set_actor $PLAYER_ACTOR Z_angle_to 358.6452 0001: wait 500 ms 016A: fade 1 time 1000
:bad_guy wait 1000 if Model.Available(#WMYPLT) else_jump @bad_guy 0860: link_actor $PLAYER_ACTOR to_interior 0 2@ = Actor.Create(Mission1, #WMYPLT, 768.6641, -543.2671, 16.5837) // done 0860: link_actor $PLAYER_ACTOR to_interior 0 Actor.Angle(2@) = 165.4577 Actor.WeaponAccuracy(2@) = 100 0446: set_actor 2@ immune_to_headshots 1 07DD: set_actor 2@ temper_to 100 // see pedstats.dat 03FE: set_actor 2@ money 0 01B2: give_actor 2@ weapon 28 ammo 30000 // Load the weapon model before using this Actor.Health(2@) = 400 Model.Destroy(#WMYPLT) 05E2: AS_actor 2@ kill_actor $PLAYER_ACTOR 00BC: show_text_highpriority GXT 'KLLTO' time 7000 flag 1 //6 letters max in name
:dead_check2 wait 0 if Actor.Dead(2@) else_jump @dead_check2 actor.RemoveReferences(2@) 00BC: show_text_highpriority GXT 'GTORT' time 7000 flag 1 //6 letters max in name player.ClearWantedLevel($PLAYER_CHAR) 02A8: $btoport = create_marker 0 at 240.6784 57.4507 2.5064 jump @load_army_guytalk2
:load_army_guytalk2 wait 0 if Player.Defined($PLAYER_CHAR) else_jump @load_army_guytalk2 if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @load_army_guytalk2 jump @army_guy_talker2
:army_guy_talker2 wait 0 if Model.Available(#ARMY) else_jump @army_guy_talker2 3@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) // done Actor.Angle(3@) = 173.9185 Actor.WeaponAccuracy(3@) = 100 0446: set_actor 3@ immune_to_headshots 0 07DD: set_actor 3@ temper_to 100 // see pedstats.dat 03FE: set_actor 3@ money 0 01B2: give_actor 3@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(3@) = 1100 Model.Destroy(#ARMY)
:go_back_to_report wait 0 if Player.Defined($PLAYER_CHAR) else_jump @go_back_to_report if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 240.6784 57.4507 2.5064 radius 2.0 2.0 2.0 on_foot //done else_jump @go_back_to_report Player.CanMove($PLAYER_CHAR, false) 0164: disable_marker $btoport 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJFMON' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 3@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIH' time 7000 flag 1 //6 letters max in name wait 7100 jump @TestMiss_pass_1
:TestMiss_pass_1 0394: play_music 1 player.ClearWantedLevel($PLAYER_CHAR) Player.CanMove($PLAYER_CHAR, true) 0998: add_respect 10 00BA: text_styled 'MBPASS' 1000 ms 2 03E5: show_text_box 'BINFOF' 0318: set_latest_mission_passed 'Mission1' // Big Smoke 0004: $ONMISSION = 0 00D8: mission_cleanup Jump @Test_M_Start_1
:TestMiss_fail_1 00BA: text_styled 'MBFAIL' 1000 ms 1 0004: $ONMISSION = 0 00D8: mission_cleanup 0051: return
///////////////////// putting next to here /////////////////////////
:Test_M_Start_1 03A4: name_thread 'Mission1starter'
:Start_load wait 0 if Player.Defined($PLAYER_CHAR) else_jump @Start_load if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 //done else_jump @Start_load Model.Load(#ARMY)
:army_guy1 wait 0 if Model.Available(#ARMY) else_jump @army_guy1 1@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) //done //Cutscene talking guy Actor.Angle(1@) = 173.9185 Actor.WeaponAccuracy(1@) = 100 0446: set_actor 1@ immune_to_headshots 1 07DD: set_actor 1@ temper_to 100 // see pedstats.dat 03FE: set_actor 1@ money 0 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(1@) = 600 Model.Destroy(#ARMY)
:not_base_sphere wait 0 if 80EC: not actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @dead_check wait 0 actor.DestroyInstantly(1@) 03BD: destroy_sphere 2@ jump @Start_load
:dead_check wait 0 if Actor.Dead(1@) jf @Test_M_Start_2 jump @end_all
:end_all actor.DestroyInstantly(1@) jump @Start_load
:Test_M_Start_2 03BD: destroy_sphere 2@ 0001: wait 0 ms 00D6: if 0 0256: player $PLAYER_CHAR defined 004D: jump_if_false @Test_M_Start_2 00D6: if 0 0038: $ONMISSION == 0 // integer values 004D: jump_if_false @Test_M_Start_2
:check_mission_passed wait 0 if 0595: mission_complete 'Mission1' jf @Test_M_Start_6 03BC: 5@ = create_sphere_at 211.2203 82.6193 3.8906 radius 2.0 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 211.2203 82.6193 3.8906 radius 1.0 1.0 1.0 on_foot //this sphere will not spawn even after custom "mission1" is completed jf @check_mission_passed 00BA: text_styled 'MSAC' 1000 ms 2 jump @Test_M_Start_2
:Test_M_Start_6 03BC: 2@ = create_sphere_at 240.6784 57.4507 2.5064 radius 2.0 00D6: if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 240.6784 57.4507 2.5064 radius 1.0 1.0 1.0 on_foot 004D: jump_if_false @not_base_sphere 00BA: text_styled 'MSAB' 1000 ms 2 actor.DestroyInstantly(1@) 0004: $ONMISSION = 1 // integer values 0A94: start_custom_mission "Mission1" jump @Test_M_Start_2
| This post has been edited by Ashwin the new boy on Saturday, Apr 7 2012, 07:24
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
spidermight  |
Posted: Saturday, Apr 7 2012, 06:57
|
Cleo Modder

Group: Members
Joined: Aug 14, 2008


|
i am still having problems, even if i win or fail the mission the sphere for the next mission does not show up, i tried the one you posted but didnt work CS FILE: | CODE | {$CLEO .cs}
:Test_M_Start_1 03A4: name_thread 'Mission1starter'
:Start_load wait 0 if Player.Defined($PLAYER_CHAR) else_jump @Start_load if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 //done else_jump @Start_load Model.Load(#ARMY)
:army_guy1 wait 0 if Model.Available(#ARMY) else_jump @army_guy1 1@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) //done //Cutscene talking guy Actor.Angle(1@) = 173.9185 Actor.WeaponAccuracy(1@) = 100 0446: set_actor 1@ immune_to_headshots 1 07DD: set_actor 1@ temper_to 100 // see pedstats.dat 03FE: set_actor 1@ money 0 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(1@) = 600 Model.Destroy(#ARMY)
:not_base_sphere wait 0 if 80EC: not actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @dead_check wait 0 actor.DestroyInstantly(1@) 03BD: destroy_sphere 2@ jump @Start_load
:dead_check wait 0 if Actor.Dead(1@) jf @Test_M_Start_2 jump @end_all
:end_all actor.DestroyInstantly(1@) jump @Start_load
:Test_M_Start_2 03BD: destroy_sphere 2@ 0001: wait 0 ms 00D6: if 0 0256: player $PLAYER_CHAR defined 004D: jump_if_false @Test_M_Start_2 00D6: if 0 0038: $mission1_Passed == 0 // integer values 004D: jump_if_false @Test_M_Start_2
:Test_M_Start_6 03BC: 2@ = create_sphere_at 240.6784 57.4507 2.5064 radius 2.0 00D6: if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 240.6784 57.4507 2.5064 radius 1.0 1.0 1.0 on_foot 004D: jump_if_false @not_base_sphere 00BA: text_styled 'MSAB' 1000 ms 2 actor.DestroyInstantly(1@) 0004: $mission1_Passed = 1 // integer values 0A94: start_custom_mission "Mission1"
:0 wait 0 if 0004: $mission1_Passed = 2 jf @Test_M_Start_2
:Load_sphere_and_models_2 wait 0 if Player.Defined($PLAYER_CHAR) else_jump @Load_sphere_and_models_2 if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 //done else_jump @Load_sphere_and_models_2 Model.Load(#ARMY)
:army_guy2 wait 0 if Model.Available(#ARMY) else_jump @army_guy1 3@ = Actor.Create(Mission1, #ARMY, 246.1451, 72.8039, 3.8622) // //Cutscene talking guy2 Actor.Angle(3@) = 6.4107 Actor.WeaponAccuracy(3@) = 100 0446: set_actor 3@ immune_to_headshots 1 07DD: set_actor 3@ temper_to 100 // see pedstats.dat 03FE: set_actor 3@ money 0 01B2: give_actor 3@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(3@) = 1100 Model.Destroy(#ARMY)
:not_base_sphere2 wait 0 if 80EC: not actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @dead_check2 wait 0 actor.DestroyInstantly(3@) 03BD: destroy_sphere 4@ jump @Load_sphere_and_models_2
:dead_check2 wait 0 if Actor.Dead(3@) jf @Test_M_Start_Part_2 jump @end_all2
:end_all2 actor.DestroyInstantly(3@) jump @Start_load
:Test_M_Start_29 03BD: destroy_sphere 4@ 0001: wait 0 ms 00D6: if 0 0256: player $PLAYER_CHAR defined 004D: jump_if_false @Test_M_Start_29 00D6: if 0038: $mission1_Passed == 2 // integer values 004D: jump_if_false @Test_M_Start_29
:Test_M_Start_Part_2 03BC: 4@ = create_sphere_at 246.0344 75.0424 3.83 radius 2.0 00D6: if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 246.0344 75.0424 3.83 radius 1.0 1.0 1.0 on_foot 004D: jump_if_false @not_base_sphere2 00BA: text_styled 'MSAC' 1000 ms 2 actor.DestroyInstantly(3@) //0004: $mission2_Passed = 1 // integer values jump @Test_M_Start_29 |
CM FILE : | CODE | {$CLEO .cm} :TestMiss_1 03A4: name_thread "Mission1" 0050: gosub @TestMiss_main_1 00D6: if 0 0112: wasted_or_busted 004D: jump_if_false @TestMiss_end_1 0050: gosub @TestMiss_fail_1
:TestMiss_end_1 0050: gosub @TestMiss_clep_1 004E: end_thread
:TestMiss_main_1 0317: increment_mission_attempts//here starts the missionscript 0004: $mission1_Passed = 1
016A: fade 0 time 500
:load_army_guytalk wait 0 if Player.Defined($PLAYER_CHAR) else_jump @load_army_guytalk if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @load_army_guytalk Player.CanMove($PLAYER_CHAR, false) Model.Load(#ARMY) Model.Load(#m4) model.Load(#CELLPHONE) Model.Load(#WMYPLT) model.Load(#micro_uzi) 04ED: load_animation "GANGS"
:army_guy_talker wait 2000 if Model.Available(#ARMY) else_jump @army_guy_talker 1@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) // done Actor.Angle(1@) = 173.9185 Actor.WeaponAccuracy(1@) = 100 0446: set_actor 1@ immune_to_headshots 0 07DD: set_actor 1@ temper_to 100 // see pedstats.dat 03FE: set_actor 1@ money 0 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(1@) = 1100 Model.Destroy(#ARMY)
wait 9000 016A: fade 1 time 1000
:animation_talk2 wait 0 if 04EE: animation "GANGS" loaded else_jump @animation_talk2
0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIA' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJTMO' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIB' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJTMT' time 5500 flag 1 //6 letters max in name wait 5600 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIC' time 9000 flag 1 //6 letters max in name wait 9100 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" wait 100 0729: AS_actor 1@ hold_cellphone 1 // requires to load first the model #cellphone wait 2000 00BC: show_text_highpriority GXT 'BMKID' time 7000 flag 1 //6 letters max in name wait 7100 00BC: show_text_highpriority GXT 'BMKIE' time 2500 flag 1 //6 letters max in name wait 2600 0729: AS_actor 1@ hold_cellphone 0 0249: release_model #CELLPHONE 01B2: give_actor 1@ weapon 31 ammo 30000 // Load the weapon model before using this 0605: actor 1@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIF' time 8500 flag 1 //6 letters max in name wait 8600 00BC: show_text_highpriority GXT 'BMKIG' time 8500 flag 1 //6 letters max in name wait 8600 0792: disembark_instantly_actor 1@ 04EF: release_animation "GANGS" Player.CanMove($PLAYER_CHAR, true) 02A8: $terroristhouse = create_marker 0 at 766.5538 -555.8936 18.0129 00BC: show_text_highpriority GXT 'GTOTH' time 7000 flag 1 //6 letters max in name 03E5: show_text_box 'BINFOF'
:dead_check wait 0 if Actor.Dead(1@) else_jump @not_in_sphere_check jump @TestMiss_fail_1
:not_in_sphere_check wait 0 if 80EC: not actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @dead_check actor.DestroyInstantly(1@) jump @teleport_to_terrorist_house
:teleport_to_terrorist_house wait 0 if Player.Defined($PLAYER_CHAR) else_jump @teleport_to_terrorist_house if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 766.5538 -555.8936 18.0129 radius 2.0 2.0 2.0 on_foot //done else_jump @teleport_to_terrorist_house 0164: disable_marker $terroristhouse 016A: fade 0 time 1000 0001: wait 1000 ms 04BB: select_interior 1 04E4: unknown_refresh_game_renderer_at 223.1581 1289.0724 03CB: set_rendering_origin_at 223.1581 1289.0724 1082.1328 0860: link_actor $PLAYER_ACTOR to_interior 1 00A1: put_actor $PLAYER_ACTOR at 223.1581 1289.0724 1082.1328 0173: set_actor $PLAYER_ACTOR Z_angle_to 6.9519 0001: wait 500 ms 016A: fade 1 time 1000
:intel_pickup 0213: $PICKUP_INTEL_BM = create_pickup #BRIEFCASE type 3 at 232.0651 1287.4071 1082.1406 wait 0 if 0214: pickup $PICKUP_INTEL_BM picked_up else_jump @intel_pickup 00BC: show_text_highpriority GXT 'GNEWSO' time 4000 flag 1 //6 letters max in name wait 4100 jump @tele_out
:tele_out 016A: fade 0 time 1000 0001: wait 1000 ms 04BB: select_interior 0 04E4: unknown_refresh_game_renderer_at 766.5538 -555.8936 03CB: set_rendering_origin_at 766.5538 -555.8936 18.0129 0860: link_actor $PLAYER_ACTOR to_interior 0 00A1: put_actor $PLAYER_ACTOR at 766.5538 -555.8936 18.0129 0173: set_actor $PLAYER_ACTOR Z_angle_to 358.6452 0001: wait 500 ms 016A: fade 1 time 1000
:bad_guy wait 1000 if Model.Available(#WMYPLT) else_jump @bad_guy 0860: link_actor $PLAYER_ACTOR to_interior 0 2@ = Actor.Create(Mission1, #WMYPLT, 768.6641, -543.2671, 16.5837) // done 0860: link_actor $PLAYER_ACTOR to_interior 0 Actor.Angle(2@) = 165.4577 Actor.WeaponAccuracy(2@) = 100 0446: set_actor 2@ immune_to_headshots 1 07DD: set_actor 2@ temper_to 100 // see pedstats.dat 03FE: set_actor 2@ money 0 01B2: give_actor 2@ weapon 28 ammo 30000 // Load the weapon model before using this Actor.Health(2@) = 400 Model.Destroy(#WMYPLT) 05E2: AS_actor 2@ kill_actor $PLAYER_ACTOR 00BC: show_text_highpriority GXT 'KLLTO' time 7000 flag 1 //6 letters max in name
:dead_check2 wait 0 if Actor.Dead(2@) else_jump @dead_check2 actor.RemoveReferences(2@) 00BC: show_text_highpriority GXT 'GTORT' time 7000 flag 1 //6 letters max in name player.ClearWantedLevel($PLAYER_CHAR) 02A8: $btoport = create_marker 0 at 240.6784 57.4507 2.5064 jump @load_army_guytalk2
:load_army_guytalk2 wait 0 if Player.Defined($PLAYER_CHAR) else_jump @load_army_guytalk2 if 00EC: actor $PLAYER_ACTOR 0 near_point 234.7088 93.3518 radius 100.0 100.0 else_jump @load_army_guytalk2 jump @army_guy_talker2
:army_guy_talker2 wait 0 if Model.Available(#ARMY) else_jump @army_guy_talker2 3@ = Actor.Create(Mission1, #ARMY, 240.6714, 59.3084, 2.6639) // done Actor.Angle(3@) = 173.9185 Actor.WeaponAccuracy(3@) = 100 0446: set_actor 3@ immune_to_headshots 0 07DD: set_actor 3@ temper_to 100 // see pedstats.dat 03FE: set_actor 3@ money 0 01B2: give_actor 3@ weapon 31 ammo 30000 // Load the weapon model before using this Actor.Health(3@) = 1100 Model.Destroy(#ARMY)
:go_back_to_report wait 0 if Player.Defined($PLAYER_CHAR) else_jump @go_back_to_report if 00FF: actor $PLAYER_ACTOR sphere 1 in_sphere 240.6784 57.4507 2.5064 radius 2.0 2.0 2.0 on_foot //done else_jump @go_back_to_report Player.CanMove($PLAYER_CHAR, false) 0164: disable_marker $btoport 0605: actor $PLAYER_ACTOR perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'CJFMON' time 7000 flag 1 //6 letters max in name wait 7100 0792: disembark_instantly_actor $PLAYER_ACTOR 04EF: release_animation "GANGS" 0605: actor 3@ perform_animation_sequence "PRTIAL_GNGTLKA" IFP_file "GANGS" 4.0 loop 1 0 0 0 time -1 00BC: show_text_highpriority GXT 'BMKIH' time 7000 flag 1 //6 letters max in name wait 7100 jump @TestMiss_pass_1
:TestMiss_pass_1 0394: play_music 1 player.ClearWantedLevel($PLAYER_CHAR) Player.CanMove($PLAYER_CHAR, true) 0998: add_respect 10 00BA: text_styled 'MBPASS' 1000 ms 2 03E5: show_text_box 'BINFOF' 0318: set_latest_mission_passed 'Mission1' // Big Smoke 0004: $mission1_Passed = 2 jump @TestMiss_clep_1
:TestMiss_fail_1 00BA: text_styled 'MBFAIL' 1000 ms 1 0004: $mission1_Passed = 0 jump @TestMiss_clep_1
:TestMiss_clep_1 00D8: mission_cleanup 0051: return |
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
0 User(s) are reading this topic (0 Guests and 0 Anonymous Users)
0 Members:
Track this topic
Receive email notification when a reply has been made to this topic and you are not active on the board.
Subscribe to this forum
Receive email notification when a new topic is posted in this forum and you are not active on the board.
Download / Print this Topic
Download this topic in different formats or view a printer friendly version.
| |
 |
|
 |
|
|
|
|