Quantcast

Jump to content

» «
Photo

I need some help with a simple CLEO Mission?

9 replies to this topic
ThePlague1988
  • ThePlague1988

    Square Civilian

  • BUSTED!
  • Joined: 01 Nov 2010

#1

Posted 04 April 2012 - 09:31 PM Edited by ThePlague1988, 05 April 2012 - 04:12 AM.

I'm working on a simple mission (trying to do a R* Style mission). But the only thing that doesn't work right is when the car blows up... when you get in and out of the car I got that working where it says "hey get back in the car" but, I would like to add a check in there if the car blows up. It respawns the car and you can try it again. Thanks in advance for any help.

Here is the code.

EDIT: Someone (e.g. ZAZ, spaceeinstein, Dutchy... etc)
Please help me out thanks...

Updated: Everything works but the getting in and out of the car is sluggish now and the markers don't disable and enable when they're supposed to..
That's all that is wrong with this so far. It's my first real mission so, please be caring and try not to flame me thanks.

CODE

{$CLEO .cm}
:Mission
thread 'MYTM'
gosub @Mission_Main
if
wasted_or_busted
jf @Mission_End
gosub @Mission_Fail

:Mission_End
gosub @Mission_Cleanup
end_thread

:Mission_Main
increment_mission_attempts // here is where my mission starts
$ONMISSION = 1
wait 1000
00BC: text_highpriority 'MYTM_02' 5000 ms 1

:Mission_11
0247: load_model #GREENWOO
0247: load_model #COLT45
0247: load_model #BFYST
038B: load_requested_models

:Mission_47
if or
8248:   not model #GREENWOO available
8248:   not model #COLT45 available
8248:   not model #BFYST available
else_jump @Mission_86
wait 0 ms
jump @Mission_47

:Mission_86
0674: set_car_model #GREENWOO numberplate "I_LUV_SA"
00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
Car.Angle([email protected]) = 270.0
0224: set_car [email protected] health_to 250
0186: [email protected] = create_marker_above_car [email protected]
01B2: give_actor $PLAYER_ACTOR weapon 22 ammo 1000
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 22
00BC: show_text_highpriority GXT 'MYTM_04' time 3000 flag 1  // Get in the car parked in the middle of grove street.
[email protected] = 0      // for in the car or not?

:Mission_137
wait 0 ms
if and
[email protected] == 1
not Actor.InCar($PLAYER_ACTOR, [email protected])
jf @Mission_146
[email protected] = 2

:Mission_141
Marker.CreateAboveCar([email protected], [email protected])
Marker.Disable([email protected])
03BD: destroy_sphere [email protected]
00BC: show_text_highpriority GXT 'MYTM_03' time 3000 flag 1 // Hey get back in the car!

:Mission_146
wait 0 ms
if
 Car.Wrecked([email protected])
then
 [email protected] = 3 // if car is destoryed
 jump @Mission_Car_Wrecked
else
 if Actor.InCar($PLAYER_ACTOR, [email protected])
 then
   [email protected] = 1
 else
   jump @Mission_146
 end
end

:Mission_151
Marker.Disable([email protected])
0167: [email protected] = create_marker_at 2100.9604 -1366.8369 23.9844 flags 0 3
03BC: [email protected] = create_sphere_at 2100.9604 -1366.8369 23.9844 radius 5.0
//2100.9604 -1366.8369 23.9844 pos of the marker

:Mission_Car_Wrecked
wait 0 ms
if [email protected] == 3
then
 03BD: destroy_sphere [email protected]
 Marker.Disable([email protected])
 Marker.Disable([email protected])
 jump @Mission_86
end

