|
 |
|
|
|
|
|
GTA Modification Forums
SA mission crash when busted or wasted
 |
|
 |
| |
dennis48309  |
Posted: Tuesday, Jul 31 2012, 18:08
|
Player Hater

Group: Members
Joined: Jul 30, 2012

|
If you look at what I did, I made a tiny modification to this to make it loop. A mission that starts and the thread ends right away is completely useless. I adjusted my structure to mimic the one on the tutorial, with the addition of the loop.
:BLASTEM 03A4: name_thread 'BLASTEM' $ONMISSION = 1 wait 0 0050: gosub @BLASTEM_BEGIN
:BLASTEM_LOOP wait 0 00D6: if 0112: wasted_or_busted 004D: jump_if_false @BLASTEM_LOOP 0050: gosub @BLASTEM_FAILED :BLASTEM_END 0050: gosub @BLASTEM_CLEAN 004E: end_thread :BLASTEM_BEGIN Model.Load(#COMET) Model.Load(#SWAT) Model.Load(#M4) 038B: load_requested_models
:BLASTEM_BEGIN2 if or not Model.Available(#COMET) not Model.Available(#SWAT) not Model.Available(#M4) else_jump @BLASTEM_BEGIN3 jump @BLASTEM_BEGIN2
:BLASTEM_BEGIN3 9@ = Car.Create(#COMET, 2440.6672, -1655.4305, 13.3432)
$789 = Actor.Create(CivMale, #SWAT, 2467.6672, -1655.4305, 13.3432) $787 = Actor.Create(CivMale, #SWAT, 2470.6672, -1655.4305, 13.3432) $786 = Actor.Create(CivMale, #SWAT, 2464.6672, -1655.4305, 13.3432) 0243: set_actor $789 ped_stats_to 1 01B2: give_actor $789 weapon 31 ammo 120 01B9: set_actor $789 armed_weapon_to 31 02E2: set_actor $789 weapon_accuracy_to 75 0243: set_actor $787 ped_stats_to 1 01B2: give_actor $787 weapon 31 ammo 120 01B9: set_actor $787 armed_weapon_to 31 02E2: set_actor $787 weapon_accuracy_to 75 0243: set_actor $786 ped_stats_to 1 01B2: give_actor $786 weapon 31 ammo 120 01B9: set_actor $786 armed_weapon_to 31 02E2: set_actor $786 weapon_accuracy_to 75 //$789 = Marker.CreateAboveActor($789) //$787 = Marker.CreateAboveActor($787) //$786 = Marker.CreateAboveActor($786) 077A: set_actor $789 acquaintance 4 to_actors_pedtype 0 077A: set_actor $787 acquaintance 4 to_actors_pedtype 0 077A: set_actor $786 acquaintance 4 to_actors_pedtype 0 0051: return :BLASTEM_FAILED // This section is what happens after you died or got busted during your mission 0051: return :BLASTEM_CLEAN // This section is where you clean up the contents of your mission so you can end it 0004: $ONMISSION = 0 00D8: mission_cleanup 0051: return
|
|
|
|
|
 |
|
 |
 |
|
 |
| |
SilentPL  |
Posted: Tuesday, Jul 31 2012, 18:11
|
Senior File Manager

Group: Members
Joined: Feb 1, 2010



|
Nope. Do it like R* did it. | CODE | :BLASTEM 03A4: name_thread 'BLASTEM' 0050: gosub @BLASTEM_BEGIN 00D6: if 0112: wasted_or_busted 004D: jump_if_false @BLASTEM_END 0050: gosub @BLASTEM_FAILED
:BLASTEM_END 0050: gosub @BLASTEM_CLEAN 004E: end_thread
:BLASTEM_BEGIN $ONMISSION = 1 Model.Load(#COMET) Model.Load(#SWAT) Model.Load(#M4) 038B: load_requested_models
:BLASTEM_BEGIN2 if or not Model.Available(#COMET) not Model.Available(#SWAT) not Model.Available(#M4) else_jump @BLASTEM_BEGIN3 0001: wait 0 ms jump @BLASTEM_BEGIN2
:BLASTEM_BEGIN3 9@ = Car.Create(#COMET, 2440.6672, -1655.4305, 13.3432)
$789 = Actor.Create(CivMale, #SWAT, 2467.6672, -1655.4305, 13.3432) $787 = Actor.Create(CivMale, #SWAT, 2470.6672, -1655.4305, 13.3432) $786 = Actor.Create(CivMale, #SWAT, 2464.6672, -1655.4305, 13.3432) 0243: set_actor $789 ped_stats_to 1 01B2: give_actor $789 weapon 31 ammo 120 01B9: set_actor $789 armed_weapon_to 31 02E2: set_actor $789 weapon_accuracy_to 75 0243: set_actor $787 ped_stats_to 1 01B2: give_actor $787 weapon 31 ammo 120 01B9: set_actor $787 armed_weapon_to 31 02E2: set_actor $787 weapon_accuracy_to 75 0243: set_actor $786 ped_stats_to 1 01B2: give_actor $786 weapon 31 ammo 120 01B9: set_actor $786 armed_weapon_to 31 02E2: set_actor $786 weapon_accuracy_to 75 //$789 = Marker.CreateAboveActor($789) //$787 = Marker.CreateAboveActor($787) //$786 = Marker.CreateAboveActor($786) 077A: set_actor $789 acquaintance 4 to_actors_pedtype 0 077A: set_actor $787 acquaintance 4 to_actors_pedtype 0 077A: set_actor $786 acquaintance 4 to_actors_pedtype 0
while true 0001: wait 0 ms // Put mission checks HERE end 0051: return
:BLASTEM_FAILED // This section is what happens after you died or got busted during your mission 0051: return
:BLASTEM_CLEAN // This section is where you clean up the contents of your mission so you can end it 0004: $ONMISSION = 0 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.
| |
 |
|
 |
|
|
|
|