// Super Tank 25/05/2009
// www.GTAMP.com
// This script is public domain.  You can use it freely.

OBJ_DATA ball_1 = (1.0,1.0,255.0) 0 FOOTY 
OBJ_DATA ball_2 = (255.0,255.0,255.0) 0 FOOTY
OBJ_DATA ball_3 = (255.0,1.0,255.0) 0 FOOTY
OBJ_DATA ball_4 = (1.0,255.0,255.0) 0 FOOTY
OBJ_DATA ball_5 = (100.0,100.0,255.0) 0 FOOTY
OBJ_DATA ball_6 = (50.0,50.0,255.0) 0 FOOTY
OBJ_DATA ball_7 = (80.0,80.0,255.0) 0 FOOTY
OBJ_DATA ball_8 = (150.0,150.0,255.0) 0 FOOTY

CAR_DATA tank1
CAR_DATA tank2
CAR_DATA tank3
CAR_DATA tank4
CAR_DATA tank5
CAR_DATA tank6

CHAR_DATA dude1
CHAR_DATA dude2
CHAR_DATA dude3
CHAR_DATA dude4
CHAR_DATA dude5
CHAR_DATA dude6
CHAR_DATA pedgroup1
CHAR_DATA pedgroup2
CHAR_DATA pedgroup3
CHAR_DATA pedgroup4
CHAR_DATA pedgroup5
CHAR_DATA pedgroup6

PLAYER_PED p1 = (93.00,110.0,255.0) 10 180 // Red
PLAYER_PED p2 = (94.00,110.0,255.0) 09 000 // Orange
PLAYER_PED p3 = (95.00,110.0,2.0) 07 180 // Yellow
PLAYER_PED p4 = (96.00,110.0,2.0) 11 000 // Green
PLAYER_PED p5 = (97.00,110.0,2.0) 13 225 // Blue
PLAYER_PED p6 = (98.00,110.0,2.0) 08 045 // Black

COUNTER loop = 1
COUNTER subloop = 1
COUNTER TanksFull = 0
COUNTER load = 0

LEVELSTART

tank1 = CREATE_CAR (90.0,109.0) 19 0 TANK END
tank2 = CREATE_CAR (91.0,109.0) 19 0 TANK END
tank3 = CREATE_CAR (92.0,109.0) 19 0 TANK END
tank4 = CREATE_CAR (93.0,109.0) 19 0 TANK END
tank5 = CREATE_CAR (94.0,109.0) 19 0 TANK END
tank6 = CREATE_CAR (95.0,109.0) 19 0 TANK END

WHILE ( loop = 1 )

WHILE ( TanksFull = 0 )

++load

pedgroup1 = CREATE_CHAR ( 90.0 , 108.0 , 2.0 ) 1 1 DUMMY END
pedgroup2 = CREATE_CHAR ( 91.0 , 108.0 , 2.0 ) 1 1 DUMMY END
pedgroup3 = CREATE_CHAR ( 92.0 , 108.0 , 2.0 ) 1 1 DUMMY END
pedgroup4 = CREATE_CHAR ( 93.0 , 108.0 , 2.0 ) 1 1 DUMMY END
pedgroup5 = CREATE_CHAR ( 94.0 , 108.0 , 2.0 ) 1 1 DUMMY END
pedgroup6 = CREATE_CHAR ( 95.0 , 108.0 , 2.0 ) 1 1 DUMMY END

ORDER_CHAR_TO_BACKDOOR ( pedgroup1 , tank1 )
ORDER_CHAR_TO_BACKDOOR ( pedgroup2 , tank2 )
ORDER_CHAR_TO_BACKDOOR ( pedgroup3 , tank3 )
ORDER_CHAR_TO_BACKDOOR ( pedgroup4 , tank4 )
ORDER_CHAR_TO_BACKDOOR ( pedgroup5 , tank5 )
ORDER_CHAR_TO_BACKDOOR ( pedgroup6 , tank6 )

IF ( load = 5 )
 SET TanksFull = 1
 DISPLAY_BRIEF (2794)
ENDIF