:Mission_156
wait 0 ms
if and
00DB:   actor $PLAYER_ACTOR in_car [email protected]
01AE:   car [email protected] sphere 0 near_point 2100.9604 -1366.8369 23.9844 radius 5.0 5.0 stopped
else_jump @Mission_137
Marker.Disable([email protected])
03BD: destroy_sphere [email protected]
[email protected] = Actor.Create(CivFemale, #BFYST, 2094.3499, -1342.9515, 23.9844)
Actor.Angle([email protected]) = 88.44
0187: [email protected] = create_marker_above_actor [email protected]
Actor.WeaponAccuracy([email protected]) = 90
Actor.Health([email protected]) = 250
01B2: give_actor [email protected] weapon 22 ammo 1000
01B9: set_actor [email protected] armed_weapon_to 22
05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR

:Mission_178
wait 0 ms
if
Actor.Dead([email protected])
else_jump @Mission_178

:Mission_Pass
0394: play_music 1
Player.ClearWantedLevel($PLAYER_CHAR)
Player.Money($PLAYER_CHAR) += 10000
0318: set_latest_mission_passed 'TM_PASS' // My First Mission
01E3: show_text_1number_styled GXT 'M_PASS' number 10000 time 5000 style 1 // Mission Passed!
return

:Mission_Fail
00BA: text_styled 'M_FAIL' 5000 ms 1
return

:Mission_Cleanup
0249: release_model #GREENWOO
0249: release_model #COLT45
0249: release_model #BFYST
Marker.Disable([email protected])
$ONMISSION = 0
mission_cleanup
return

Bad.boy!
  • Bad.boy!

    ex SA modder

  • Feroci
  • Joined: 20 Jun 2010
  • Netherlands

#2

Posted 05 April 2012 - 06:48 AM

That's because some of the markers are never defined.
Your code never get's to this part:
CODE
:Mission_151
Marker.Disable([email protected])
0167: [email protected] = create_marker_at 2100.9604 -1366.8369 23.9844 flags 0 3
03BC: [email protected] = create_sphere_at 2100.9604 -1366.8369 23.9844 radius 5.0
//2100.9604 -1366.8369 23.9844 pos of the marker


And this part:
CODE
:Mission_156
wait 0 ms
if and
00DB:   actor $PLAYER_ACTOR in_car [email protected]
01AE:   car [email protected] sphere 0 near_point 2100.9604 -1366.8369 23.9844 radius 5.0 5.0 stopped
else_jump @Mission_137
Marker.Disable([email protected])
03BD: destroy_sphere [email protected]
[email protected] = Actor.Create(CivFemale, #BFYST, 2094.3499, -1342.9515, 23.9844)
Actor.Angle([email protected]) = 88.44
0187: [email protected] = create_marker_above_actor [email protected]
Actor.WeaponAccuracy([email protected]) = 90
Actor.Health([email protected]) = 250
01B2: give_actor [email protected] weapon 22 ammo 1000
01B9: set_actor [email protected] armed_weapon_to 22
05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR

:Mission_178
wait 0 ms
if
Actor.Dead([email protected])
else_jump @Mission_178


The code is stuck between MISSION_137 and MISSION_146. In your script the player has to get in the car, and the script will keep looping. If you get out of the car, the game will probably crash, because you disable a marker that isn't defined yet. And if your game survives it will evantually get stuck in the loop again.

ThePlague1988
  • ThePlague1988

    Square Civilian

  • BUSTED!
  • Joined: 01 Nov 2010

#3

Posted 05 April 2012 - 08:12 PM

Thanks for the reply Bad.boy, could you maybe help me fix it please?

Bad.boy!
  • Bad.boy!

    ex SA modder

  • Feroci
  • Joined: 20 Jun 2010
  • Netherlands

#4

Posted 05 April 2012 - 08:29 PM Edited by Bad.boy!, 05 April 2012 - 09:04 PM.

Sure, but what do you want? Do you want to check if the player is in the car and then perform the rest of the code or something else? And what about the markers, when do they need to show up?

EDIT: I think this is what you want (it was a pretty complicated script, but I think this will work):
CODE
{$CLEO .cm}
:Mission
thread 'MYTM'
gosub @Mission_Main
if
wasted_or_busted
jf @Mission_End
gosub @Mission_Fail

:Mission_End
gosub @Mission_Cleanup
end_thread

:Mission_Main
increment_mission_attempts // here is where my mission starts
$ONMISSION = 1
wait 1000
00BC: text_highpriority 'MYTM_02' 5000 ms 1

:Mission_11
0247: load_model #GREENWOO
0247: load_model #COLT45
0247: load_model #BFYST
038B: load_requested_models

:Mission_47
if or
8248:   not model #GREENWOO available
8248:   not model #COLT45 available
8248:   not model #BFYST available
else_jump @Mission_86
wait 0 ms
jump @Mission_47

:Mission_86
0674: set_car_model #GREENWOO numberplate "I_LUV_SA"
00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
Car.Angle([email protected]) = 270.0
0224: set_car [email protected] health_to 250
0186: [email protected] = create_marker_above_car [email protected]
01B2: give_actor $PLAYER_ACTOR weapon 22 ammo 1000
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 22
[email protected] = 0    

:MISSION_137
wait 0
if
   Car.Wrecked([email protected])
then
   jump @Mission_Car_Wrecked
else
   if
       Actor.InCar($PLAYER_ACTOR, [email protected])
   then
       0167: [email protected] = create_marker_at 2100.9604 -1366.8369 23.9844 flags 0 3
       03BC: [email protected] = create_sphere_at 2100.9604 -1366.8369 23.9844 radius 5.0
       Marker.Disable([email protected])
       jump @Mission_141
   else
       if
           [email protected] == 1
       then
           Marker.Disable([email protected])
           03BD: destroy_sphere [email protected]
           [email protected] = 0
       else
           jump @MISSION_137
       end
   end
end

:MISSION_141
wait 0
[email protected] = 1
if
   not Actor.InCar($PLAYER_ACTOR, [email protected])
then
   jump @Mission_146
else
   if
       00EC:   actor $PLAYER_ACTOR 0 near_point 2100.9604 -1366.8369 23.9844 radius 5.0 5.0
   then
       Marker.Disable([email protected])
       03BD: destroy_sphere [email protected]
       jump @Mission_151
   else
       if
           Car.Wrecked([email protected])
       then
           [email protected] = 2
           jump @Mission_Car_Wrecked
       else
           jump @MISSION_141
       end
   end
end

:MISSION_146
Marker.CreateAboveCar([email protected], [email protected])
00BC: show_text_highpriority GXT 'MYTM_04' time 3000 flag 1  // Get in the car parked in the middle of grove street.
jump @MISSION_137

:Mission_Car_Wrecked
wait 0 ms
if
   [email protected] == 2
then
   03BD: destroy_sphere [email protected]
   Marker.Disable([email protected])
   00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
   Car.Angle([email protected]) = 270.0
   0224: set_car [email protected] health_to 250
   0186: [email protected] = create_marker_above_car [email protected]
   jump @MISSION_137
else
   Marker.Disable([email protected])
   00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
   Car.Angle([email protected]) = 270.0
   0224: set_car [email protected] health_to 250
   0186: [email protected] = create_marker_above_car [email protected]
   jump @MISSION_137
end        

:MISSION_151
[email protected] = Actor.Create(CivFemale, #BFYST, 2094.3499, -1342.9515, 23.9844)
Actor.Angle([email protected]) = 88.44
0187: [email protected] = create_marker_above_actor [email protected]
Actor.WeaponAccuracy([email protected]) = 90
Actor.Health([email protected]) = 250
01B2: give_actor [email protected] weapon 22 ammo 1000
01B9: set_actor [email protected] armed_weapon_to 22
05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR

:Mission_178
wait 0 ms
if
Actor.Dead([email protected])
else_jump @Mission_178

:Mission_Pass
0394: play_music 1
Player.ClearWantedLevel($PLAYER_CHAR)
Player.Money($PLAYER_CHAR) += 10000
0318: set_latest_mission_passed 'TM_PASS' // My First Mission
01E3: show_text_1number_styled GXT 'M_PASS' number 10000 time 5000 style 1 // Mission Passed!
return

:Mission_Fail
00BA: text_styled 'M_FAIL' 5000 ms 1
return

:Mission_Cleanup
0249: release_model #GREENWOO
0249: release_model #COLT45
0249: release_model #BFYST
Marker.Disable([email protected])
$ONMISSION = 0
mission_cleanup
return

ThePlague1988
  • ThePlague1988

    Square Civilian

  • BUSTED!
  • Joined: 01 Nov 2010

#5

Posted 05 April 2012 - 11:21 PM

You know exactly what I'm trying to do but you missed it the MYTM_04 is supposed to be for when you start the mission and MYTM_03 is for (Hey get back in the car!). Anyway there are some bugs.. like the markers sometimes don't disappear if you get in and out over and over again or if the car blows up twice or more then it doesn't create the marker and sphere again. stuff like that.

BTW: I modified a thing or two..

CODE
{$CLEO .cm}
:Mission
thread 'MYTM'
gosub @Mission_Main
if
wasted_or_busted
jf @Mission_End
gosub @Mission_Fail

:Mission_End
gosub @Mission_Cleanup
end_thread

:Mission_Main
increment_mission_attempts // here is where my mission starts
$ONMISSION = 1
wait 1000
00BC: text_highpriority 'MYTM_02' 5000 ms 1

:Mission_11
0247: load_model #GREENWOO
0247: load_model #COLT45
0247: load_model #BFYST
038B: load_requested_models

:Mission_47
if or
8248:   not model #GREENWOO available
8248:   not model #COLT45 available
8248:   not model #BFYST available
else_jump @Mission_86
wait 0 ms
jump @Mission_47

:Mission_86
0674: set_car_model #GREENWOO numberplate "I_LUV_SA"
00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
Car.Angle([email protected]) = 270.0
0224: set_car [email protected] health_to 250
01B2: give_actor $PLAYER_ACTOR weapon 22 ammo 1000
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 22
00BC: show_text_highpriority GXT 'MYTM_04' time 3000 flag 1  // Get in the car parked in the middle of grove street.
Marker.CreateAboveCar([email protected], [email protected])
[email protected] = 0    

:MISSION_137
wait 0
if
  Car.Wrecked([email protected])
then
  jump @Mission_Car_Wrecked
else
  if
      Actor.InCar($PLAYER_ACTOR, [email protected])
  then
      Marker.Disable([email protected])
      0167: [email protected] = create_marker_at 2100.9604 -1366.8369 23.9844 flags 0 3
      0168: set_marker [email protected] size 3
      0165: set_marker [email protected] color_to 5
      03BC: [email protected] = create_sphere_at 2100.9604 -1366.8369 23.9844 radius 5.0
      jump @Mission_141
  else
      if
          [email protected] == 1
      then
          Marker.Disable([email protected])
          03BD: destroy_sphere [email protected]
          [email protected] = 0
      else
          jump @MISSION_137
      end
  end
end

:MISSION_141
wait 0
[email protected] = 1
if
  not Actor.InCar($PLAYER_ACTOR, [email protected])
then
  jump @Mission_146
else
  if
      00EC:   actor $PLAYER_ACTOR 0 near_point 2100.9604 -1366.8369 23.9844 radius 5.0 5.0
  then
      Marker.Disable([email protected])
      03BD: destroy_sphere [email protected]
      jump @Mission_151
  else
      if
          Car.Wrecked([email protected])
      then
          [email protected] = 2
          jump @Mission_Car_Wrecked
      else
          Marker.Disable([email protected])
          jump @MISSION_141
      end
  end
end

:MISSION_146
Marker.CreateAboveCar([email protected], [email protected])
00BC: show_text_highpriority GXT 'MYTM_03' time 3000 flag 1  // Hey get back in the car.
jump @MISSION_137

:Mission_Car_Wrecked
wait 0 ms
if
  [email protected] == 2
then
  03BD: destroy_sphere [email protected]
  Marker.Disable([email protected])
  00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
  Car.Angle([email protected]) = 270.0
  0224: set_car [email protected] health_to 250
  0186: [email protected] = create_marker_above_car [email protected]
  jump @MISSION_137
else
  Marker.Disable([email protected])
  00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
  Car.Angle([email protected]) = 270.0
  0224: set_car [email protected] health_to 250
  0186: [email protected] = create_marker_above_car [email protected]
  jump @MISSION_137
end        

:MISSION_151
[email protected] = Actor.Create(CivFemale, #BFYST, 2094.3499, -1342.9515, 23.9844)
Actor.Angle([email protected]) = 88.44
0187: [email protected] = create_marker_above_actor [email protected]
Actor.WeaponAccuracy([email protected]) = 90
Actor.Health([email protected]) = 250
01B2: give_actor [email protected] weapon 22 ammo 1000
01B9: set_actor [email protected] armed_weapon_to 22
05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR

:Mission_178
wait 0 ms
if
Actor.Dead([email protected])
else_jump @Mission_178

:Mission_Pass
0394: play_music 1
Player.ClearWantedLevel($PLAYER_CHAR)
Player.Money($PLAYER_CHAR) += 10000
0318: set_latest_mission_passed 'TM_PASS' // My First Mission
01E3: show_text_1number_styled GXT 'M_PASS' number 10000 time 5000 style 1 // Mission Passed!
return

:Mission_Fail
00BA: text_styled 'M_FAIL' 5000 ms 1
return

:Mission_Cleanup
0249: release_model #GREENWOO
0249: release_model #COLT45
0249: release_model #BFYST
Marker.Disable([email protected])
$ONMISSION = 0
mission_cleanup
return


But no major mods to it just like added in the stuff I explained above.

Bad.boy!
  • Bad.boy!

    ex SA modder

  • Feroci
  • Joined: 20 Jun 2010
  • Netherlands

#6

Posted 06 April 2012 - 12:28 PM

Does this work, I forgot a jump:
CODE
:MISSION_137
wait 0
if
 Car.Wrecked([email protected])
then
 jump @Mission_Car_Wrecked
else
 if
     Actor.InCar($PLAYER_ACTOR, [email protected])
 then
     Marker.Disable([email protected])
     0167: [email protected] = create_marker_at 2100.9604 -1366.8369 23.9844 flags 0 3
     0168: set_marker [email protected] size 3
     0165: set_marker [email protected] color_to 5
     03BC: [email protected] = create_sphere_at 2100.9604 -1366.8369 23.9844 radius 5.0
     jump @Mission_141
 else
     if
         [email protected] == 1
     then
         Marker.Disable([email protected])
         03BD: destroy_sphere [email protected]
         [email protected] = 0
         jump @MISSION_137 // I forgot this one
     else
         jump @MISSION_137
     end
 end
end

ThePlague1988
  • ThePlague1988

    Square Civilian

  • BUSTED!
  • Joined: 01 Nov 2010

#7

Posted 06 April 2012 - 01:37 PM

Thanks works perfectly now... biggrin.gif

Silent
  • Silent

    Chief Vision™ Alterer

  • GTA Mods Staff
  • Joined: 01 Feb 2010
  • Poland
  • Most Helpful [Modding] 2016
    Contribution Award [Mods]
    Best Script/Plugin 2014 [SilentPatch]
    Most Respected 2014
    Most Helpful [Mods] 2014
    Most Helpful [GTA] 2013
    Most Helpful [Mods] 2013
    Most Talented [Modding] 2013
    Best Map 2013 [ViceCityStories PC Edition]
    Best Vehicle 2013 [III Aircraft]
    Most Helpful [Mods] 2012
    Modder of the Year 2012

#8

Posted 06 April 2012 - 01:44 PM

By the way:

CODE
:Mission_11
0247: load_model #GREENWOO
0247: load_model #COLT45
0247: load_model #BFYST
038B: load_requested_models

:Mission_47
if or
8248:   not model #GREENWOO available
8248:   not model #COLT45 available
8248:   not model #BFYST available
else_jump @Mission_86
wait 0 ms
jump @Mission_47


0248 check is perfectly obsolete after you use 038B. You may use checks OR 038b, but using both will just waste space and time.

ThePlague1988
  • ThePlague1988

    Square Civilian

  • BUSTED!
  • Joined: 01 Nov 2010

#9

Posted 06 April 2012 - 06:44 PM

Thanks for the tip man...

ThePlague1988
  • ThePlague1988

    Square Civilian

  • BUSTED!
  • Joined: 01 Nov 2010

#10

Posted 15 April 2012 - 04:09 AM

Hey how come this doesn't work man I copied and pasted/edited some of the code. Then in the second part it crashes the game for some reason.... Dunno why? Could you please enlighten me. Thanks in advance.

Here is the new code:
CODE
{$CLEO .cm}
:Mission
thread 'MYTM'
gosub @Mission_Main
if
wasted_or_busted
jf @Mission_End
gosub @Mission_Fail

:Mission_End
gosub @Mission_Cleanup
end_thread

:Mission_Main
increment_mission_attempts // here is where my mission starts
$ONMISSION = 1
wait 1000
00BC: text_highpriority 'MYTM_02' 5000 ms 1

:Mission_11
0247: load_model #GREENWOO
0247: load_model #COLT45
0247: load_model #BFYST
0247: load_model #VWFYST1
038B: load_requested_models

:Mission_47
if or
8248:   not model #GREENWOO available
8248:   not model #COLT45 available
8248:   not model #BFYST available
8248:   not model #VWFYST1 available
else_jump @Mission_86
wait 0 ms
jump @Mission_47

:Mission_86
0674: set_car_model #GREENWOO numberplate "I_LUV_SA"
00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
Car.Angle([email protected]) = 270.0
0224: set_car [email protected] health_to 250
01B2: give_actor $PLAYER_ACTOR weapon 22 ammo 1000
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 22
Marker.CreateAboveCar([email protected], [email protected])
gosub @Mission_Start_Crap
[email protected] = 0    

:MISSION_137
wait 0
if
Car.Wrecked([email protected])
then
jump @Mission_Car_Wrecked
else
if
    Actor.InCar($PLAYER_ACTOR, [email protected])
then
    Marker.Disable([email protected])
    0167: [email protected] = create_marker_at 2100.9604 -1366.8369 23.9844 flags 0 3
    0168: set_marker [email protected] size 3
    0165: set_marker [email protected] color_to 5
    03BC: [email protected] = create_sphere_at 2100.9604 -1366.8369 23.9844 radius 5.0
    jump @Mission_141
else
    if
        [email protected] == 1
    then
        Marker.Disable([email protected])
        03BD: destroy_sphere [email protected]
        [email protected] = 0
        jump @MISSION_137 // I forgot this one
    else
        jump @MISSION_137
    end
end
end

:MISSION_141
wait 0
[email protected] = 1
if
  not Actor.InCar($PLAYER_ACTOR, [email protected])
then
  jump @Mission_146
else
  if
      00EC:   actor $PLAYER_ACTOR 0 near_point 2100.9604 -1366.8369 23.9844 radius 5.0 5.0
  then
      Marker.Disable([email protected])
      03BD: destroy_sphere [email protected]
      jump @Mission_151
  else
      if
          Car.Wrecked([email protected])
      then
          [email protected] = 2
          jump @Mission_Car_Wrecked
      else
          Marker.Disable([email protected])
          jump @MISSION_141
      end
  end
end

:MISSION_146
Marker.CreateAboveCar([email protected], [email protected])
00BC: show_text_highpriority GXT 'MYTM_03' time 3000 flag 1  // Hey get back in the car.
jump @MISSION_137

:Mission_Car_Wrecked
wait 0 ms
if
  [email protected] == 2
then
  03BD: destroy_sphere [email protected]
  Marker.Disable([email protected])
  00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
  Car.Angle([email protected]) = 270.0
  0224: set_car [email protected] health_to 250
  0186: [email protected] = create_marker_above_car [email protected]
  jump @MISSION_137
else
  Marker.Disable([email protected])
  00A5: [email protected] = create_car #GREENWOO at 2458.2483 -1659.0264 13.3047
  Car.Angle([email protected]) = 270.0
  0224: set_car [email protected] health_to 250
  0186: [email protected] = create_marker_above_car [email protected]
  gosub @Mission_Start_Crap
  jump @MISSION_137
end        

:MISSION_151
[email protected] = Actor.Create(CivFemale, #BFYST, 2094.3499, -1342.9515, 23.9844)
Actor.Angle([email protected]) = 88.44
0187: [email protected] = create_marker_above_actor [email protected]
Actor.WeaponAccuracy([email protected]) = 90
Actor.Health([email protected]) = 250
01B2: give_actor [email protected] weapon 22 ammo 1000
01B9: set_actor [email protected] armed_weapon_to 22
05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR

:Mission_178
wait 0 ms
if
Actor.Dead([email protected])
else_jump @Mission_178
Car.StorePos([email protected], [email protected], [email protected], [email protected])
Car.Destroy([email protected])

:Mission_196
Marker.Disable([email protected])
[email protected] = Actor.Create(CivFemale, #VWFYST1, 2094.3499, -1342.9515, 23.9844)
[email protected] = Car.Create(#GREENWOO, [email protected], [email protected], [email protected])
Actor.Angle([email protected]) = 27.14
Marker.CreateAboveActor([email protected], [email protected])
Actor.Health([email protected]) = 100
Marker.CreateAboveCar([email protected], [email protected])
gosub @Mission_Start_Crap_2
[email protected] = 0

:Mission_256
wait 0
if
Car.Wrecked([email protected])
then
jump @Mission_Car_Wrecked_2
else
if
    Actor.InCar($PLAYER_ACTOR, [email protected])
then
    Marker.Disable([email protected])
    0167: [email protected] = create_marker_at 2458.2483 -1659.0264 13.3047 flags 0 3
    0168: set_marker [email protected] size 3
    0165: set_marker [email protected] color_to 5
    03BC: [email protected] = create_sphere_at 2458.2483 -1659.0264 13.3047 radius 5.0
    jump @Mission_298
else
    if
        [email protected] == 1
    then
        Marker.Disable([email protected])
        03BD: destroy_sphere [email protected]
        [email protected] = 0
        jump @Mission_256 // I forgot this one
    else
        jump @Mission_256
    end
end
end

:Mission_298
wait 0
[email protected] = 1
if
  not Actor.InCar($PLAYER_ACTOR, [email protected])
then
  jump @Mission_326
else
  if
      not Actor.InCar([email protected], [email protected])
  then
      05CA: AS_actor [email protected] enter_car [email protected] passenger_seat 0 10000 ms
  else
      0526: set_actor [email protected] stay_in_car 1
  end
  if
      00EC:   actor $PLAYER_ACTOR 0 near_point 2458.2483 -1659.0264 13.3047 radius 5.0 5.0
  then
      Marker.Disable([email protected])
      03BD: destroy_sphere [email protected]
      jump @Mission_342
  else
      if
          Car.Wrecked([email protected])
      then
          [email protected] = 2
          jump @Mission_Car_Wrecked_2
      else
          Marker.Disable([email protected])
          jump @Mission_298
      end
  end
end

:MISSION_326
Marker.CreateAboveCar([email protected], [email protected])
00BC: show_text_highpriority GXT 'MYTM_03' time 3000 flag 1  // Hey get back in the car.
jump @Mission_256

:Mission_Car_Wrecked_2
wait 0 ms
if
  [email protected] == 2
then
  03BD: destroy_sphere [email protected]
  Marker.Disable([email protected])
  00A5: [email protected] = create_car #GREENWOO at 2100.9604 -1366.8369 23.9844
  Car.Angle([email protected]) = 270.0
  0224: set_car [email protected] health_to 1000
  0186: [email protected] = create_marker_above_car [email protected]
  jump @Mission_256
else
  Marker.Disable([email protected])
  00A5: [email protected] = create_car #GREENWOO at 2100.9604 -1366.8369 23.9844
  Car.Angle([email protected]) = 270.0
  0224: set_car [email protected] health_to 1000
  0186: [email protected] = create_marker_above_car [email protected]
  gosub @Mission_Start_Crap_2
  jump @Mission_256
end

:Mission_342
05CD: AS_actor [email protected] exit_car [email protected]
wait 2000 ms
Actor.DestroyWithFade([email protected])        

:Mission_Pass
0394: play_music 1
Player.ClearWantedLevel($PLAYER_CHAR)
Player.Money($PLAYER_CHAR) += 10000
0318: set_latest_mission_passed 'TM_PASS' // My First Mission
01E3: show_text_1number_styled GXT 'M_PASS' number 10000 time 5000 style 1 // Mission Passed!
return

:Mission_Start_Crap
00BC: show_text_highpriority GXT 'MYTM_04' time 3000 flag 1  // Get in the car parked in the middle of grove street.
return

:Mission_Start_Crap_2
00BC: show_text_highpriority GXT 'MYTM_05' time 3000 flag 1 // Get in the car with the marker above it.
return

:Mission_Fail
00BA: text_styled 'M_FAIL' 5000 ms 1
return

:Mission_Cleanup
0249: release_model #GREENWOO
0249: release_model #COLT45
0249: release_model #BFYST
0249: release_model #VWFYST1
Marker.Disable([email protected])
$ONMISSION = 0
mission_cleanup
return




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users