ENDWHILE

SET_CAR_ROCKETPROOF ( tank1, ON )
SET_CAR_ROCKETPROOF ( tank2, ON )
SET_CAR_ROCKETPROOF ( tank3, ON )
SET_CAR_ROCKETPROOF ( tank4, ON )
SET_CAR_ROCKETPROOF ( tank5, ON )
SET_CAR_ROCKETPROOF ( tank6, ON )
SET_CAR_BULLETPROOF ( tank1, ON )
SET_CAR_BULLETPROOF ( tank2, ON )
SET_CAR_BULLETPROOF ( tank3, ON )
SET_CAR_BULLETPROOF ( tank4, ON )
SET_CAR_BULLETPROOF ( tank5, ON )
SET_CAR_BULLETPROOF ( tank6, ON )
SET_CAR_FLAMEPROOF ( tank1, ON )
SET_CAR_FLAMEPROOF ( tank2, ON )
SET_CAR_FLAMEPROOF ( tank3, ON )
SET_CAR_FLAMEPROOF ( tank4, ON )
SET_CAR_FLAMEPROOF ( tank5, ON )
SET_CAR_FLAMEPROOF ( tank6, ON )

WHILE ( SUBLOOP = 1 )

IF ( IS_CHARACTER_IN_CAR  ( p1, tank4 ))
 dude1 = CREATE_CHAR_INSIDE_CAR ( tank1 ) 8 tank_driver END
 dude2 = CREATE_CHAR_INSIDE_CAR ( tank2 ) 8 tank_driver END
 dude3 = CREATE_CHAR_INSIDE_CAR ( tank3 ) 8 tank_driver END
 dude4 = CREATE_CHAR_INSIDE_CAR ( tank4 ) 8 tank_driver END
 dude5 = CREATE_CHAR_INSIDE_CAR ( tank5 ) 8 tank_driver END
 dude6 = CREATE_CHAR_INSIDE_CAR ( tank6 ) 8 tank_driver END
 PUT_CAR_ON_TRAILER ( tank2 , tank1 )
 PUT_CAR_ON_TRAILER ( tank3 , tank2 )
 PUT_CAR_ON_TRAILER ( tank4 , tank3 )
 PUT_CAR_ON_TRAILER ( tank5 , tank4 )
 PUT_CAR_ON_TRAILER ( tank6 , tank5 )
 /*
 SET_CHAR_SHOOTING_SKILL ( dude1 , crack_shot ) 
 SET_CHAR_SHOOTING_SKILL ( dude2 , crack_shot ) 
 SET_CHAR_SHOOTING_SKILL ( dude3 , crack_shot ) 
 SET_CHAR_SHOOTING_SKILL ( dude4 , crack_shot ) 
 SET_CHAR_SHOOTING_SKILL ( dude5 , crack_shot ) 
 SET_CHAR_BRAVERY_LEVEL ( dude1 , loony ) 
 SET_CHAR_BRAVERY_LEVEL ( dude2 , loony ) 
 SET_CHAR_BRAVERY_LEVEL ( dude3 , loony ) 
 SET_CHAR_BRAVERY_LEVEL ( dude4 , loony ) 
 SET_CHAR_BRAVERY_LEVEL ( dude5 , loony ) 
 SET_CHAR_DRIVE_AGGRESSION ( dude1 , on )
 SET_CHAR_DRIVE_AGGRESSION ( dude2 , on )
 SET_CHAR_DRIVE_AGGRESSION ( dude3 , on )
 SET_CHAR_DRIVE_AGGRESSION ( dude4 , on )
 SET_CHAR_DRIVE_AGGRESSION ( dude5 , on )
 SET_CHAR_TO_USE_CAR_WEAPON ( dude1 , ON )
 SET_CHAR_TO_USE_CAR_WEAPON ( dude2 , ON )
 SET_CHAR_TO_USE_CAR_WEAPON ( dude3 , ON )
 SET_CHAR_TO_USE_CAR_WEAPON ( dude4 , ON )
 SET_CHAR_TO_USE_CAR_WEAPON ( dude5 , ON )
 SET_CHAR_TO_USE_CAR_WEAPON ( dude6 , ON )
 SET_CHAR_TO_STAY_IN_CAR ( dude1 , ON ) 
 SET_CHAR_TO_STAY_IN_CAR ( dude2 , ON ) 
 SET_CHAR_TO_STAY_IN_CAR ( dude3, ON ) 
 SET_CHAR_TO_STAY_IN_CAR ( dude4 , ON ) 
 SET_CHAR_TO_STAY_IN_CAR ( dude5 , ON ) 
 SET_CHAR_TO_STAY_IN_CAR ( dude6 , ON )
 SET_CHAR_OBJECTIVE ( dude1 , KILL_CHAR_ANY_MEANS , p1 )
 SET_CHAR_OBJECTIVE ( dude2 , KILL_CHAR_ANY_MEANS , p1 )  
 SET_CHAR_OBJECTIVE ( dude3 , KILL_CHAR_ANY_MEANS , p1 ) 
 SET_CHAR_OBJECTIVE ( dude4 , KILL_CHAR_ANY_MEANS , p1 ) 
 SET_CHAR_OBJECTIVE ( dude5 , KILL_CHAR_ANY_MEANS , p1 ) 
 SET_CHAR_OBJECTIVE ( dude6 , KILL_CHAR_ANY_MEANS , p1 )
 */
 
 SET_CHAR_OBJECTIVE ( dude1 , FIRE_AT_OBJECT_FROM_VEHICLE , ball_1 ) 
 SET_CHAR_OBJECTIVE ( dude2 , FIRE_AT_OBJECT_FROM_VEHICLE , ball_2 ) 
 SET_CHAR_OBJECTIVE ( dude3 , FIRE_AT_OBJECT_FROM_VEHICLE , ball_3 ) 
 SET_CHAR_OBJECTIVE ( dude4 , FIRE_AT_OBJECT_FROM_VEHICLE , ball_4 ) 
 SET_CHAR_OBJECTIVE ( dude5 , FIRE_AT_OBJECT_FROM_VEHICLE , ball_5 ) 
 //																			SET_CHAR_OBJECTIVE ( dude6 , FIRE_AT_OBJECT_FROM_VEHICLE , ball_6 ) 	
 SET subloop = 0
ENDIF

GIVE_WEAPON ( tank1 , car_machine_gun )
GIVE_WEAPON ( tank2 , car_machine_gun )
GIVE_WEAPON ( tank3 , car_machine_gun )
GIVE_WEAPON ( tank4 , car_machine_gun )
GIVE_WEAPON ( tank5 , car_machine_gun )
GIVE_WEAPON ( tank6 , car_machine_gun )
GIVE_WEAPON ( tank1 , tank_gun )
GIVE_WEAPON ( tank2 , tank_gun )
GIVE_WEAPON ( tank3 , tank_gun )
GIVE_WEAPON ( tank4 , tank_gun )
GIVE_WEAPON ( tank5 , tank_gun )
GIVE_WEAPON ( tank6 , tank_gun )

GIVE_WEAPON (p1, ROCKET_LAUNCHER, 10) 

IF (CHECK_CHARACTER_HEALTH(p2, 0))
  GIVE_WEAPON (p2, ROCKET_LAUNCHER, 99) 
ENDIF

IF (CHECK_CHARACTER_HEALTH(p3, 0))
  GIVE_WEAPON (p3, ROCKET_LAUNCHER, 99) 
ENDIF

IF (CHECK_CHARACTER_HEALTH(p4, 0))
  GIVE_WEAPON (p4, ROCKET_LAUNCHER, 99) 
ENDIF

IF (CHECK_CHARACTER_HEALTH(p5, 0))
  GIVE_WEAPON (p5, ROCKET_LAUNCHER, 99) 
ENDIF

IF (CHECK_CHARACTER_HEALTH(p6, 0))
  GIVE_WEAPON (p6, ROCKET_LAUNCHER, 99) 
ENDIF

ENDWHILE

ENDWHILE

LEVELEND
