Toni

Материал из GTAModding.ru
Перейти к: навигация, поиск

Содержание

toni1

MISSION_START
// *******************************************************************************************
// *******************************************************************************************
// *************************************Toni mission 1****************************************
// ***************************************Laundry day*****************************************
// *******************************************************************************************
// *******************************************************************************************
// *******************************************************************************************
 
// Mission start stuff			
 
GOSUB mission_start_toni1
 
IF HAS_DEATHARREST_BEEN_EXECUTED
	GOSUB mission_toni1_failed
ENDIF
 
GOSUB mission_cleanup_toni1
 
MISSION_END
 
// Variables for mission
 
VAR_INT t1_triad_van1 t1_triad_van2 t1_triad_van3 //t1_triad_van4 // Vehicle for mission
 
VAR_INT blip1_van1 blip2_van2 blip3_van3 //blip4_van4
 
VAR_INT counter1_toni1 // Counts up number of mission vans destroyed
 
VAR_INT vanman1 vanman2 vanman3 in_van1 in_van2 in_van3 //vanman4 in_van4
 
VAR_INT dead_van1 dead_van2 dead_van3 //dead_van4
 
VAR_INT grenade_blip picked_up_grenades
 
VAR_INT triad_hates_you	free_greandes
 
// ***************************************Mission Start*************************************
 
mission_start_toni1:
 
REGISTER_MISSION_GIVEN
flag_player_on_mission = 1
flag_player_on_toni_mission = 1
SCRIPT_NAME toni1
WAIT 0
 
picked_up_grenades = 0
counter1_toni1 = 0
dead_van1 = 0
dead_van2 = 0
dead_van3 = 0
//dead_van4 = 0
in_van1 = 0
in_van2	= 0
in_van3	= 0
//in_van4	= 0
 
/*
IF CAN_PLAYER_START_MISSION Player
	MAKE_PLAYER_SAFE_FOR_CUTSCENE Player
ELSE
	GOTO mission_toni1_failed
ENDIF
 
SET_FADING_COLOUR 0 0 0
 
DO_FADE 1500 FADE_OUT
 
SWITCH_STREAMING OFF
 
PRINT_BIG ( TM1 ) 15000 2 //"Toni Mission 1"	 
*/
 
 
 
LOAD_SPECIAL_CHARACTER 1 tony
LOAD_SPECIAL_MODEL cut_obj1 PLAYERH
LOAD_SPECIAL_MODEL cut_obj2 TONYH
REQUEST_MODEL ind_newrizzos
 
/*
WHILE GET_FADING_STATUS
	WAIT 0
 
ENDWHILE
*/
 
//LOAD_SCENE 1218.4 -314.5 28.9
 
LOAD_ALL_MODELS_NOW
 
WHILE NOT HAS_SPECIAL_CHARACTER_LOADED 1
OR NOT HAS_MODEL_LOADED cut_obj1
OR NOT HAS_MODEL_LOADED cut_obj2
OR NOT HAS_MODEL_LOADED ind_newrizzos
	WAIT 0
 
ENDWHILE
 
LOAD_CUTSCENE t1_tol
SET_CUTSCENE_OFFSET 1218.42 -314.5 28.9
 
CREATE_CUTSCENE_OBJECT PED_PLAYER cs_player
SET_CUTSCENE_ANIM cs_player player
 
CREATE_CUTSCENE_OBJECT PED_SPECIAL1 cs_tony
SET_CUTSCENE_ANIM cs_tony tony
 
CREATE_CUTSCENE_HEAD cs_tony CUT_OBJ2 cs_tonyhead
SET_CUTSCENE_HEAD_ANIM cs_tonyhead tony
 
CREATE_CUTSCENE_HEAD cs_player CUT_OBJ1 cs_playerhead
SET_CUTSCENE_HEAD_ANIM cs_playerhead player
 
CLEAR_AREA 1219.5 -321.1 27.5 1.0 TRUE
SET_PLAYER_COORDINATES player 1219.5 -321.1 26.4
 
SET_PLAYER_HEADING player 180.0
 
CLEAR_AREA 1216.1 -313.0 29.9 10.0 TRUE	//TONIS RESTAURANT
 
DO_FADE 1500 FADE_IN
 
SWITCH_RUBBISH OFF
SWITCH_STREAMING ON
START_CUTSCENE
 
// Displays cutscene text
 
 
GET_CUTSCENE_TIME cs_time
 
WHILE cs_time < 171
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM1_A ) 10000 1 // Mission brief
 
WHILE cs_time < 3769
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM1_B ) 10000 1 // Mission brief
 
WHILE cs_time < 5825
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM1_C ) 10000 1 // Mission brief
 
WHILE cs_time < 8026
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM1_D ) 10000 1 // Mission brief
 
WHILE cs_time < 11500
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
CLEAR_PRINTS
 
WHILE cs_time < 15961
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM1_G ) 10000 1 // Mission brief
 
WHILE cs_time < 21005
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM1_H ) 10000 1 // Mission brief
 
WHILE cs_time < 22997
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM1_I ) 10000 1 // Mission brief
 
WHILE cs_time < 27589
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM1_J ) 10000 1 // Mission brief
 
WHILE cs_time < 29796
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
CLEAR_PRINTS
 
WHILE cs_time < 31666
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
DO_FADE 1500 FADE_OUT
 
WHILE NOT HAS_CUTSCENE_FINISHED
	WAIT 0
 
ENDWHILE
 
CLEAR_PRINTS
 
WHILE GET_FADING_STATUS
	WAIT 0
ENDWHILE
 
REQUEST_MODEL CAR_MRWONGS
REQUEST_MODEL PED_CT_MAN1
SWITCH_RUBBISH ON
CLEAR_CUTSCENE
SET_CAMERA_IN_FRONT_OF_PLAYER
 
 
WAIT 500
 
DO_FADE 1500 FADE_IN
 
UNLOAD_SPECIAL_CHARACTER 1
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ1
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ2
MARK_MODEL_AS_NO_LONGER_NEEDED ind_newrizzos
 
	WHILE NOT HAS_MODEL_LOADED CAR_MRWONGS
	OR NOT HAS_MODEL_LOADED PED_CT_MAN1
		WAIT 0
 
	ENDWHILE
 
// START OF MISSION
 
SWITCH_CAR_GENERATOR gen_car31 0 
 
CREATE_PICKUP_WITH_AMMO WEAPON_GRENADE PICKUP_ONCE 10 1278.8 -81.5 15.1 free_greandes
ADD_SPRITE_BLIP_FOR_PICKUP free_greandes RADAR_SPRITE_WEAPON grenade_blip
 
CREATE_CAR CAR_MRWONGS 854.0 -778.0 -100.0 t1_triad_van1  
CREATE_CHAR_INSIDE_CAR t1_triad_van1 PEDTYPE_CIVMALE PED_CT_MAN1 vanman1
ADD_BLIP_FOR_CAR t1_triad_van1 blip1_van1
SET_CAR_CRUISE_SPEED  t1_triad_van1 17.0
SET_CAR_DRIVING_STYLE t1_triad_van1 0
SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van1 TRUE
SET_CHAR_PERSONALITY vanman1 PEDSTAT_TOUGH_GUY
//SET_CAR_HEALTH t1_triad_van1 600
 
CREATE_CAR CAR_MRWONGS 1020.0 -677.0 -100.0 t1_triad_van2
CREATE_CHAR_INSIDE_CAR t1_triad_van2 PEDTYPE_CIVMALE PED_CT_MAN1 vanman2
ADD_BLIP_FOR_CAR t1_triad_van2 blip2_van2
SET_CAR_CRUISE_SPEED  t1_triad_van2 17.0
SET_CAR_DRIVING_STYLE t1_triad_van2 0
SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van2 TRUE
SET_CHAR_PERSONALITY vanman2 PEDSTAT_GEEK_GUY
//SET_CAR_HEALTH t1_triad_van2 600
 
CREATE_CAR CAR_MRWONGS 904.0 -579.0 -100.0 t1_triad_van3
CREATE_CHAR_INSIDE_CAR t1_triad_van3 PEDTYPE_CIVMALE PED_CT_MAN1 vanman3
ADD_BLIP_FOR_CAR t1_triad_van3 blip3_van3
SET_CAR_CRUISE_SPEED  t1_triad_van3 17.0
SET_CAR_DRIVING_STYLE t1_triad_van3 0
SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van3 TRUE
SET_CHAR_PERSONALITY vanman3 PEDSTAT_TOUGH_GUY
//SET_CAR_HEALTH t1_triad_van3 600
/*
CREATE_CAR CAR_MRWONGS 996.0 -463.0 14.0 t1_triad_van4
CREATE_CHAR_INSIDE_CAR t1_triad_van4 PEDTYPE_CIVMALE PED_CT_MAN1 vanman4
ADD_BLIP_FOR_CAR t1_triad_van4 blip4_van4
SET_CAR_CRUISE_SPEED  t1_triad_van4 17.0
SET_CAR_DRIVING_STYLE t1_triad_van4 0
SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van4 TRUE
SET_CHAR_PERSONALITY vanman4 PEDSTAT_GEEK_GUY
SET_CAR_HEALTH t1_triad_van4 600
*/
 
WHILE NOT counter1_toni1 = 3
	WAIT 0
 
		IF IS_CAR_DEAD t1_triad_van1 
		AND dead_van1 = 0
			REMOVE_BLIP blip1_van1
			dead_van1 = 1
			++ counter1_toni1	
		ENDIF
 
		IF NOT IS_CAR_DEAD t1_triad_van1 
			IF NOT IS_CAR_HEALTH_GREATER t1_triad_van1 999
				IF NOT IS_CHAR_DEAD vanman1
					IF IS_CHAR_IN_CAR vanman1 t1_triad_van1
						SET_CAR_CRUISE_SPEED t1_triad_van1 18.0
						SET_CAR_DRIVING_STYLE t1_triad_van1 2
						SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van1 FALSE
					ENDIF
				ENDIF
			ENDIF
		ENDIF
 
		IF NOT IS_CAR_DEAD t1_triad_van1
			IF IS_PLAYER_IN_CAR player t1_triad_van1
			AND in_van1 = 0
				SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van1 FALSE
				in_van1 = 1
			ENDIF
		ENDIF
 
		IF IS_CAR_DEAD t1_triad_van2
		AND dead_van2 = 0 
			REMOVE_BLIP blip2_van2
			dead_van2 = 1
			++ counter1_toni1
		ENDIF
 
		IF NOT IS_CAR_DEAD t1_triad_van2
			IF NOT IS_CAR_HEALTH_GREATER t1_triad_van2 999
				IF NOT IS_CHAR_DEAD vanman2
					IF IS_CHAR_IN_CAR vanman2 t1_triad_van2
						SET_CAR_CRUISE_SPEED t1_triad_van2 17.0
						SET_CAR_DRIVING_STYLE t1_triad_van2 2
						SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van2 FALSE
					ENDIF
				ENDIF
			ENDIF
		ENDIF
 
		IF NOT IS_CAR_DEAD t1_triad_van2
			IF IS_PLAYER_IN_CAR player t1_triad_van2
			AND in_van2 = 0
				SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van2 FALSE
				in_van2 = 1
			ENDIF
		ENDIF
 
	   	IF IS_CAR_DEAD t1_triad_van3
		AND dead_van3 = 0 
			REMOVE_BLIP blip3_van3
			dead_van3 = 1
			++ counter1_toni1
		ENDIF
 
		IF NOT IS_CAR_DEAD t1_triad_van3
			IF NOT IS_CAR_HEALTH_GREATER t1_triad_van3 999
				IF NOT IS_CHAR_DEAD vanman3
					IF IS_CHAR_IN_CAR vanman3 t1_triad_van3
						SET_CAR_CRUISE_SPEED t1_triad_van3 19.0
						SET_CAR_DRIVING_STYLE t1_triad_van3 2
						SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van3 FALSE
					ENDIF
				ENDIF
			ENDIF
		ENDIF
 
		IF NOT IS_CAR_DEAD t1_triad_van3
			IF IS_PLAYER_IN_CAR player t1_triad_van3
			AND in_van3 = 0
				SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van3 FALSE
				in_van3 = 1
			ENDIF
		ENDIF
		/*
		IF IS_CAR_DEAD t1_triad_van4
		AND dead_van4 = 0 
			REMOVE_BLIP blip4_van4
			dead_van4 = 1
			++ counter1_toni1
		ENDIF
 
		IF NOT IS_CAR_DEAD t1_triad_van4
			IF NOT IS_CAR_HEALTH_GREATER t1_triad_van4 599
				IF NOT IS_CHAR_DEAD vanman4
					IF IS_CHAR_IN_CAR vanman4 t1_triad_van4
						SET_CAR_CRUISE_SPEED t1_triad_van4 20.0
						SET_CAR_DRIVING_STYLE t1_triad_van4 2
						SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van4 FALSE		
					ENDIF
				ENDIF
			ENDIF
		ENDIF
 
		IF NOT IS_CAR_DEAD t1_triad_van4
			IF IS_PLAYER_IN_CAR player t1_triad_van4
			AND in_van4 = 0
				SET_CAR_ONLY_DAMAGED_BY_PLAYER t1_triad_van4 FALSE
				in_van4 = 1
			ENDIF
		ENDIF
		*/
		IF HAS_PICKUP_BEEN_COLLECTED free_greandes
		AND picked_up_grenades = 0
			WAIT 1500
			GET_CONTROLLER_MODE controlmode
			IF controlmode = 0
			OR controlmode = 1
				PRINT_HELP GREN_1
			ENDIF
			IF controlmode = 2
				PRINT_HELP GREN_2
			ENDIF
			IF controlmode = 3
				PRINT_HELP GREN_3
			ENDIF
			picked_up_grenades = 1
		ENDIF
 
ENDWHILE
 
 
 
GOTO mission_toni1_passed 
 
 // Mission toni1 failed
 
mission_toni1_failed:
PRINT_BIG ( M_FAIL ) 5000 1 //"Mission Failed"
RETURN
 
 
 
// mission toni1 passed
 
mission_toni1_passed:
 
flag_toni_mission1_passed = 1
PLAY_MISSION_PASSED_TUNE 1
PRINT_WITH_NUMBER_BIG ( M_PASS ) 20000 5000 1 //"Mission Passed!"
CLEAR_WANTED_LEVEL player
ADD_SCORE player 20000
REGISTER_MISSION_PASSED	TM1
PLAYER_MADE_PROGRESS 1
START_NEW_SCRIPT toni_mission2_loop 
RETURN
 
 
 
// mission cleanup
 
mission_cleanup_toni1:
 
flag_player_on_mission = 0
flag_player_on_toni_mission = 0
REMOVE_BLIP blip1_van1
REMOVE_BLIP blip2_van2
REMOVE_BLIP blip3_van3
//REMOVE_BLIP blip4_van4
REMOVE_BLIP grenade_blip
REMOVE_PICKUP free_greandes
SWITCH_CAR_GENERATOR gen_car31 101
MARK_MODEL_AS_NO_LONGER_NEEDED CAR_MRWONGS
MARK_MODEL_AS_NO_LONGER_NEEDED PED_CT_MAN1
MISSION_HAS_FINISHED
RETURN

toni2

MISSION_START
// *******************************************************************************************
// *******************************************************************************************
// *************************************Toni mission 2****************************************
// **************************************Triad Ambush*****************************************
// *******************************************************************************************
// *******************************************************************************************
// *******************************************************************************************
 
// Mission start stuff
 
GOSUB mission_start_toni2
 
IF HAS_DEATHARREST_BEEN_EXECUTED
	GOSUB mission_toni2_failed
ENDIF
 
GOSUB mission_cleanup_toni2
 
MISSION_END
 
 
// Variables for mission
 
VAR_INT thong1 thong1B thong2 thong2B thong3 thong3B thong_car	// gang members for mission
 
VAR_INT blip1_t2 blip2_t2 thong_blip1 thong_blip1B thong_blip2 thong_blip2B thong_blip3 thong_blip3B
 
VAR_INT thong1_dead thong1B_dead thong2_dead thong2B_dead thong3_dead thong3B_dead thongs_killed thongs_killed_message
 
VAR_INT briefcase_tm2 traid_threat_cleared_T2 
 
// ***************************************Mission Start*************************************
 
mission_start_toni2:
 
REGISTER_MISSION_GIVEN
flag_player_on_mission = 1
flag_player_on_toni_mission = 1
SCRIPT_NAME toni2
WAIT 0
 
thong1_dead = 0
thong1B_dead = 0
thong2_dead = 0
thong2B_dead = 0
thong3_dead = 0
thong3B_dead = 0
thongs_killed = 0
thongs_killed_message = 0
traid_threat_cleared_T2 = 0
 
 
 
LOAD_SPECIAL_MODEL cut_obj1 PLAYERH			
LOAD_SPECIAL_MODEL cut_obj2	NOTE
REQUEST_MODEL ind_newrizzos
 
 
LOAD_ALL_MODELS_NOW
 
WHILE NOT HAS_MODEL_LOADED cut_obj1
OR NOT HAS_MODEL_LOADED cut_obj2
OR NOT HAS_MODEL_LOADED ind_newrizzos
	WAIT 0
 
ENDWHILE
 
LOAD_CUTSCENE T2_TPU
SET_CUTSCENE_OFFSET 1218.42 -314.5 28.9
 
CREATE_CUTSCENE_OBJECT PED_PLAYER cs_player
SET_CUTSCENE_ANIM cs_player player
 
CREATE_CUTSCENE_HEAD cs_player CUT_OBJ1 cs_playerhead
SET_CUTSCENE_HEAD_ANIM cs_playerhead player
 
CREATE_CUTSCENE_OBJECT cut_obj2 cs_note
SET_CUTSCENE_ANIM cs_note NOTE
 
CLEAR_AREA 1219.5 -321.1 27.5 1.0 TRUE
SET_PLAYER_COORDINATES player 1219.5 -321.1 26.4
 
SET_PLAYER_HEADING player 180.0
 
CLEAR_AREA 1216.1 -313.0 29.9 10.0 TRUE	//TONIS RESTAURANT
 
DO_FADE 1500 FADE_IN
 
SWITCH_RUBBISH OFF
SWITCH_STREAMING ON
START_CUTSCENE
 
// Displays cutscene text
 
GET_CUTSCENE_TIME cs_time
 
 
WHILE cs_time < 151 
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM2_A ) 10000 1 
 
WHILE cs_time < 3879
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM2_AA ) 10000 1 
 
WHILE cs_time < 7522
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
PRINT_NOW ( TM2_B ) 10000 1 
 
WHILE cs_time < 10947
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM2_C ) 10000 1 
 
WHILE cs_time < 14507
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM2_D ) 10000 1 
 
WHILE cs_time < 18705
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM2_E ) 10000 1 
 
WHILE cs_time < 22114
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
CLEAR_PRINTS
 
WHILE cs_time < 23333
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
DO_FADE 1500 FADE_OUT
 
WHILE NOT HAS_CUTSCENE_FINISHED
	WAIT 0
 
ENDWHILE
 
CLEAR_PRINTS
 
WHILE GET_FADING_STATUS
	WAIT 0
ENDWHILE
 
SWITCH_RUBBISH ON
CLEAR_CUTSCENE
SET_CAMERA_IN_FRONT_OF_PLAYER
 
WAIT 500
 
DO_FADE 1500 FADE_IN
 
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ1
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ2
MARK_MODEL_AS_NO_LONGER_NEEDED ind_newrizzos
 
 
// START OF MISSION
 
IF IS_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1
	CLEAR_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1
	traid_threat_cleared_T2 = 1
ENDIF
 
SWITCH_CAR_GENERATOR gen_car31 0
 
CREATE_PICKUP briefcase PICKUP_ONCE 865.7 -663.6 14.8 briefcase_tm2
 
ADD_BLIP_FOR_PICKUP	briefcase_tm2 blip1_t2
 
REQUEST_MODEL CAR_BELLYUP
REQUEST_MODEL PED_GANG_TRIAD_A
REQUEST_MODEL PED_GANG_TRIAD_B
 
WHILE NOT HAS_MODEL_LOADED CAR_BELLYUP
OR NOT HAS_MODEL_LOADED PED_GANG_TRIAD_A
OR NOT HAS_MODEL_LOADED PED_GANG_TRIAD_B
	WAIT 0
ENDWHILE
 
 
main_toni2:
 
	WAIT 0
 
WHILE NOT HAS_PICKUP_BEEN_COLLECTED briefcase_tm2
	WAIT 0
 
ENDWHILE
 
REMOVE_BLIP blip1_t2
 
SET_POLICE_IGNORE_PLAYER Player On
SET_PLAYER_CONTROL Player Off
SWITCH_WIDESCREEN ON			
 
				CLEAR_AREA 869.4 -639.0 15.0 1.0 TRUE
				CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A 869.4 -639.0 -100.0 thong1
				GIVE_WEAPON_TO_CHAR thong1 WEAPONTYPE_BASEBALLBAT 1
				SET_CHAR_OBJ_GOTO_COORD_ON_FOOT thong1 869.4 -656.0
 
				CLEAR_AREA 868.5 -637.0 15.0 1.0 TRUE
				CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A 868.5 -637.0 -100.0 thong1B
				SET_CHAR_HEADING thong1B 180.0
				GIVE_WEAPON_TO_CHAR thong1B WEAPONTYPE_PISTOL 200
				//SET_CHAR_OBJ_GOTO_COORD_ON_FOOT thong1B 869.4 -656.0
 
			SET_FIXED_CAMERA_POSITION 869.7 -666.0 16.0 0.0 0.0 0.0
 
			POINT_CAMERA_AT_CHAR thong1 FIXED INTERPOLATION
 
			WAIT 2500
 
				CLEAR_AREA 869.4 -688.0 15.0 1.0 TRUE
				CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 869.4 -688.0 -100.0 thong2
				GIVE_WEAPON_TO_CHAR thong2 WEAPONTYPE_BASEBALLBAT 1
				SET_CHAR_OBJ_GOTO_COORD_ON_FOOT thong2 869.4 -678.0
 
				CLEAR_AREA 868.5 -690.0 15.0 1.0 TRUE
				CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 868.5 -690.0 -100.0 thong2B
				GIVE_WEAPON_TO_CHAR thong2B WEAPONTYPE_PISTOL 100
				//SET_CHAR_OBJ_GOTO_COORD_ON_FOOT thong2B 869.4 -678.0
 
			POINT_CAMERA_AT_CHAR thong2 FIXED INTERPOLATION
 
			WAIT 2500
 
				CLEAR_AREA 892.6 -666.0 15.0 4.0 TRUE
				CREATE_CAR CAR_BELLYUP 892.5 -666.0 -100.0 thong_car
				SET_CAR_HEADING thong_car 180.0
				CREATE_CHAR_INSIDE_CAR thong_car PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A thong3
				CREATE_CHAR_AS_PASSENGER thong_car PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A 0 thong3B
				GIVE_WEAPON_TO_CHAR thong3 WEAPONTYPE_PISTOL 27
				GIVE_WEAPON_TO_CHAR thong3B WEAPONTYPE_BASEBALLBAT 1
				CAR_SET_IDLE thong_car
 
				POINT_CAMERA_AT_CAR thong_car FIXED INTERPOLATION
 
				SET_CHAR_OBJ_LEAVE_CAR thong3B thong_car
 
				WHILE IS_CHAR_IN_CAR thong3B thong_car
				   WAIT 0	
					IF IS_CHAR_DEAD thong3B
					OR IS_CAR_DEAD thong_car
						GOTO next_bit_tm2
					ENDIF
 
				ENDWHILE
 
				IF NOT IS_CHAR_DEAD thong3B
					SET_CHAR_OBJ_GOTO_COORD_ON_FOOT thong3B 886.2 -665.8
				ENDIF
 
			WAIT 2500
 
			next_bit_tm2:
 
 
	SET_PLAYER_CONTROL Player On
	SET_POLICE_IGNORE_PLAYER Player OFF
	SWITCH_WIDESCREEN OFF
	RESTORE_CAMERA
 
			WAIT 0
 
			IF NOT IS_CHAR_DEAD thong1
				SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS thong1 player
				SET_CHAR_THREAT_SEARCH thong1 THREAT_PLAYER1  
			ENDIF
 
			IF NOT IS_CHAR_DEAD thong1B
				//SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS thong1B player
				SET_CHAR_THREAT_SEARCH thong1B THREAT_PLAYER1  
			ENDIF
 
			IF NOT IS_CHAR_DEAD thong2
				SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS thong2 player
				SET_CHAR_THREAT_SEARCH thong2 THREAT_PLAYER1
			ENDIF
 
			IF NOT IS_CHAR_DEAD thong2B
				//SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS thong2B player
				SET_CHAR_THREAT_SEARCH thong2B THREAT_PLAYER1
			ENDIF
 
			IF NOT IS_CHAR_DEAD thong3B
				SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS thong3B player
				SET_CHAR_THREAT_SEARCH thong3B THREAT_PLAYER1
			ENDIF
 
PRINT_NOW ( TM2_3 ) 5000 1	// " Get back to Toni's!"
 
IF NOT IS_CHAR_DEAD thong1
	ADD_BLIP_FOR_CHAR thong1 thong_blip1
ENDIF
IF NOT IS_CHAR_DEAD thong1B
	ADD_BLIP_FOR_CHAR thong1B thong_blip1B
ENDIF
IF NOT IS_CHAR_DEAD thong2
	ADD_BLIP_FOR_CHAR thong2 thong_blip2
ENDIF
IF NOT IS_CHAR_DEAD thong2B
	ADD_BLIP_FOR_CHAR thong2B thong_blip2B
ENDIF
IF NOT IS_CHAR_DEAD thong3
	ADD_BLIP_FOR_CHAR thong3 thong_blip3
ENDIF
IF NOT IS_CHAR_DEAD thong3B
	ADD_BLIP_FOR_CHAR thong3B thong_blip3B
ENDIF
 
WHILE NOT thongs_killed = 6
	WAIT 0
 
		IF IS_CHAR_DEAD thong1
		AND thong1_dead = 0
			thongs_killed ++
			//ADD_SCORE player 500
			REMOVE_BLIP	thong_blip1
			thong1_dead = 1
		ENDIF
 
		IF IS_CHAR_DEAD thong1B
		AND thong1B_dead = 0
			thongs_killed ++
			//ADD_SCORE player 500
			REMOVE_BLIP	thong_blip1B
			thong1B_dead = 1
		ENDIF
 
		IF IS_CHAR_DEAD thong2
		AND thong2_dead = 0
			thongs_killed ++
			//ADD_SCORE player 500
			REMOVE_BLIP	thong_blip2
			thong2_dead = 1
		ENDIF
 
		IF IS_CHAR_DEAD thong2B
		AND thong2B_dead = 0
			thongs_killed ++
			//ADD_SCORE player 500
			REMOVE_BLIP	thong_blip2B
			thong2B_dead = 1
		ENDIF
 
		IF IS_CHAR_DEAD thong3
		AND thong3_dead = 0
			thongs_killed ++
			//ADD_SCORE player 500
			REMOVE_BLIP	thong_blip3
			thong3_dead = 1
		ENDIF
 
		IF IS_CHAR_DEAD thong3B
		AND thong3B_dead = 0
			thongs_killed ++
			//ADD_SCORE player 500
			REMOVE_BLIP	thong_blip3B
			thong3B_dead = 1
		ENDIF
 
		IF NOT IS_PLAYER_IN_AREA_2D player 890.0 -639.3 846.6 -688.0 FALSE
 
			IF NOT IS_CHAR_DEAD thong1B
				SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS thong1B player
				//SET_CHAR_THREAT_SEARCH thong1B THREAT_PLAYER1  
			ENDIF
 
			IF NOT IS_CHAR_DEAD thong2B
				SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS thong2B player
				//SET_CHAR_THREAT_SEARCH thong1B THREAT_PLAYER1  
			ENDIF
 
			IF NOT IS_CHAR_DEAD thong3
				SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS thong3 player
				SET_CHAR_THREAT_SEARCH thong3 THREAT_PLAYER1
			ENDIF
 
		ENDIF
 
ENDWHILE
 
 
	PRINT_NOW ( TM2_1 ) 5000 1	// " Get back to Toni's!"
 
	ADD_BLIP_FOR_COORD 1223.0 -327.0 -100.0 blip2_t2
	//CHANGE_BLIP_DISPLAY blip2_t2 BLIP_ONLY
 
 
WHILE NOT LOCATE_PLAYER_ON_FOOT_3D Player 1219.6 -320.7 27.4 1.0 1.0 2.0 TRUE
	WAIT 0
 
		/*	 
		IF thongs_killed = 6
		AND thongs_killed_message = 0
			PRINT_NOW ( TM2_2 ) 6000 1
			ADD_SCORE player 500
			thongs_killed_message = 1 
		ENDIF 
		*/ 		
ENDWHILE
 
	SET_PLAYER_CONTROL Player OFF
	SET_POLICE_IGNORE_PLAYER Player ON
	SWITCH_WIDESCREEN ON
 
GET_PLAYER_CHAR Player script_controlled_player
SET_CHAR_RUNNING script_controlled_player TRUE
 
SET_FIXED_CAMERA_POSITION 1214.4 -323.9 29.8 0.0 0.0 0.
POINT_CAMERA_AT_POINT 1215.2 -323.4 29.4 JUMP_CUT
 
 
CLEAR_AREA 1219.6 -314.0 29.7 2.0 TRUE
SET_CHAR_OBJ_RUN_TO_COORD script_controlled_player 1219.6 -314.0
 
PLAY_MISSION_PASSED_TUNE 1
PRINT_WITH_NUMBER_BIG ( M_PASS ) 10000 5000 1 //"Mission Passed!"
CLEAR_WANTED_LEVEL player
ADD_SCORE player 10000
 
TIMERB = 0
 
WHILE NOT IS_CHAR_OBJECTIVE_PASSED script_controlled_player
	WAIT 0
 
	IF TIMERB > 7000
		IF NOT IS_CHAR_DEAD	script_controlled_player
			SET_CHAR_COORDINATES script_controlled_player 1219.6 -314.0 -100.0
		ENDIF
	ENDIF
 
ENDWHILE
 
CLEAR_AREA 1219.6 -323.8 26.8 2.0 TRUE
SET_CHAR_OBJ_RUN_TO_COORD script_controlled_player 1219.6 -323.8
 
TIMERB = 0
 
WHILE NOT IS_CHAR_OBJECTIVE_PASSED script_controlled_player
	WAIT 0
 
	IF TIMERB > 7000
		IF NOT IS_CHAR_DEAD	script_controlled_player
			SET_CHAR_COORDINATES script_controlled_player 1219.6 -323.8 -100.0
		ENDIF
	ENDIF
 
ENDWHILE
 
	SET_PLAYER_CONTROL Player ON
	SET_POLICE_IGNORE_PLAYER Player OFF
	SWITCH_WIDESCREEN OFF
	RESTORE_CAMERA_JUMPCUT
	SET_CHAR_RUNNING script_controlled_player FALSE
 
 
GOTO mission_toni2_passed 
 
 
 // Mission toni2 failed
 
mission_toni2_failed:
RETURN
 
 
 
// mission toni2 passed
 
mission_toni2_passed:
 
flag_toni_mission2_passed = 1
//PLAY_MISSION_PASSED_TUNE 1
//PRINT_WITH_NUMBER_BIG ( M_PASS ) 10000 5000 1 //"Mission Passed!"
//CLEAR_WANTED_LEVEL player
//ADD_SCORE player 10000
SET_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1
REGISTER_MISSION_PASSED	TM2
PLAYER_MADE_PROGRESS 1
START_NEW_SCRIPT toni_mission3_loop
RETURN
 
 
 
// mission cleanup
 
mission_cleanup_toni2:
 
flag_player_on_mission = 0
flag_player_on_toni_mission = 0
SWITCH_CAR_GENERATOR gen_car31 101	
REMOVE_BLIP blip1_t2
REMOVE_BLIP blip2_t2
REMOVE_BLIP	thong_blip1
REMOVE_BLIP	thong_blip1B
REMOVE_BLIP	thong_blip2
REMOVE_BLIP	thong_blip2B
REMOVE_BLIP	thong_blip3
REMOVE_BLIP	thong_blip3B
REMOVE_PICKUP briefcase_tm2
MARK_MODEL_AS_NO_LONGER_NEEDED CAR_BELLYUP
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_TRIAD_A
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_TRIAD_B
IF traid_threat_cleared_T2 = 1
	SET_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1
ENDIF	
MISSION_HAS_FINISHED
RETURN

toni3

MISSION_START
// *******************************************************************************************
// *******************************************************************************************
// *************************************Toni mission 3****************************************
// *************************************Pick up the Lads**************************************
// *******************************************************************************************
// *******************************************************************************************
// *******************************************************************************************
 
// Mission start stuff
 
GOSUB mission_start_toni3
 
IF has_deatharrest_been_executed
	GOSUB mission_toni3_failed
ENDIF
 
GOSUB mission_cleanup_toni3
 
MISSION_END
 
// Variables for mission
 
VAR_INT carry_car blip1_t3 blip2_t3 blip3_t3 blip4_t3 blip5_t3 cutscene_seen_flag
 
VAR_INT flag_displayed_horn_message_tm3 flag_displayed_wanted_message_tm3 flag_car_blip_displayed
 
VAR_INT triads1 triads2 triads3 triads4 triads5 triads6 triads7 triads8 triads9 triads10 //triads11 triads12  
 
VAR_INT triad_van1 triad_van2 triad_van3 triad_van4	triad_van5 triad_van6
 
// ***************************************Mission Start*************************************
 
mission_start_toni3:
 
REGISTER_MISSION_GIVEN
flag_player_on_mission = 1
flag_player_on_toni_mission = 1
SCRIPT_NAME toni3
CLEAR_THIS_BIG_PRINT (M_PASS)
WAIT 0
 
cutscene_seen_flag = 0
 
/*
IF CAN_PLAYER_START_MISSION Player
	MAKE_PLAYER_SAFE_FOR_CUTSCENE Player
ELSE
	GOTO mission_toni3_failed
ENDIF
 
SET_FADING_COLOUR 0 0 0
 
DO_FADE 1500 FADE_OUT
 
SWITCH_STREAMING OFF
 
PRINT_BIG ( TM3 ) 15000 2 //"Toni Mission 1"	 
*/
 
 
 
LOAD_SPECIAL_MODEL cut_obj1 PLAYERH
LOAD_SPECIAL_MODEL cut_obj2	NOTE
REQUEST_MODEL ind_newrizzos
 
/*
WHILE GET_FADING_STATUS
	WAIT 0
 
ENDWHILE
*/
 
//LOAD_SCENE 1218.4 -314.5 28.9
 
LOAD_ALL_MODELS_NOW
 
WHILE NOT HAS_MODEL_LOADED cut_obj1
OR NOT HAS_MODEL_LOADED cut_obj2
OR NOT HAS_MODEL_LOADED ind_newrizzos
	WAIT 0
 
ENDWHILE
 
LOAD_CUTSCENE T3_MAS
SET_CUTSCENE_OFFSET 1218.42 -314.5 28.9
 
CREATE_CUTSCENE_OBJECT PED_PLAYER cs_player
SET_CUTSCENE_ANIM cs_player player
 
CREATE_CUTSCENE_HEAD cs_player CUT_OBJ1 cs_playerhead
SET_CUTSCENE_HEAD_ANIM cs_playerhead player
 
CREATE_CUTSCENE_OBJECT cut_obj2 cs_note
SET_CUTSCENE_ANIM cs_note NOTE
 
CLEAR_AREA 1219.5 -321.1 27.5 1.0 TRUE
SET_PLAYER_COORDINATES player 1219.5 -321.1 26.4
 
SET_PLAYER_HEADING player 180.0
 
CLEAR_AREA 1216.1 -313.0 29.9 10.0 TRUE	//TONIS RESTAURANT
 
DO_FADE 1500 FADE_IN
 
//SWITCH_WORLD_PROCESSING OFF
SWITCH_RUBBISH OFF
SWITCH_STREAMING ON
START_CUTSCENE
 
// Displays cutscene text
 
 
GET_CUTSCENE_TIME cs_time
 
/*
WHILE cs_time < 100
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_MA ) 5000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 1000
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_MB ) 5000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 2000
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_MC ) 5000 1 // Pick Frankies Limo at Joeys and take it to him
*/
WHILE cs_time < 3006
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_A ) 10000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 5297
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_B ) 10000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 8661
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_C ) 10000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 12025
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_D ) 10000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 14817
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_E ) 10000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 17107 
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_F ) 10000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 18968
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM3_G ) 10000 1 // Pick Frankies Limo at Joeys and take it to him
 
WHILE cs_time < 19787
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
CLEAR_PRINTS
 
WHILE cs_time < 21666
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
 
DO_FADE 1500 FADE_OUT
 
WHILE NOT HAS_CUTSCENE_FINISHED
	WAIT 0
 
ENDWHILE
 
CLEAR_PRINTS
 
WHILE GET_FADING_STATUS
	WAIT 0
ENDWHILE
 
//SWITCH_WORLD_PROCESSING ON
SWITCH_RUBBISH ON
CLEAR_CUTSCENE
SET_CAMERA_IN_FRONT_OF_PLAYER
 
WAIT 500
 
DO_FADE 1500 FADE_IN
 
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ1
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ2
MARK_MODEL_AS_NO_LONGER_NEEDED ind_newrizzos
 
// START OF MISSION
 
LOAD_SPECIAL_CHARACTER 1 tony
LOAD_SPECIAL_CHARACTER 2 joey2
LOAD_SPECIAL_CHARACTER 3 luigi
 
REQUEST_MODEL CAR_STRETCH
REQUEST_MODEL CAR_BELLYUP
REQUEST_MODEL PED_GANG_TRIAD_A
REQUEST_MODEL PED_GANG_TRIAD_B
 
WHILE NOT HAS_SPECIAL_CHARACTER_LOADED 1
OR NOT HAS_SPECIAL_CHARACTER_LOADED 2
OR NOT HAS_SPECIAL_CHARACTER_LOADED 3
	WAIT 0
ENDWHILE
 
WHILE NOT HAS_MODEL_LOADED CAR_STRETCH
OR NOT HAS_MODEL_LOADED	CAR_BELLYUP
OR NOT HAS_MODEL_LOADED PED_GANG_TRIAD_A
OR NOT HAS_MODEL_LOADED	PED_GANG_TRIAD_B
	WAIT 0
ENDWHILE
/*
WHILE NOT ROTATE_OBJECT joeys_garage_door3 135.0 30.0 FALSE
	WAIT 0
 
ENDWHILE
*/
CREATE_CAR CAR_STRETCH 1187.0 -860.4 14.5 carry_car
SET_CAR_HEADING carry_car 225.0
CHANGE_CAR_COLOUR carry_car CARCOLOUR_BLACK CARCOLOUR_BLACK
SET_CAR_STRONG carry_car TRUE
SET_CAR_PROOFS carry_car TRUE TRUE TRUE TRUE TRUE
//ADD_BLIP_FOR_CAR carry_car blip1_t3
ADD_BLIP_FOR_COORD 1191.7 -870.0 -100.0	blip1_t3
SET_CAN_RESPRAY_CAR carry_car OFF
//SET_RADIO_CHANNEL carry_car 1 -1
 
//PICK UP LIMO AND JOEY
 
//GOTO skip_to_toni3_cut //TEST!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
 
pick_up_joey:
 
	flag_car_blip_displayed = TRUE
 
	IF IS_CAR_DEAD carry_car
		GOTO mission_toni3_failed
	ENDIF
 
 
WHILE NOT LOCATE_PLAYER_ON_FOOT_3D Player 1191.7 -870.0 15.0 1.5 1.5 2.0 TRUE
	WAIT 0
 
	IF IS_CAR_DEAD carry_car
		GOTO mission_toni3_failed
	ENDIF
 
ENDWHILE
 
 
	SET_PLAYER_CONTROL Player Off
	SET_POLICE_IGNORE_PLAYER Player On
	SET_EVERYONE_IGNORE_PLAYER Player ON
	SWITCH_WIDESCREEN ON		
	SET_FADING_COLOUR 0 0 0
	DO_FADE 1000 FADE_OUT
 
	WAIT 1000
	LOAD_SCENE 1190.07 -869.86 13.97
 
	IF IS_PLAYER_PLAYING Player
 
	   	CLEAR_AREA 1190.2 -866.4 14.1 1.0 TRUE
	   	SET_PLAYER_COORDINATES player 1189.5 -867.6 14.1
		SET_PLAYER_HEADING player 36.0	
		SET_FIXED_CAMERA_POSITION 1186.177 -852.455 17.219 0.0 0.0 0.0
		POINT_CAMERA_AT_POINT 1186.077 -853.425 16.995 JUMP_CUT
		GET_PLAYER_CHAR Player script_controlled_player
		SET_CHAR_RUNNING script_controlled_player TRUE
		IF NOT IS_CAR_DEAD carry_car
			SET_CHAR_OBJ_ENTER_CAR_AS_DRIVER script_controlled_player carry_car
		ENDIF
 
		DO_FADE 1000 FADE_IN
		WAIT 1000
	ENDIF
 
	IF IS_CAR_DEAD carry_car
	  	GOTO mission_toni3_failed
	ENDIF
 
	WHILE NOT IS_PLAYER_IN_CAR player carry_car	
		WAIT 0
 
			IF IS_CAR_DEAD carry_car
				GOTO mission_toni3_failed
			ENDIF
 
	ENDWHILE
/*
WHILE NOT ROTATE_OBJECT joeys_garage_door3 45.0 30.0 FALSE
	WAIT 0
 
ENDWHILE
*/
REMOVE_BLIP blip1_t3
SET_RADIO_CHANNEL 1 -1
 
CREATE_CHAR PEDTYPE_SPECIAL PED_SPECIAL2 1179.4 -858.6 14.0 joey
CLEAR_CHAR_THREAT_SEARCH joey
 
	IF IS_CAR_DEAD carry_car
		GOTO mission_toni3_failed
	ENDIF
 
SET_CHAR_OBJ_ENTER_CAR_AS_PASSENGER joey carry_car
 
//SET_FIXED_CAMERA_POSITION 1182.8 -856.1 17.0 0.0 0.0 0.0
//POINT_CAMERA_AT_CHAR joey FIXED INTERPOLATION
 
TIMERB = 0
LOAD_MISSION_AUDIO T3_A
 
	WHILE NOT IS_CHAR_IN_CAR joey carry_car 
		WAIT 0
 
		 	IF IS_CHAR_DEAD joey
				GOTO mission_toni3_failed
			ENDIF
 
			IF IS_CAR_DEAD carry_car
				GOTO mission_toni3_failed
			ENDIF
 
			IF TIMERB > 10000
				IF NOT IS_CHAR_DEAD	joey
				AND NOT IS_CAR_DEAD	carry_car
					//WARP_CHAR_INTO_CAR joey carry_car
					//WARP_CHAR_INTO_CAR_AS_PASSENGER joey carry_car
				ENDIF
			ENDIF
 
	ENDWHILE	
 
WHILE NOT HAS_MISSION_AUDIO_LOADED
	WAIT 0
ENDWHILE
 
PLAY_MISSION_AUDIO
 
SET_CHAR_CANT_BE_DRAGGED_OUT joey TRUE
ADD_BLIP_FOR_COORD 906.2 -426.0 -100.0 blip3_t3
 
//CAR DRIVING OUT OF GARAGE CUT SCENE
 
CLEAR_AREA 1195.0 -870.3 15.0 10.0 TRUE
 
SET_FIXED_CAMERA_POSITION 1200.9 -866.5 19.0 0.0 0.0 0.0
POINT_CAMERA_AT_PLAYER player FIXED JUMP_CUT
 
GET_OBJECT_COORDINATES joeys_garage_door2 joeydoor2_X joeydoor2_Y joeydoor2_Z
GET_OBJECT_COORDINATES joeys_garage_door3 joeydoor3_X joeydoor3_Y joeydoor3_Z
 
joeydoor2_Z = joeydoor2_Z + 3.0
joeydoor3_Z = joeydoor3_Z + 3.0
 
	WHILE NOT SLIDE_OBJECT joeys_garage_door2 joeydoor2_X joeydoor2_Y joeydoor2_Z 0.1 0.1 0.1 FALSE
	OR NOT SLIDE_OBJECT joeys_garage_door3 joeydoor3_X joeydoor3_Y joeydoor3_Z 0.1 0.1 0.1 FALSE
 
		WAIT 0
 
		IF IS_CAR_DEAD carry_car
			GOTO mission_toni3_failed
		ENDIF
 
	ENDWHILE
 
CAR_GOTO_COORDINATES_ACCURATE carry_car 1198.4 -871.1 -100.0
SET_CAR_CRUISE_SPEED carry_car 4.0
SET_CAR_DRIVING_STYLE carry_car 3
 
WHILE NOT LOCATE_CAR_2D carry_car 1198.4 -871.1 2.0 2.0 FALSE
	WAIT 0
 
	IF IS_CAR_DEAD carry_car
		GOTO mission_toni3_failed
	ENDIF
 
ENDWHILE
 
GET_OBJECT_COORDINATES joeys_garage_door2 joeydoor2_X joeydoor2_Y joeydoor2_Z
GET_OBJECT_COORDINATES joeys_garage_door3 joeydoor3_X joeydoor3_Y joeydoor3_Z
 
joeydoor2_Z = joeydoor2_Z - 3.0
joeydoor3_Z = joeydoor3_Z - 3.0
 
	WHILE NOT SLIDE_OBJECT joeys_garage_door2 joeydoor2_X joeydoor2_Y joeydoor2_Z 0.1 0.1 0.1 FALSE
	OR NOT SLIDE_OBJECT joeys_garage_door3 joeydoor3_X joeydoor3_Y joeydoor3_Z 0.1 0.1 0.1 FALSE
		WAIT 0
 
		IF IS_CAR_DEAD carry_car
			GOTO mission_toni3_failed
		ENDIF
 
	ENDWHILE
 
ADD_BLIP_FOR_CAR carry_car blip1_t3
REMOVE_BLIP blip1_t3
 
SWITCH_WIDESCREEN OFF
SET_PLAYER_CONTROL Player On
SET_CAR_STATUS carry_car STATUS_PLAYER
SET_POLICE_IGNORE_PLAYER Player Off
SET_EVERYONE_IGNORE_PLAYER Player OFF
RESTORE_CAMERA_JUMPCUT
SET_CAMERA_IN_FRONT_OF_PLAYER
SET_CAR_PROOFS carry_car FALSE FALSE FALSE FALSE FALSE
flag_displayed_horn_message_tm3 = 0
flag_displayed_wanted_message_tm3 = 0
 
 
//PICK UP LUIGI
 
REMOVE_BLIP blip3_t3
 
pick_up_Luigi:
 
IF IS_CAR_DEAD carry_car
	GOTO mission_toni3_failed
ENDIF
 
flag_car_blip_displayed = TRUE
blob_flag = 1
 
WHILE NOT IS_PLAYER_STOPPED_IN_AREA_3D player 903.8 -423.0 14.0 908.3 -431.0 18.0 blob_flag
OR NOT IS_PLAYER_IN_CAR player carry_car
OR NOT IS_PLAYER_PRESSING_HORN player
OR IS_WANTED_LEVEL_GREATER Player 0    	
 
	WAIT 0
 
	IF IS_CAR_DEAD carry_car
		PRINT_NOW (TM3_A1) 5000 1 //Joeys dead
		GOTO mission_toni3_failed
	ENDIF
 
	IF IS_PLAYER_IN_CAR player carry_car
		IF flag_car_blip_displayed = TRUE
			ADD_BLIP_FOR_COORD 906.2 -426.0 -100.0 blip3_t3
			blob_flag = 1
			REMOVE_BLIP blip1_t3
		flag_car_blip_displayed = FALSE
		ENDIF
	ENDIF
 
	IF NOT IS_PLAYER_IN_CAR player carry_car
		IF flag_car_blip_displayed = FALSE
			ADD_BLIP_FOR_CAR carry_car blip1_t3
			REMOVE_BLIP blip3_t3
			blob_flag = 0
			PRINT_NOW ( IN_VEH ) 5000 1 //"Get back in the carry_car!"
			flag_car_blip_displayed = TRUE
		ENDIF
	ENDIF
 
	IF IS_PLAYER_STOPPED_IN_AREA_IN_CAR_3D player 903.8 -420.2 14.0 908.3 -431.1 18.0 FALSE
		IF IS_PLAYER_IN_CAR player carry_car
			IF IS_WANTED_LEVEL_GREATER player 0
				IF flag_displayed_wanted_message_tm3 = 0
					PRINT_NOW ( WANTED1 ) 5000 1
					flag_displayed_wanted_message_tm3 = 1
				ENDIF
			ELSE
				IF flag_displayed_horn_message_tm3 = 0
					PRINT_NOW ( HORN ) 5000 1
					flag_displayed_horn_message_tm3 = 1
				ENDIF
			ENDIF
		ENDIF
	ENDIF
 
	IF NOT IS_PLAYER_IN_AREA_IN_CAR_3D player 903.8 -420.2 14.0 908.3 -431.1 18.0 FALSE
		IF flag_displayed_horn_message_tm3 = 1
		OR flag_displayed_wanted_message_tm3 = 1
			CLEAR_THIS_PRINT ( WANTED1 )
			CLEAR_THIS_PRINT ( HORN )
			flag_displayed_horn_message_tm3 = 0
			flag_displayed_wanted_message_tm3 = 0
		ENDIF
	ENDIF
 
	IF NOT IS_CAR_HEALTH_GREATER carry_car 600
		WAIT 500
		IF IS_CAR_DEAD carry_car
			PRINT_NOW (TM3_A1) 5000 1 //Joeys dead
			GOTO mission_toni3_failed
		ENDIF
		PRINT_NOW ( TRASH ) 5000 2 //Repair the car!
		REMOVE_BLIP blip1_t3
		REMOVE_BLIP blip3_t3
		ADD_BLIP_FOR_CAR carry_car blip1_t3
		CHANGE_BLIP_DISPLAY blip1_t3 BLIP_ONLY
		flag_car_blip_displayed = TRUE
 
		WHILE NOT IS_CAR_HEALTH_GREATER carry_car 600
			WAIT 0 
 
			IF IS_CAR_DEAD carry_car
				PRINT_NOW (TM3_A1) 5000 1 //Joeys dead
				GOTO mission_toni3_failed
			ENDIF
 
			IF IS_PLAYER_IN_CAR player carry_car
				IF flag_car_blip_displayed = TRUE
					//ADD_BLIP_FOR_COORD 925.0 -359.5 -100.0 blip5_t3
					ADD_SPRITE_BLIP_FOR_COORD 925.0 -359.5 -100.0 RADAR_SPRITE_SPRAY blip5_t3
					REMOVE_BLIP blip1_t3
				flag_car_blip_displayed = FALSE
				ENDIF
			ENDIF
 
			IF NOT IS_PLAYER_IN_CAR player carry_car
				IF flag_car_blip_displayed = FALSE
					ADD_BLIP_FOR_CAR carry_car blip1_t3
					REMOVE_BLIP blip5_t3
					PRINT_NOW ( IN_VEH ) 5000 1 //"Get back in the carry_car!"
					flag_car_blip_displayed = TRUE
				ENDIF
			ENDIF
 
		ENDWHILE
 
			REMOVE_BLIP blip5_t3
			GOTO pick_up_Luigi			
	ENDIF
 
 
ENDWHILE
 
CLEAR_THIS_PRINT ( WANTED1 )
CLEAR_THIS_PRINT ( HORN )
 
IF NOT IS_CAR_DEAD carry_car
	LOCK_CAR_DOORS carry_car CARLOCK_LOCKED_PLAYER_INSIDE
ENDIF
 
WAIT 500
 
SET_PLAYER_CONTROL Player Off
SWITCH_WIDESCREEN ON
SET_POLICE_IGNORE_PLAYER Player ON
SET_EVERYONE_IGNORE_PLAYER Player ON
REMOVE_BLIP blip3_t3
 
IF NOT IS_CAR_DEAD carry_car
	LOCK_CAR_DOORS carry_car CARLOCK_UNLOCKED
ENDIF
 
CLEAR_AREA 897.0 -425.5 14.7 6.0 TRUE
 
//SET_FIXED_CAMERA_POSITION 903.2 -427.7 16.6 0.0 0.0 0.0
//POINT_CAMERA_AT_CHAR luigi FIXED JUMP_CUT
SET_FIXED_CAMERA_POSITION 900.505 -419.672 14.976 0.0 0.0 0.0
POINT_CAMERA_AT_POINT 900.937 -420.566 15.093 JUMP_CUT
 
CREATE_CHAR PEDTYPE_SPECIAL PED_SPECIAL3 897.0 -425.3 14.8 luigi
CLEAR_CHAR_THREAT_SEARCH luigi
 
 
SET_PED_DENSITY_MULTIPLIER 0.0
 
TIMERB = 0
LOAD_MISSION_AUDIO T3_B
 
 SET_CHAR_OBJ_GOTO_COORD_ON_FOOT luigi 901.0 -426.4
 
	WHILE NOT IS_CHAR_OBJECTIVE_PASSED luigi
		WAIT 0
 
		IF IS_CHAR_DEAD luigi
			GOTO mission_toni3_failed
		ENDIF
 
		IF IS_CAR_DEAD carry_car
			GOTO mission_toni3_failed
		ENDIF
 
		IF TIMERB > 12000
			IF NOT IS_CHAR_DEAD	luigi
				SET_CHAR_COORDINATES luigi 901.0 -426.4 -100.0
			ENDIF
		ENDIF
 
	ENDWHILE
 
 
SET_CHAR_OBJ_ENTER_CAR_AS_PASSENGER luigi carry_car
 
	WHILE NOT IS_CHAR_IN_CAR luigi carry_car 
		WAIT 0
 
	 	IF IS_CHAR_DEAD luigi
			GOTO mission_toni3_failed
		ENDIF
 
		IF IS_CAR_DEAD carry_car
			GOTO mission_toni3_failed
		ENDIF
 
	ENDWHILE
 
SET_CHAR_CANT_BE_DRAGGED_OUT luigi TRUE
 
WHILE NOT HAS_MISSION_AUDIO_LOADED
	WAIT 0
ENDWHILE
 
PLAY_MISSION_AUDIO
 
SET_PLAYER_CONTROL Player On
RESTORE_CAMERA_JUMPCUT
SWITCH_WIDESCREEN OFF
SET_POLICE_IGNORE_PLAYER Player OFF
SET_EVERYONE_IGNORE_PLAYER Player OFF
SET_PED_DENSITY_MULTIPLIER 1.0
 
SWITCH_PED_ROADS_ON 824.9 -633.8 13.0 845.3 -693.8 18.0 
SWITCH_ROADS_ON 824.9 -633.8 13.0 845.3 -693.8 18.0
 
flag_displayed_horn_message_tm3 = 0
flag_displayed_wanted_message_tm3 = 0
 
 
//PICK UP TONI
 
pick_up_toni:
 
flag_car_blip_displayed = TRUE
blob_flag = 1
 
IF NOT IS_CAR_DEAD carry_car
	IF NOT IS_PLAYER_IN_CAR player carry_car
		REMOVE_BLIP blip1_t3
		ADD_BLIP_FOR_CAR carry_car blip1_t3
		blob_flag = 0
		PRINT_NOW ( IN_VEH ) 5000 1 //"Get back in the carry_car!"
	ENDIF
ENDIF
 
WHILE NOT IS_PLAYER_STOPPED_IN_AREA_3D player 1197.8 -321.0 24.3 1202.0 -327.5 28.0 blob_flag
OR NOT IS_PLAYER_IN_CAR player carry_car
OR NOT IS_PLAYER_PRESSING_HORN player
OR IS_WANTED_LEVEL_GREATER Player 0
 
	WAIT 0
 
	IF IS_CAR_DEAD carry_car
		PRINT_NOW (TM3_A2) 5000 1 //Joey and Luigi are dead
		GOTO mission_toni3_failed
	ENDIF
 
	IF IS_PLAYER_IN_CAR player carry_car
		IF flag_car_blip_displayed = TRUE
			ADD_BLIP_FOR_COORD 1200.5 -322.5 -100.0 blip4_t3
			blob_flag = 1
			REMOVE_BLIP blip1_t3
		flag_car_blip_displayed = FALSE
		ENDIF
	ENDIF
 
	IF NOT IS_PLAYER_IN_CAR player carry_car
		IF flag_car_blip_displayed = FALSE
			REMOVE_BLIP blip1_t3
			ADD_BLIP_FOR_CAR carry_car blip1_t3
			blob_flag = 0
			REMOVE_BLIP blip4_t3
			PRINT_NOW ( IN_VEH ) 5000 1 //"Get back in the carry_car!"
			flag_car_blip_displayed = TRUE
		ENDIF
	ENDIF
 
	IF IS_PLAYER_STOPPED_IN_AREA_IN_CAR_3D player 1197.8 -321.0 24.3 1202.0 -327.5 28.0 FALSE
		IF IS_PLAYER_IN_CAR player carry_car
 
			IF IS_WANTED_LEVEL_GREATER player 0
				IF flag_displayed_wanted_message_tm3 = 0
					PRINT_NOW ( WANTED1 ) 5000 1
					flag_displayed_wanted_message_tm3 = 1
				ENDIF
			ELSE
				IF flag_displayed_horn_message_tm3 = 0
					PRINT_NOW ( HORN ) 5000 1
					flag_displayed_horn_message_tm3 = 1
				ENDIF
			ENDIF
		ENDIF
	ENDIF
 
	IF NOT IS_PLAYER_IN_AREA_IN_CAR_3D player 1197.8 -321.0 24.3 1202.0 -327.5 28.0 FALSE
		IF flag_displayed_horn_message_tm3 = 1
		OR flag_displayed_wanted_message_tm3 = 1
			CLEAR_THIS_PRINT ( WANTED1 )
			CLEAR_THIS_PRINT ( HORN )
			flag_displayed_horn_message_tm3 = 0
			flag_displayed_wanted_message_tm3 = 0
		ENDIF
	ENDIF
 
	IF NOT IS_CAR_HEALTH_GREATER carry_car 600
		WAIT 500
		IF IS_CAR_DEAD carry_car
			PRINT_NOW (TM3_A2) 5000 1 //Joey and Luigi are dead
			GOTO mission_toni3_failed
		ENDIF
		PRINT_NOW ( TRASH ) 5000 2 //Repair the car!
		REMOVE_BLIP blip1_t3
		REMOVE_BLIP blip4_t3
		ADD_BLIP_FOR_CAR carry_car blip1_t3
		CHANGE_BLIP_DISPLAY blip1_t3 BLIP_ONLY		
		flag_car_blip_displayed = TRUE
 
		WHILE NOT IS_CAR_HEALTH_GREATER carry_car 600
			WAIT 0 
 
			IF IS_CAR_DEAD carry_car
				PRINT_NOW (TM3_A2) 5000 1 //Joey and Luigi are dead
				GOTO mission_toni3_failed
			ENDIF
 
			IF IS_PLAYER_IN_CAR player carry_car
				IF flag_car_blip_displayed = TRUE
					ADD_SPRITE_BLIP_FOR_COORD 925.0 -359.5 -100.0 RADAR_SPRITE_SPRAY blip5_t3
					REMOVE_BLIP blip1_t3
				flag_car_blip_displayed = FALSE
				ENDIF
			ENDIF
 
			IF NOT IS_PLAYER_IN_CAR player carry_car
				IF flag_car_blip_displayed = FALSE
					ADD_BLIP_FOR_CAR carry_car blip1_t3
					REMOVE_BLIP blip5_t3
					PRINT_NOW ( IN_VEH ) 5000 1 //"Get back in the carry_car!"
					flag_car_blip_displayed = TRUE
				ENDIF
			ENDIF
 
		ENDWHILE
 
		REMOVE_BLIP blip5_t3
		GOTO pick_up_toni
	ENDIF
 
 
ENDWHILE
 
CLEAR_THIS_PRINT ( WANTED1 )
CLEAR_THIS_PRINT ( HORN )
 
IF NOT IS_CAR_DEAD carry_car
	LOCK_CAR_DOORS carry_car CARLOCK_LOCKED_PLAYER_INSIDE
ENDIF
 
WAIT 500
 
SET_PLAYER_CONTROL Player Off
SWITCH_WIDESCREEN ON
SET_POLICE_IGNORE_PLAYER Player ON
SET_EVERYONE_IGNORE_PLAYER Player ON
REMOVE_BLIP blip4_t3
 
IF NOT IS_CAR_DEAD carry_car
	LOCK_CAR_DOORS carry_car CARLOCK_UNLOCKED
ENDIF
 
CLEAR_AREA 1213.6 -321.1 26.5 10.0 TRUE
 
CREATE_CHAR PEDTYPE_SPECIAL PED_SPECIAL1 1217.0 -321.1 -100.0 toni
SET_CHAR_HEADING toni 90.0
CLEAR_CHAR_THREAT_SEARCH toni
 
//SET_FIXED_CAMERA_POSITION 1211.6 -323.7 28.0 0.0 0.0 0.0
//POINT_CAMERA_AT_CHAR toni FIXED JUMP_CUT
SET_FIXED_CAMERA_POSITION 1222.214 -328.629 34.454 0.0 0.0 0.0
POINT_CAMERA_AT_POINT 1221.629 -328.046 33.891 JUMP_CUT
 
SET_PED_DENSITY_MULTIPLIER 0.0
/*
TIMERB = 0
 
SET_CHAR_OBJ_GOTO_COORD_ON_FOOT toni 1219.2 -320.9
 
	WHILE NOT IS_CHAR_OBJECTIVE_PASSED toni
		WAIT 0
 
		IF IS_CHAR_DEAD toni
			GOTO mission_toni3_failed
		ENDIF
 
		IF IS_CAR_DEAD carry_car
			GOTO mission_toni3_failed
		ENDIF
 
		IF TIMERB > 12000
			IF NOT IS_CHAR_DEAD	toni
				SET_CHAR_COORDINATES toni 1219.2 -320.9 26.4
			ENDIF
		ENDIF
 
	ENDWHILE
*/
TIMERB = 0
 
LOAD_MISSION_AUDIO T3_C
 
SET_CHAR_OBJ_GOTO_COORD_ON_FOOT toni 1205.5 -321.0
 
	WHILE NOT IS_CHAR_OBJECTIVE_PASSED toni
		WAIT 0
 
		IF IS_CHAR_DEAD toni
			GOTO mission_toni3_failed
		ENDIF
 
		IF IS_CAR_DEAD carry_car
			GOTO mission_toni3_failed
		ENDIF
 
		IF TIMERB > 12000
			IF NOT IS_CHAR_DEAD	toni
				SET_CHAR_COORDINATES toni 1205.5 -321.0 -100.0
			ENDIF
		ENDIF
 
	ENDWHILE
 
 
SET_FIXED_CAMERA_POSITION 1206.2 -326.2 27.0 0.0 0.0 0.0
POINT_CAMERA_AT_CHAR toni FIXED JUMP_CUT
SET_CHAR_OBJ_ENTER_CAR_AS_PASSENGER toni carry_car
 
	WHILE NOT IS_CHAR_IN_CAR toni carry_car 
		WAIT 0
 
	 	IF IS_CHAR_DEAD toni
			GOTO mission_toni3_failed
		ENDIF
 
		IF IS_CAR_DEAD carry_car
			GOTO mission_toni3_failed
		ENDIF
 
	ENDWHILE
 
WHILE NOT HAS_MISSION_AUDIO_LOADED
	WAIT 0
ENDWHILE
 
PLAY_MISSION_AUDIO
 
SET_CHAR_CANT_BE_DRAGGED_OUT toni TRUE
SET_POLICE_IGNORE_PLAYER Player OFF
SET_EVERYONE_IGNORE_PLAYER Player OFF
SET_PED_DENSITY_MULTIPLIER 1.0
 
 
//YET ANOTHER AMBUSH BY THE TRIADS
 
CREATE_CAR CAR_BELLYUP 1193.0 -228.0 -100.0 triad_van1
SET_CAR_HEADING triad_van1 180.0
SET_CAR_DRIVING_STYLE triad_van1 3
SET_CAR_CRUISE_SPEED triad_van1 30.0
SET_CAR_STRONG triad_van1 TRUE
 
			CREATE_CHAR_INSIDE_CAR triad_van1 PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A triads1
			GIVE_WEAPON_TO_CHAR triads1 WEAPONTYPE_PISTOL 100
			SET_CAR_MISSION  triad_van1 2
			SET_CHAR_THREAT_SEARCH triads1 THREAT_PLAYER1
 
			CREATE_CHAR_AS_PASSENGER triad_van1 PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 0 triads2
			GIVE_WEAPON_TO_CHAR triads2 WEAPONTYPE_PISTOL 100
			SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS triads2 Player
			//SET_CHAR_OBJ_DESTROY_CAR triads2 carry_car
			SET_CHAR_THREAT_SEARCH triads2 THREAT_PLAYER1
 
CREATE_CAR CAR_BELLYUP 1275.8 -346.7 -100.0 triad_van2
SET_CAR_HEADING triad_van2 1.0
SET_CAR_DRIVING_STYLE triad_van2 3
SET_CAR_CRUISE_SPEED triad_van2 30.0
SET_CAR_STRONG triad_van2 TRUE
 
			CREATE_CHAR_INSIDE_CAR triad_van2 PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A triads3
			GIVE_WEAPON_TO_CHAR triads3 WEAPONTYPE_PISTOL 100
			SET_CAR_MISSION  triad_van2 2
			SET_CHAR_THREAT_SEARCH triads3 THREAT_PLAYER1
 
			CREATE_CHAR_AS_PASSENGER triad_van2 PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 0 triads4
			GIVE_WEAPON_TO_CHAR triads4 WEAPONTYPE_PISTOL 100
			SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS triads4 Player
			//SET_CHAR_OBJ_DESTROY_CAR triads4 carry_car
			SET_CHAR_THREAT_SEARCH triads4 THREAT_PLAYER1
 
CREATE_CAR CAR_BELLYUP 1342.5 -281.5 -100.0 triad_van3
SET_CAR_HEADING triad_van3 90.0
SET_CAR_DRIVING_STYLE triad_van3 3
SET_CAR_CRUISE_SPEED triad_van3 30.0	
SET_CAR_STRONG triad_van3 TRUE
 
			CREATE_CHAR_INSIDE_CAR triad_van3 PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A triads5
			GIVE_WEAPON_TO_CHAR triads5 WEAPONTYPE_PISTOL 100
			SET_CAR_MISSION  triad_van3 2
			SET_CHAR_THREAT_SEARCH triads5 THREAT_PLAYER1
 
			CREATE_CHAR_AS_PASSENGER triad_van3 PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 0 triads6
			GIVE_WEAPON_TO_CHAR triads6 WEAPONTYPE_PISTOL 100
			SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS triads6 Player
			//SET_CHAR_OBJ_DESTROY_CAR triads6 carry_car
			SET_CHAR_THREAT_SEARCH triads6 THREAT_PLAYER1
 
CREATE_CAR CAR_BELLYUP 1121.6 -345.2 -100.0 triad_van4
SET_CAR_HEADING triad_van4 270.0
SET_CAR_DRIVING_STYLE triad_van4 3
SET_CAR_CRUISE_SPEED triad_van4 30.0	
SET_CAR_STRONG triad_van4 TRUE
 
			CREATE_CHAR_INSIDE_CAR triad_van4 PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A triads7
			GIVE_WEAPON_TO_CHAR triads7 WEAPONTYPE_PISTOL 100
			SET_CAR_MISSION triad_van4 2
			SET_CHAR_THREAT_SEARCH triads7 THREAT_PLAYER1
 
			CREATE_CHAR_AS_PASSENGER triad_van4 PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 0 triads8
			GIVE_WEAPON_TO_CHAR triads8 WEAPONTYPE_PISTOL 100
			SET_CHAR_OBJ_KILL_PLAYER_ANY_MEANS triads8 Player
			//SET_CHAR_OBJ_DESTROY_CAR triads8 carry_car
			SET_CHAR_THREAT_SEARCH triads8 THREAT_PLAYER1
 
//ROAD BLOCK
 
CREATE_CAR CAR_BELLYUP 1383.3 -285.0 -100.0 triad_van5
SET_CAR_HEADING triad_van5 10.0
 
CREATE_CAR CAR_BELLYUP 1383.3 -279.0 -100.0 triad_van6
SET_CAR_HEADING triad_van6 160.0
 
CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_A 1382.1 -281.7 -100.0 triads9
GIVE_WEAPON_TO_CHAR triads9 WEAPONTYPE_PISTOL 100
SET_CHAR_STAY_IN_SAME_PLACE triads9 TRUE
SET_CHAR_OBJ_DESTROY_CAR triads9 carry_car
SET_CHAR_THREAT_SEARCH triads9 THREAT_PLAYER1
 
CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 1384.3 -291.5 -100.0 triads10
GIVE_WEAPON_TO_CHAR triads10 WEAPONTYPE_PISTOL 100
SET_CHAR_STAY_IN_SAME_PLACE triads10 TRUE
SET_CHAR_OBJ_DESTROY_CAR triads10 carry_car
SET_CHAR_THREAT_SEARCH triads10 THREAT_PLAYER1
 
POINT_CAMERA_AT_CAR triad_van1 BEHINDCAR INTERPOLATION
 
WAIT 3000
 
SET_PLAYER_CONTROL Player On
SWITCH_WIDESCREEN OFF
RESTORE_CAMERA_JUMPCUT
 
 
//GO TO FRANKIES
 
get_to_frankies:
 
flag_car_blip_displayed = TRUE
 
IF NOT IS_CAR_DEAD carry_car
	SET_TARGET_CAR_FOR_MISSION_GARAGE frankie_garage carry_car
ENDIF
 
IF NOT IS_CAR_DEAD carry_car
	IF NOT IS_PLAYER_IN_CAR player carry_car
		REMOVE_BLIP blip1_t3
		ADD_BLIP_FOR_CAR carry_car blip1_t3
		blob_flag = 0
		PRINT_NOW ( IN_VEH ) 5000 1 //"Get back in the carry_car!"
	ENDIF
ENDIF
 
WHILE NOT IS_CAR_IN_MISSION_GARAGE frankie_garage
//OR NOT IS_PLAYER_IN_CAR player carry_car
	WAIT 0
 
		IF IS_CAR_DEAD carry_car
			PRINT_NOW (TM3_A3) 5000 1 //Joey, luigi and Toni are dead
			GOTO mission_toni3_failed
		ENDIF
 
		IF IS_PLAYER_IN_CAR player carry_car
			IF flag_car_blip_displayed = TRUE
				ADD_BLIP_FOR_COORD 1428.6 -183.1 -100.0 blip2_t3
				CHANGE_BLIP_DISPLAY blip2_t3 BLIP_ONLY
				REMOVE_BLIP blip1_t3
			flag_car_blip_displayed = FALSE
			ENDIF
		ENDIF
 
		IF NOT IS_PLAYER_IN_CAR player carry_car
			IF flag_car_blip_displayed = FALSE
			ADD_BLIP_FOR_CAR carry_car blip1_t3
			REMOVE_BLIP blip2_t3
			PRINT_NOW ( IN_VEH ) 5000 1 //"Get back in the carry_car!"
			flag_car_blip_displayed = TRUE
			ENDIF
		ENDIF
 
		IF NOT IS_CAR_DEAD triad_van1
			IF IS_CAR_IN_AREA_2D triad_van1 1393.6 -268.2 1427.1 -154.1 FALSE
				IF NOT IS_CHAR_DEAD triads1
				AND NOT IS_CHAR_DEAD triads2
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triads1 Player
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triads2 Player
				ENDIF	
			ENDIF
		ENDIF
 
		IF NOT IS_CAR_DEAD triad_van2
			IF IS_CAR_IN_AREA_2D triad_van2 1393.6 -268.2 1427.1 -154.1 FALSE
				IF NOT IS_CHAR_DEAD triads3
				AND NOT IS_CHAR_DEAD triads4
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triads3 Player
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triads4 Player
				ENDIF	
			ENDIF
		ENDIF
 
		IF NOT IS_CAR_DEAD triad_van3
			IF IS_CAR_IN_AREA_2D triad_van3 1393.6 -268.2 1427.1 -154.1 FALSE
				IF NOT IS_CHAR_DEAD triads5
				AND NOT IS_CHAR_DEAD triads6
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triads5 Player
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triads6 Player
				ENDIF	
			ENDIF
		ENDIF
 
		IF NOT IS_CAR_DEAD triad_van4
			IF IS_CAR_IN_AREA_2D triad_van4 1393.6 -268.2 1427.1 -154.1 FALSE
				IF NOT IS_CHAR_DEAD triads7
				AND NOT IS_CHAR_DEAD triads8
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triads7 Player
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triads8 Player
				ENDIF	
			ENDIF
		ENDIF
 
ENDWHILE
 
 
REMOVE_BLIP blip1_t3
REMOVE_BLIP blip2_t3
SET_FIXED_CAMERA_POSITION 1421.8 -182.5 52.5 0.0 0.0 0.0
POINT_CAMERA_AT_CAR carry_car FIXED INTERPOLATION
 
WAIT 1000
 
SET_POLICE_IGNORE_PLAYER Player OFF
SET_EVERYONE_IGNORE_PLAYER Player OFF
 
IF IS_PLAYER_IN_ANY_CAR player
	WARP_PLAYER_FROM_CAR_TO_COORD player 1454.6 -189.5 55.0
ELSE
	SET_PLAYER_COORDINATES Player 1454.6 -189.5 55.0
ENDIF
 
	IF NOT IS_CHAR_DEAD triads1
		DELETE_CHAR triads1
	ENDIF
	IF NOT IS_CHAR_DEAD triads2
		DELETE_CHAR triads2
	ENDIF
	IF NOT IS_CHAR_DEAD triads3
		DELETE_CHAR triads3
	ENDIF
	IF NOT IS_CHAR_DEAD triads4
		DELETE_CHAR triads4
	ENDIF
	IF NOT IS_CHAR_DEAD triads5
		DELETE_CHAR triads5
	ENDIF
	IF NOT IS_CHAR_DEAD triads6
		DELETE_CHAR triads6
	ENDIF
	IF NOT IS_CHAR_DEAD triads7
		DELETE_CHAR triads7
	ENDIF
	IF NOT IS_CHAR_DEAD triads8
		DELETE_CHAR triads8
	ENDIF
	IF NOT IS_CHAR_DEAD triads9
		DELETE_CHAR triads9
	ENDIF
	IF NOT IS_CHAR_DEAD triads10
		DELETE_CHAR triads10
	ENDIF
	IF NOT IS_CAR_DEAD triad_van1
		DELETE_CAR triad_van1
	ENDIF
	IF NOT IS_CAR_DEAD triad_van2
		DELETE_CAR triad_van2
	ENDIF
	IF NOT IS_CAR_DEAD triad_van3
		DELETE_CAR triad_van3
	ENDIF
	IF NOT IS_CAR_DEAD triad_van4
		DELETE_CAR triad_van4
	ENDIF
	IF NOT IS_CAR_DEAD triad_van5
		DELETE_CAR triad_van5
	ENDIF
	IF NOT IS_CAR_DEAD triad_van6
		DELETE_CAR triad_van6
	ENDIF
 
//skip_to_toni3_cut: //TEST!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
//LOAD_SCENE 1457.776 -185.348 54.925	//TEST!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
//SET_PLAYER_COORDINATES player 1454.6 -189.5 55.0 //TEST!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
 
 
	GET_GAME_TIMER breakout_timer_start
	breakout_diff = 0
 
	WHILE NOT CAN_PLAYER_START_MISSION Player
	AND breakout_diff < 5000	//	if player is not in control after 5 secs do the cutscene anyway
		WAIT 0
 
		IF IS_CAR_DEAD carry_car
			PRINT_NOW (TM3_A3) 5000 1 //Joey, luigi and Toni are dead
			GOTO mission_toni3_failed
		ENDIF
 
		GET_GAME_TIMER breakout_timer							
		breakout_diff = breakout_timer - breakout_timer_start
	ENDWHILE
 
	MAKE_PLAYER_SAFE_FOR_CUTSCENE Player
 
 
// ****************************************START OF CUTSCENE2********************************
 
SET_FADING_COLOUR 0 0 0
 
DO_FADE 1500 FADE_OUT
 
CLEAR_AREA 1427.0 -187.8 50.0 12.0 TRUE
CLEAR_AREA 1444.99 -186.9 56.0 30.0 TRUE
 
SWITCH_RUBBISH OFF
SWITCH_STREAMING OFF
 
LOAD_SPECIAL_CHARACTER 4 frankie
REQUEST_MODEL PED_GANG_MAFIA_B
 
LOAD_SPECIAL_MODEL cut_obj1 PLAYERH
LOAD_SPECIAL_MODEL cut_obj2 FRANKH
LOAD_SPECIAL_MODEL cut_obj3 JOEYH
LOAD_SPECIAL_MODEL cut_obj4 LUIGIH
LOAD_SPECIAL_MODEL cut_obj5 TONYH
REQUEST_MODEL salvsdetail
REQUEST_MODEL swank_inside
REQUEST_MODEL franksclb02
 
WHILE GET_FADING_STATUS
	WAIT 0
 
ENDWHILE
 
LOAD_ALL_MODELS_NOW
 
WHILE NOT HAS_SPECIAL_CHARACTER_LOADED 4
OR NOT HAS_MODEL_LOADED PED_GANG_MAFIA_B
OR NOT HAS_MODEL_LOADED	salvsdetail
OR NOT HAS_MODEL_LOADED swank_inside
OR NOT HAS_MODEL_LOADED	franksclb02
	WAIT 0
ENDWHILE
 
WHILE NOT HAS_MODEL_LOADED cut_obj1
OR NOT HAS_MODEL_LOADED cut_obj2
OR NOT HAS_MODEL_LOADED cut_obj3
OR NOT HAS_MODEL_LOADED cut_obj4
OR NOT HAS_MODEL_LOADED cut_obj5
	WAIT 0
ENDWHILE
 
LOAD_CUTSCENE S0_MAS
SET_CUTSCENE_OFFSET 1457.776 -185.348 54.925
 
CREATE_CUTSCENE_OBJECT PED_PLAYER cs_player
SET_CUTSCENE_ANIM cs_player player
 
CREATE_CUTSCENE_OBJECT PED_SPECIAL1 cs_tony
SET_CUTSCENE_ANIM cs_tony tony
 
CREATE_CUTSCENE_OBJECT PED_SPECIAL2 cs_joey
SET_CUTSCENE_ANIM cs_joey joey2
 
CREATE_CUTSCENE_OBJECT PED_SPECIAL3 cs_luigi
SET_CUTSCENE_ANIM cs_luigi luigi
 
CREATE_CUTSCENE_OBJECT PED_SPECIAL4 cs_frankie
SET_CUTSCENE_ANIM cs_frankie frankie
 
CREATE_CUTSCENE_OBJECT PED_GANG_MAFIA_B cs_mafia
SET_CUTSCENE_ANIM cs_mafia gang02
 
CREATE_CUTSCENE_HEAD cs_player cut_obj1 cs_playerhead
SET_CUTSCENE_HEAD_ANIM cs_playerhead player
 
CREATE_CUTSCENE_HEAD cs_frankie cut_obj2 cs_frankiehead
SET_CUTSCENE_HEAD_ANIM cs_frankiehead frank
 
CREATE_CUTSCENE_HEAD cs_joey cut_obj3 cs_joeyhead
SET_CUTSCENE_HEAD_ANIM cs_joeyhead joey
 
CREATE_CUTSCENE_HEAD cs_luigi cut_obj4 cs_luigihead
SET_CUTSCENE_HEAD_ANIM cs_luigihead luigi
 
CREATE_CUTSCENE_HEAD cs_tony cut_obj5 cs_tonyhead
SET_CUTSCENE_HEAD_ANIM cs_tonyhead tony
 
//SET_PLAYER_COORDINATES player 1455.2 -186.8 55.0
 
SET_PLAYER_HEADING player 341.0
 
DO_FADE 1500 FADE_IN
 
SWITCH_STREAMING ON
START_CUTSCENE
 
GET_CUTSCENE_TIME cs_time
 
WHILE cs_time < 416 
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_H 10000 1
 
WHILE cs_time < 3252
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_I 10000 1
 
WHILE cs_time < 4866
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_J 10000 1
 
WHILE cs_time < 5839
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_K 10000 1
 
WHILE cs_time < 10201
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_L 10000 1
 
WHILE cs_time < 13769
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_M 10000 1
 
WHILE cs_time < 17654
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_N 10000 1
 
WHILE cs_time < 18718
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_N2 10000 1
 
WHILE cs_time < 19529
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_O 10000 1
 
WHILE cs_time < 21673
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_P 10000 1
 
WHILE cs_time < 25525
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_Q 10000 1
 
WHILE cs_time < 26615
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_R 10000 1
 
WHILE cs_time < 29462
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_S 10000 1
 
WHILE cs_time < 32814
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_T 10000 1
 
WHILE cs_time < 35855
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_U 10000 1
 
WHILE cs_time < 37787
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_V 10000 1
 
WHILE cs_time < 44707
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW TM3_W 10000 1
 
WHILE cs_time < 47837
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
CLEAR_PRINTS
 
WHILE cs_time < 48666
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
DO_FADE 1500 FADE_OUT
WHILE GET_FADING_STATUS
WAIT 0
ENDWHILE
 
WHILE NOT HAS_CUTSCENE_FINISHED
WAIT 0
ENDWHILE
 
CLEAR_PRINTS
 
DO_FADE 0 FADE_OUT
 
CLEAR_CUTSCENE
 
DO_FADE 0 FADE_OUT
 
UNLOAD_SPECIAL_CHARACTER 1
UNLOAD_SPECIAL_CHARACTER 2
UNLOAD_SPECIAL_CHARACTER 3
UNLOAD_SPECIAL_CHARACTER 4
MARK_MODEL_AS_NO_LONGER_NEEDED cut_obj1
MARK_MODEL_AS_NO_LONGER_NEEDED cut_obj2
MARK_MODEL_AS_NO_LONGER_NEEDED cut_obj3
MARK_MODEL_AS_NO_LONGER_NEEDED cut_obj4
MARK_MODEL_AS_NO_LONGER_NEEDED cut_obj5
MARK_MODEL_AS_NO_LONGER_NEEDED salvsdetail
MARK_MODEL_AS_NO_LONGER_NEEDED swank_inside
MARK_MODEL_AS_NO_LONGER_NEEDED franksclb02
 
WAIT 500
 
DO_FADE 1500 FADE_IN
 
 
 
 
GOTO mission_toni3_passed  
 
 
 
 // Mission toni3 failed
 
mission_toni3_failed:
PRINT_BIG ( M_FAIL ) 5000 1 //"Mission Failed"
RETURN
 
 
 
// mission toni3 passed
 
mission_toni3_passed:
 
flag_toni_mission3_passed = 1
PLAY_MISSION_PASSED_TUNE 1
PRINT_WITH_NUMBER_BIG ( M_PASS ) 15000 5000 1 //"Mission Passed!"
CLEAR_WANTED_LEVEL player
ADD_SCORE player 15000
REGISTER_MISSION_PASSED	TM3
PLAYER_MADE_PROGRESS 1
START_NEW_SCRIPT frankie_mission1_loop
REMOVE_BLIP	luigi_contact_blip
REMOVE_BLIP	joey_contact_blip
REMOVE_BLIP	toni_contact_blip
REMOVE_BLIP frankie_contact_blip
ADD_SPRITE_BLIP_FOR_CONTACT_POINT 1455.7 -187.3 -100.0 RADAR_SPRITE_SAL frankie_contact_blip
//WAIT 3000						  
//WARP_PLAYER_FROM_CAR_TO_COORD player 1455.7 -187.3 -100.0
DELETE_CAR carry_car				 
RESTORE_CAMERA_JUMPCUT
SET_CAMERA_BEHIND_PLAYER
RETURN
 
 
 
// mission cleanup
 
mission_cleanup_toni3:
 
flag_player_on_mission = 0
flag_player_on_toni_mission = 0
REMOVE_BLIP blip1_t3
REMOVE_BLIP blip2_t3
REMOVE_BLIP blip3_t3
REMOVE_BLIP blip4_t3
REMOVE_BLIP blip5_t3
REMOVE_CHAR_ELEGANTLY joey
REMOVE_CHAR_ELEGANTLY luigi
REMOVE_CHAR_ELEGANTLY toni
MARK_MODEL_AS_NO_LONGER_NEEDED CAR_STRETCH
MARK_MODEL_AS_NO_LONGER_NEEDED CAR_BELLYUP
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_TRIAD_A
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_TRIAD_B
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_MAFIA_B
UNLOAD_SPECIAL_CHARACTER 1
UNLOAD_SPECIAL_CHARACTER 2
UNLOAD_SPECIAL_CHARACTER 3
UNLOAD_SPECIAL_CHARACTER 4
SET_TARGET_CAR_FOR_MISSION_GARAGE frankie_garage -1
CLEAR_THIS_PRINT ( IN_VEH )
MISSION_HAS_FINISHED
RETURN

toni4

MISSION_START
// *******************************************************************************************
// *******************************************************************************************
// *************************************Toni mission 4****************************************
// ********************************Kill the Triad Warlords************************************
// *******************************************************************************************
// *******************************************************************************************
// *******************************************************************************************
 
// Mission start stuff
 
GOSUB mission_start_toni4
 
IF HAS_DEATHARREST_BEEN_EXECUTED
	GOSUB mission_toni4_failed
ENDIF
 
GOSUB mission_cleanup_toni4
 
MISSION_END
 
// Variables for mission
 
VAR_INT blip1_tm4 blip2_tm4 blip3_tm4 triad1_can_leg_it triad2_can_leg_it triad3_can_leg_it
 
VAR_INT	triad_head1 triad_head2 triad_head3 warlords_dead 
 
VAR_INT triad_grunt1 triad_grunt1B triad_grunt2 triad_grunt2B triad_grunt3 triad_grunt3B
 
VAR_INT grunts1_been_created_before grunts2_been_created_before grunts3_been_created_before 
 
VAR_INT mafia_goon1 mafia_goon2	been_in_fish_factory clear_triads_threats
 
VAR_INT grabbed_peds_before	Fishbastards audio_played_tm4
 
VAR_INT char_already_dead1 char_already_dead2 char_already_dead3
 
VAR_INT pay_back_for_traids1 pay_back_for_traids2 pay_back_for_traids3
 
// ***************************************Mission Start*************************************
 
mission_start_toni4:
 
REGISTER_MISSION_GIVEN
flag_player_on_mission = 1
flag_player_on_toni_mission = 1
SCRIPT_NAME toni4
WAIT 0
 
grunts1_been_created_before = 0
grunts2_been_created_before = 0
grunts3_been_created_before = 0
grabbed_peds_before = 0
been_in_fish_factory = 0 
audio_played_tm4 = 0
triad1_can_leg_it = 0
triad1_can_leg_it = 0
triad1_can_leg_it = 0
pay_back_for_traids1 = 0
pay_back_for_traids2 = 0
pay_back_for_traids3 = 0
 
 
 
REQUEST_MODEL PED_GANG_MAFIA_A
REQUEST_MODEL PED_GANG_MAFIA_B
REQUEST_MODEL ind_newrizzos
LOAD_SPECIAL_MODEL cut_obj1 PLAYERH
LOAD_SPECIAL_MODEL cut_obj2	NOTE
 
LOAD_ALL_MODELS_NOW
 
WHILE NOT HAS_MODEL_LOADED cut_obj1
OR NOT HAS_MODEL_LOADED cut_obj2
OR NOT HAS_MODEL_LOADED PED_GANG_MAFIA_A
OR NOT HAS_MODEL_LOADED PED_GANG_MAFIA_B
OR NOT HAS_MODEL_LOADED ind_newrizzos
	WAIT 0
 
ENDWHILE
 
CREATE_CHAR PEDTYPE_GANG_MAFIA PED_GANG_MAFIA_B 1216.4 -309.9 -100.0 mafia_goon1
CREATE_CHAR PEDTYPE_GANG_MAFIA PED_GANG_MAFIA_A 1215.9 -311.2 29.0 mafia_goon2
 
	IF NOT IS_CHAR_DEAD mafia_goon1
	AND NOT IS_CHAR_DEAD mafia_goon2
 
		GIVE_WEAPON_TO_CHAR mafia_goon1 WEAPONTYPE_UZI 300
		SET_CHAR_THREAT_SEARCH mafia_goon1 THREAT_COP
		SET_CHAR_THREAT_SEARCH mafia_goon1 THREAT_GANG_TRIAD
		SET_CHAR_RUNNING mafia_goon1 TRUE
		TURN_CHAR_TO_FACE_CHAR mafia_goon1 mafia_goon2
		SET_CHARS_CHATTING mafia_goon1 mafia_goon2 24000
 
		GIVE_WEAPON_TO_CHAR mafia_goon2 WEAPONTYPE_UZI 300
		SET_CHAR_THREAT_SEARCH mafia_goon2 THREAT_COP
		SET_CHAR_THREAT_SEARCH mafia_goon2 THREAT_GANG_TRIAD
		SET_CHAR_RUNNING mafia_goon2 TRUE
		TURN_CHAR_TO_FACE_CHAR mafia_goon2 mafia_goon1
 
	ENDIF
 
 
LOAD_CUTSCENE T4_TAT
SET_CUTSCENE_OFFSET 1218.42 -314.5 28.9
 
CREATE_CUTSCENE_OBJECT PED_PLAYER cs_player
SET_CUTSCENE_ANIM cs_player player
 
CREATE_CUTSCENE_HEAD cs_player CUT_OBJ1 cs_playerhead
SET_CUTSCENE_HEAD_ANIM cs_playerhead player
 
CREATE_CUTSCENE_OBJECT cut_obj2 cs_note
SET_CUTSCENE_ANIM cs_note NOTE
 
CLEAR_AREA 1219.6 -323.0 25.6 1.0 TRUE
SET_PLAYER_COORDINATES player 1219.6 -323.0 25.6
 
SET_PLAYER_HEADING player 180.0
 
CLEAR_AREA 1216.1 -313.0 29.9 10.0 TRUE	//TONIS RESTAURANT
 
DO_FADE 1500 FADE_IN
 
//SWITCH_WORLD_PROCESSING OFF
SWITCH_RUBBISH OFF
SWITCH_STREAMING ON
START_CUTSCENE
 
// Displays cutscene text
 
 
GET_CUTSCENE_TIME cs_time
 
 
WHILE cs_time < 82
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM4_A ) 10000 1 // Mission brief
 
WHILE cs_time < 2415
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM4_A2 ) 10000 1 // Mission brief
 
WHILE cs_time < 4420
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM4_B ) 10000 1 // Mission brief
 
WHILE cs_time < 7629
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM4_C ) 10000 1 // Mission brief
 
WHILE cs_time < 11110
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM4_D ) 10000 1 // Mission brief
 
WHILE cs_time < 13283
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM4_E ) 10000 1 // Mission brief
 
WHILE cs_time < 18058
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM4_F ) 10000 1 // Mission brief
 
WHILE cs_time < 21248
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM4_G ) 10000 1 // Mission brief
 
WHILE cs_time < 24000
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
DO_FADE 1500 FADE_OUT
 
WHILE NOT HAS_CUTSCENE_FINISHED
	WAIT 0
 
ENDWHILE
 
CLEAR_PRINTS
 
WHILE GET_FADING_STATUS
	WAIT 0
ENDWHILE
 
//SWITCH_WORLD_PROCESSING ON
SWITCH_RUBBISH ON
CLEAR_CUTSCENE
SET_CAMERA_IN_FRONT_OF_PLAYER
 
IF NOT IS_CHAR_DEAD	mafia_goon1
AND NOT IS_CHAR_DEAD mafia_goon2
	SET_CHARS_CHATTING mafia_goon1 mafia_goon2 0
ENDIF
 
GIVE_WEAPON_TO_PLAYER Player WEAPONTYPE_SHOTGUN 20
SET_CURRENT_PLAYER_WEAPON Player WEAPONTYPE_SHOTGUN
 
IF NOT IS_CHAR_DEAD	mafia_goon1
AND NOT IS_CHAR_DEAD mafia_goon2
	SET_CHAR_COORDINATES mafia_goon1 1220.2 -321.8 26.4
	SET_CHAR_COORDINATES mafia_goon2 1219.0 -321.3 26.4
ENDIF
 
WAIT 500
 
DO_FADE 1500 FADE_IN
 
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ1
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ2
MARK_MODEL_AS_NO_LONGER_NEEDED ind_newrizzos
 
REQUEST_MODEL PED_GANG_TRIAD_A
REQUEST_MODEL PED_GANG_TRIAD_B
 
	WHILE NOT HAS_MODEL_LOADED PED_GANG_TRIAD_A
	OR NOT HAS_MODEL_LOADED PED_GANG_TRIAD_B
		WAIT 0
	ENDWHILE
 
SET_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1 //TEST
 
warlords_dead = 0
triads_spot_you = 0
clear_triads_threats = 0
 
IF NOT IS_CHAR_DEAD mafia_goon1
	SET_PLAYER_AS_LEADER mafia_goon1 player
ENDIF
 
IF NOT IS_CHAR_DEAD mafia_goon2  
	SET_PLAYER_AS_LEADER mafia_goon2 player
ENDIF
 
 
    SETUP_ZONE_PED_INFO LITTLEI DAY	  (15) 500 250 0 (0 0 0 0) 0
    SETUP_ZONE_PED_INFO	LITTLEI	NIGHT ( 8) 500 250 0 (0 0 0 0) 0
 
    SETUP_ZONE_PED_INFO CHINA DAY   (30) 350 600 0 (0 0 0 0) 0  
    SETUP_ZONE_PED_INFO CHINA NIGHT (30) 350 600 0 (0 0 0 0) 0
 
 
// START MISSION
 
//RESET_NUM_OF_MODELS_KILLED_BY_PLAYER
 
CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 906.4 -541.4 14.4 triad_head1 //Fish warhouse (Chinatown)
GIVE_WEAPON_TO_CHAR triad_head1 WEAPONTYPE_UZI 80
SET_CHAR_HEADING triad_head1 109.0
ADD_BLIP_FOR_CHAR triad_head1 blip1_tm4
ADD_ARMOUR_TO_CHAR triad_head1 100
//SET_CHAR_THREAT_SEARCH triad_head1 THREAT_GANG_MAFIA
SET_CHAR_THREAT_SEARCH triad_head1 THREAT_PLAYER1
SET_CHAR_ONLY_DAMAGED_BY_PLAYER triad_head1 TRUE
SET_CHAR_STAY_IN_SAME_PLACE triad_head1 TRUE
 
CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 968.6 -682.2 14.3 triad_head2 //Market place
GIVE_WEAPON_TO_CHAR triad_head2 WEAPONTYPE_UZI 80
ADD_BLIP_FOR_CHAR triad_head2 blip2_tm4
ADD_ARMOUR_TO_CHAR triad_head2 100
//SET_CHAR_THREAT_SEARCH triad_head2 THREAT_GANG_MAFIA
SET_CHAR_THREAT_SEARCH triad_head2 THREAT_PLAYER1
SET_CHAR_ONLY_DAMAGED_BY_PLAYER triad_head2 TRUE
SET_CHAR_STAY_IN_SAME_PLACE triad_head2 TRUE
 
CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 968.3 -1136.8 15.0 triad_head3 //Fish factory
GIVE_WEAPON_TO_CHAR triad_head3 WEAPONTYPE_UZI 80
SET_CHAR_HEADING triad_head3 38.0
ADD_BLIP_FOR_CHAR triad_head3 blip3_tm4
ADD_ARMOUR_TO_CHAR triad_head3 100
//SET_CHAR_THREAT_SEARCH triad_head3 THREAT_GANG_MAFIA
SET_CHAR_THREAT_SEARCH triad_head3 THREAT_PLAYER1
SET_CHAR_ONLY_DAMAGED_BY_PLAYER triad_head3 TRUE
SET_CHAR_STAY_IN_SAME_PLACE triad_head3 TRUE
 
char_already_dead1 = 0
char_already_dead2 = 0
char_already_dead3 = 0
 
	LOAD_MISSION_AUDIO T4_A
 
	WHILE NOT HAS_MISSION_AUDIO_LOADED
		WAIT 0
	ENDWHILE
 
WHILE NOT warlords_dead = 3
	WAIT 0
 
		IF IS_CHAR_DEAD triad_head1 
		AND char_already_dead1 = 0
			REMOVE_BLIP blip1_tm4 
			warlords_dead ++
			char_already_dead1 = 1
		ENDIF  	   		   	 		 
 
		IF IS_CHAR_DEAD triad_head2 
		AND char_already_dead2 = 0 
			REMOVE_BLIP blip2_tm4
			warlords_dead ++
			char_already_dead2 = 1
		ENDIF
 
		IF IS_CHAR_DEAD triad_head3 
		AND char_already_dead3 = 0
			REMOVE_BLIP blip3_tm4 
			warlords_dead ++
			char_already_dead3 = 1
		ENDIF
 
		IF IS_PLAYER_IN_ZONE Player PORT_W
		AND has_player_been_at_fish_before = 1
		AND clear_triads_threats = 0
 
			IF NOT IS_CHAR_DEAD	fish_triad1
				CLEAR_CHAR_THREAT_SEARCH fish_triad1
			ENDIF
			IF NOT IS_CHAR_DEAD	fish_triad2
				CLEAR_CHAR_THREAT_SEARCH fish_triad2
			ENDIF
			IF NOT IS_CHAR_DEAD	fish_triad3
				CLEAR_CHAR_THREAT_SEARCH fish_triad3
			ENDIF
			IF NOT IS_CHAR_DEAD	fish_triad4
				CLEAR_CHAR_THREAT_SEARCH fish_triad4
			ENDIF
			IF NOT IS_CHAR_DEAD	fish_triad5
				CLEAR_CHAR_THREAT_SEARCH fish_triad5
			ENDIF
			IF NOT IS_CHAR_DEAD	fish_triad6
				CLEAR_CHAR_THREAT_SEARCH fish_triad6
			ENDIF
 
			CLEAR_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1
 
			clear_triads_threats = 1
		ENDIF
 
		IF IS_PLAYER_IN_ZONE player FISHFAC	
			IF triads_spot_you = 0
				IF NOT IS_PLAYER_IN_ANY_CAR Player
 
					IF NOT IS_CHAR_DEAD	fish_triad1
						SET_CHAR_THREAT_SEARCH fish_triad1 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad2
						SET_CHAR_THREAT_SEARCH fish_triad2 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad3
						SET_CHAR_THREAT_SEARCH fish_triad3 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad4
						SET_CHAR_THREAT_SEARCH fish_triad4 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad5
						SET_CHAR_THREAT_SEARCH fish_triad5 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad6
						SET_CHAR_THREAT_SEARCH fish_triad6 THREAT_PLAYER1
					ENDIF
 
					triads_spot_you = 1
				ENDIF
 
				IF IS_CHAR_DEAD	fish_triad1
				OR IS_CHAR_DEAD fish_triad2
				OR IS_CHAR_DEAD fish_triad3
				OR IS_CHAR_DEAD fish_triad4
				OR IS_CHAR_DEAD fish_triad5
				OR IS_CHAR_DEAD fish_triad6
 
					IF NOT IS_CHAR_DEAD	fish_triad1
						SET_CHAR_THREAT_SEARCH fish_triad1 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad2
						SET_CHAR_THREAT_SEARCH fish_triad2 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad3
						SET_CHAR_THREAT_SEARCH fish_triad3 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad4
						SET_CHAR_THREAT_SEARCH fish_triad4 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad5
						SET_CHAR_THREAT_SEARCH fish_triad5 THREAT_PLAYER1
					ENDIF
					IF NOT IS_CHAR_DEAD	fish_triad6
						SET_CHAR_THREAT_SEARCH fish_triad6 THREAT_PLAYER1
					ENDIF
 
					triads_spot_you = 1
				ENDIF
			ENDIF
		ENDIF
 
		IF IS_PLAYER_IN_ZONE player CHINA
		AND audio_played_tm4 = 0
			PLAY_MISSION_AUDIO
			audio_played_tm4 = 1
   	 	ENDIF
 
		IF grunts1_been_created_before = 0
			IF NOT IS_CHAR_DEAD triad_head1
				IF LOCATE_PLAYER_ANY_MEANS_CHAR_2D Player triad_head1 80.0 80.0 FALSE 
 
					CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 907.4 -542.4 14.4 triad_grunt1
					SET_CHAR_HEADING triad_grunt1 180.0 
					GIVE_WEAPON_TO_CHAR triad_grunt1 WEAPONTYPE_UZI 80
					SET_CHAR_AS_LEADER triad_grunt1 triad_head1
					SET_CHAR_THREAT_SEARCH triad_grunt1 THREAT_PLAYER1
 
					CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 907.4 -542.4 14.4 triad_grunt1B
					SET_CHAR_HEADING triad_grunt1B 160.0 
					GIVE_WEAPON_TO_CHAR triad_grunt1B WEAPONTYPE_UZI 80
					SET_CHAR_AS_LEADER triad_grunt1B triad_head1
					SET_CHAR_THREAT_SEARCH triad_grunt1B THREAT_PLAYER1
 
					SET_CHAR_ONLY_DAMAGED_BY_PLAYER triad_head1 FALSE
					grunts1_been_created_before = 1
 
				ENDIF
			ENDIF
		ENDIF
 
		IF NOT IS_CHAR_DEAD	triad_head1
			IF LOCATE_PLAYER_ANY_MEANS_CHAR_2D Player triad_head1 30.0 30.0 FALSE
			AND triad1_can_leg_it = 0
				SET_CHAR_STAY_IN_SAME_PLACE triad_head1 FALSE
				triad1_can_leg_it = 1
			ENDIF
		ENDIF
 
		IF grunts2_been_created_before = 0
			IF NOT IS_CHAR_DEAD triad_head2
				IF LOCATE_PLAYER_ANY_MEANS_CHAR_2D Player triad_head2 80.0 80.0 FALSE
 
					CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 965.6 -680.2 14.3 triad_grunt2 
					GIVE_WEAPON_TO_CHAR triad_grunt2 WEAPONTYPE_UZI 80
					SET_CHAR_AS_LEADER triad_grunt2 triad_head2
					SET_CHAR_THREAT_SEARCH triad_grunt2 THREAT_PLAYER1
 
					CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 965.5 -683.0 14.3 triad_grunt2B 
					GIVE_WEAPON_TO_CHAR triad_grunt2B WEAPONTYPE_UZI 80
					SET_CHAR_AS_LEADER triad_grunt2B triad_head2
					SET_CHAR_THREAT_SEARCH triad_grunt2B THREAT_PLAYER1
 
					SET_CHAR_ONLY_DAMAGED_BY_PLAYER triad_head2 FALSE
					grunts2_been_created_before	= 1
 
				ENDIF
			ENDIF
		ENDIF
 
		IF NOT IS_CHAR_DEAD	triad_head2
			IF LOCATE_PLAYER_ANY_MEANS_CHAR_2D Player triad_head2 30.0 30.0 FALSE
			AND triad2_can_leg_it = 0
				SET_CHAR_STAY_IN_SAME_PLACE triad_head2 FALSE
				triad2_can_leg_it = 1
			ENDIF
		ENDIF
 
		IF grunts3_been_created_before = 0
			IF NOT IS_CHAR_DEAD triad_head3
				IF LOCATE_PLAYER_ANY_MEANS_CHAR_2D Player triad_head3 80.0 80.0 FALSE
 
 					CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 967.1 -1134.0 15.0 triad_grunt3 
					GIVE_WEAPON_TO_CHAR triad_grunt3 WEAPONTYPE_UZI 80
					SET_CHAR_AS_LEADER triad_grunt3 triad_head3
					SET_CHAR_THREAT_SEARCH triad_grunt3 THREAT_PLAYER1
					SET_CHAR_ONLY_DAMAGED_BY_PLAYER triad_head3 FALSE
 
					CREATE_CHAR PEDTYPE_GANG_TRIAD PED_GANG_TRIAD_B 966.1 -1129.0 15.0 triad_grunt3B 
					GIVE_WEAPON_TO_CHAR triad_grunt3B WEAPONTYPE_UZI 80
					SET_CHAR_AS_LEADER triad_grunt3B triad_head3
					SET_CHAR_THREAT_SEARCH triad_grunt3B THREAT_PLAYER1
 
					SET_CHAR_ONLY_DAMAGED_BY_PLAYER triad_head3 FALSE
					grunts3_been_created_before = 1
 
				ENDIF
			ENDIF
		ENDIF
 
		IF grunts1_been_created_before = 1
		AND pay_back_for_traids1 = 0
			IF IS_CHAR_DEAD	triad_grunt1
			OR IS_CHAR_DEAD triad_grunt1B
			OR IS_CHAR_DEAD triad_head1
 
				IF NOT IS_CHAR_DEAD triad_grunt1
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_grunt1 Player		
				ENDIF
				IF NOT IS_CHAR_DEAD triad_grunt1B
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_grunt1B Player		
				ENDIF
				IF NOT IS_CHAR_DEAD triad_head1
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_head1 Player		
				ENDIF
 
				pay_back_for_traids1 = 1
			ENDIF
		ENDIF
 
		IF grunts2_been_created_before = 1
		AND pay_back_for_traids2 = 0
			IF IS_CHAR_DEAD	triad_grunt2
			OR IS_CHAR_DEAD triad_grunt2B
			OR IS_CHAR_DEAD triad_head2
 
				IF NOT IS_CHAR_DEAD triad_grunt2
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_grunt2 Player		
				ENDIF
				IF NOT IS_CHAR_DEAD triad_grunt2B
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_grunt2B Player		
				ENDIF
				IF NOT IS_CHAR_DEAD triad_head2
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_head2 Player		
				ENDIF
 
				pay_back_for_traids2 = 1
			ENDIF
		ENDIF
 
		IF grunts3_been_created_before = 1
		AND pay_back_for_traids3 = 0
			IF IS_CHAR_DEAD	triad_grunt3
			OR IS_CHAR_DEAD triad_grunt3B
			OR IS_CHAR_DEAD triad_head3
 
				IF NOT IS_CHAR_DEAD triad_grunt3
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_grunt3 Player		
				ENDIF
				IF NOT IS_CHAR_DEAD triad_grunt3B
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_grunt3B Player		
				ENDIF
				IF NOT IS_CHAR_DEAD triad_head3
					SET_CHAR_OBJ_KILL_PLAYER_ON_FOOT triad_head3 Player		
				ENDIF
 
				pay_back_for_traids3 = 1
			ENDIF
		ENDIF
 
		IF NOT IS_CHAR_DEAD	triad_head3
			IF LOCATE_PLAYER_ANY_MEANS_CHAR_2D Player triad_head3 30.0 30.0 FALSE
			AND triad3_can_leg_it = 0
				SET_CHAR_STAY_IN_SAME_PLACE triad_head3 FALSE
				triad3_can_leg_it = 1
			ENDIF
		ENDIF
 
		IF NOT IS_CHAR_DEAD mafia_goon1
			IF NOT LOCATE_PLAYER_ANY_MEANS_CHAR_2D Player mafia_goon1 120.0 120.0 FALSE
		   		DELETE_CHAR mafia_goon1
		   	ELSE
		   		IF NOT IS_CHAR_IN_PLAYERS_GROUP mafia_goon1 Player
					SET_PLAYER_AS_LEADER mafia_goon1 player
				ENDIF
		   	ENDIF	
		ENDIF
 
		IF NOT IS_CHAR_DEAD mafia_goon2
			IF NOT LOCATE_PLAYER_ANY_MEANS_CHAR_2D Player mafia_goon2 120.0 120.0 FALSE
		   		DELETE_CHAR mafia_goon2
		   	ELSE
		   		IF NOT IS_CHAR_IN_PLAYERS_GROUP mafia_goon2 Player
					SET_PLAYER_AS_LEADER mafia_goon2 player
				ENDIF
		   	ENDIF	
		ENDIF
 
		IF IS_PLAYER_IN_AREA_3D player 1025.2 -1108.4 12.0 1009.2 -1098.4 16.0 FALSE
			IF NOT IS_PLAYER_IN_MODEL player CAR_BELLYUP
			AND NOT IS_PLAYER_IN_MODEL player CAR_TRASHMASTER
				IF IS_PLAYER_IN_AREA_3D player 1015.6 -1100.5 12.0 1009.2 -1108.1 16.0 FALSE
				AND been_in_fish_factory = 0
					been_in_fish_factory = 1
				ENDIF
 
				IF been_in_fish_factory = 0	
					PRINT_NOW ( TM4_GAT ) 5000 1 // Need Belly-up
				ENDIF	
			ENDIF 
		ENDIF
 
ENDWHILE
 
 
 
GOTO mission_toni4_passed
 
 
 // Mission toni4 failed
 
mission_toni4_failed:
 
    SETUP_ZONE_PED_INFO CHINA DAY   (20) 0 300 0 (0 0 0 0) 20 //China town 
    SETUP_ZONE_PED_INFO CHINA NIGHT (10) 0 400 0 (0 0 0 0) 10 
 
RETURN
 
 
 
// mission toni4 passed
 
mission_toni4_passed:
 
flag_toni_mission4_passed = 1
PLAY_MISSION_PASSED_TUNE 1
PRINT_WITH_NUMBER_BIG ( M_PASS ) 30000 5000 1 //"Mission Passed!"
CLEAR_WANTED_LEVEL player
ADD_SCORE player 30000
REGISTER_MISSION_PASSED TM4
PLAYER_MADE_PROGRESS 1
START_NEW_SCRIPT toni_mission5_loop
 	SETUP_ZONE_PED_INFO CHINA DAY   (20) 0 200 0 (0 0 0 0) 20 //China town 
    SETUP_ZONE_PED_INFO CHINA NIGHT (10) 0 300 0 (0 0 0 0) 10
RETURN
 
 
 
// mission cleanup
 
mission_cleanup_toni4:
 
flag_player_on_mission = 0
flag_player_on_toni_mission = 0
REMOVE_BLIP blip1_tm4
REMOVE_BLIP blip2_tm4
REMOVE_BLIP blip3_tm4
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_MAFIA_A
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_MAFIA_B
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_TRIAD_A
MARK_MODEL_AS_NO_LONGER_NEEDED PED_GANG_TRIAD_B
//UNLOAD_SPECIAL_CHARACTER 1
SET_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1 //TEST
SETUP_ZONE_PED_INFO LITTLEI DAY	  (17) 300 0 0 (0 0 0 0) 20	//St Marks
SETUP_ZONE_PED_INFO	LITTLEI	NIGHT (11) 400 0 0 (0 0 0 0) 10
MISSION_HAS_FINISHED
RETURN

toni5

MISSION_START
// *******************************************************************************************
// *******************************************************************************************
// *************************************Toni mission 5****************************************
// **********************************Destroy Fish Factory*************************************
// *******************************************************************************************
// *******************************************************************************************
// *******************************************************************************************
 
// Mission start stuff
 
GOSUB mission_start_toni5
 
IF HAS_DEATHARREST_BEEN_EXECUTED
	GOSUB mission_toni5_failed
ENDIF
 
GOSUB mission_cleanup_toni5
 
MISSION_END
 
// Variables for mission
 
VAR_INT blip1_tm5 blip2_tm5 
 
VAR_INT explosive_truck countdown_tm5 
 
VAR_INT fish_factory_destroyed triads_spot_you
 
VAR_INT flag_car_blip_displayed_tm5	explosive_truck_health explosive_truck_health2
 
VAR_INT fish_fire2 fish_fire3 fish_fire4 fish_fire5 fish_fire6 fish_fire7
 
VAR_INT debris1_tm5 debris2_tm5 debris3_tm5 debris4_tm5 debris5_tm5 debris6_tm5 debris7_tm5 debris8_tm5 debris9_tm5 debris10_tm5
 
VAR_FLOAT truck_x truck_y truck_z  
 
// ***************************************Mission Start*************************************
 
mission_start_toni5:
 
REGISTER_MISSION_GIVEN
flag_player_on_mission = 1
flag_player_on_toni_mission = 1
SCRIPT_NAME toni5
WAIT 0
 
 
LOAD_SPECIAL_CHARACTER 1 tony
LOAD_SPECIAL_MODEL cut_obj1 PLAYERH
LOAD_SPECIAL_MODEL cut_obj2 TONYH
REQUEST_MODEL ind_newrizzos
 
LOAD_ALL_MODELS_NOW
 
WHILE NOT HAS_SPECIAL_CHARACTER_LOADED 1  
OR NOT HAS_MODEL_LOADED cut_obj1
OR NOT HAS_MODEL_LOADED cut_obj2
OR NOT HAS_MODEL_LOADED ind_newrizzos
	WAIT 0
 
ENDWHILE
 
 
LOAD_CUTSCENE t5_bf
SET_CUTSCENE_OFFSET 1218.42 -314.5 28.9
 
CREATE_CUTSCENE_OBJECT PED_PLAYER cs_player
SET_CUTSCENE_ANIM cs_player player
 
CREATE_CUTSCENE_OBJECT PED_SPECIAL1 cs_tony
SET_CUTSCENE_ANIM cs_tony tony
 
CREATE_CUTSCENE_HEAD cs_tony CUT_OBJ2 cs_tonyhead
SET_CUTSCENE_HEAD_ANIM cs_tonyhead tony
 
CREATE_CUTSCENE_HEAD cs_player CUT_OBJ1 cs_playerhead
SET_CUTSCENE_HEAD_ANIM cs_playerhead player
 
CLEAR_AREA 1219.5 -321.1 27.5 1.0 TRUE
SET_PLAYER_COORDINATES player 1219.5 -321.1 26.4
 
SET_PLAYER_HEADING player 180.0
 
CLEAR_AREA 1216.1 -313.0 29.9 10.0 TRUE	//TONIS RESTAURANT
 
DO_FADE 1500 FADE_IN
 
SWITCH_RUBBISH OFF
SWITCH_STREAMING ON
START_CUTSCENE
 
// Displays cutscene text
 
GET_CUTSCENE_TIME cs_time
 
WHILE cs_time < 1350
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_B ) 10000 1 // Mission brief
 
WHILE cs_time < 3169
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_C ) 10000 1 // Mission brief
 
WHILE cs_time < 5730
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_D ) 10000 1 // Mission brief
 
WHILE cs_time < 7755
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_E ) 10000 1 // Mission brief
 
WHILE cs_time < 12490
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_F ) 10000 1 // Mission brief
 
WHILE cs_time < 17220
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_G ) 10000 1 // Mission brief
 
WHILE cs_time < 21330
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_H ) 10000 1 // Mission brief
 
WHILE cs_time < 24141
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_I ) 10000 1 // Mission brief
 
WHILE cs_time < 25817
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
PRINT_NOW ( TM5_J ) 10000 1 // Mission brief
 
WHILE cs_time < 28632
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
CLEAR_PRINTS
 
WHILE cs_time < 30000
	WAIT 0
	GET_CUTSCENE_TIME cs_time
ENDWHILE
 
DO_FADE 1500 FADE_OUT
 
WHILE NOT HAS_CUTSCENE_FINISHED
	WAIT 0
 
ENDWHILE
 
CLEAR_PRINTS
 
WHILE GET_FADING_STATUS
	WAIT 0
ENDWHILE
 
SWITCH_RUBBISH ON
CLEAR_CUTSCENE
SET_CAMERA_IN_FRONT_OF_PLAYER
 
WAIT 500
 
DO_FADE 1500 FADE_IN 
 
UNLOAD_SPECIAL_CHARACTER 1
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ1
MARK_MODEL_AS_NO_LONGER_NEEDED CUT_OBJ2
MARK_MODEL_AS_NO_LONGER_NEEDED ind_newrizzos
 
REQUEST_MODEL CAR_TRASHMASTER
 
WHILE NOT HAS_MODEL_LOADED CAR_TRASHMASTER
	WAIT 0
ENDWHILE
 
 
triads_spot_you = 0
clear_triads_threats = 0
 
// START MISSION
 
CREATE_CAR CAR_TRASHMASTER 1314.0 -106.0 -100.0 explosive_truck
SET_CAR_PROOFS explosive_truck TRUE TRUE FALSE FALSE TRUE
ARM_CAR_WITH_BOMB explosive_truck CARBOMB_TIMED
 
fish_factory_destroyed = 0
 
ADD_BLIP_FOR_CAR explosive_truck blip1_tm5
 
	WHILE NOT IS_PLAYER_IN_CAR player explosive_truck
		WAIT 0
 
		IF IS_CAR_DEAD explosive_truck
			GOTO mission_toni5_failed
		ENDIF		
 
		GOSUB triad_AI
 
		IF NOT IS_CAR_HEALTH_GREATER explosive_truck 860
		AND NOT IS_CAR_IN_AREA_3D explosive_truck 961.0 -1112.5 12.5 969.5 -1122.8 15.0 FALSE
		    EXPLODE_CAR explosive_truck
			GOTO mission_toni5_failed
		ENDIF
 
	ENDWHILE 
 
 
countdown_tm5 = 151000
DISPLAY_ONSCREEN_TIMER countdown_tm5
 
GET_CAR_HEALTH explosive_truck explosive_truck_health
DISPLAY_ONSCREEN_COUNTER_WITH_STRING explosive_truck_health COUNTER_DISPLAY_BAR (DAM)
explosive_truck_health2 = 1000 - explosive_truck_health
	IF explosive_truck_health2 > 100
		explosive_truck_health2 = 100
	ENDIF
explosive_truck_health = explosive_truck_health2
 
flag_car_blip_displayed_tm5 = TRUE
blob_flag = 1
 
toni5_wait_for_van:
WAIT 0
 
		IF IS_CAR_DEAD explosive_truck
			GOTO mission_toni5_failed
		ENDIF
 
	WHILE NOT IS_CAR_STOPPED_IN_AREA_3D explosive_truck 961.0 -1112.5 12.5 969.5 -1122.8 15.0 blob_flag
		WAIT 0
 
			IF IS_CAR_DEAD explosive_truck
				ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE truck_x truck_y truck_z 0.0 0.0 0.0 4.0 0 0 0 4000
				GOTO mission_toni5_failed
			ENDIF
 
			GOSUB triad_AI
 
			GOSUB Truck_health
 
			GET_CAR_COORDINATES explosive_truck truck_x truck_y truck_z
 
			IF IS_PLAYER_IN_CAR player explosive_truck
				IF flag_car_blip_displayed_tm5 = TRUE
					ADD_BLIP_FOR_COORD 965.0 -1117.0 -100.0 blip2_tm5
					blob_flag = 1
					REMOVE_BLIP blip1_tm5
				flag_car_blip_displayed_tm5 = FALSE
				ENDIF
			ENDIF
 
			IF NOT IS_PLAYER_IN_CAR player explosive_truck
				IF flag_car_blip_displayed_tm5 = FALSE
				ADD_BLIP_FOR_CAR explosive_truck blip1_tm5
				blob_flag = 0
				REMOVE_BLIP blip2_tm5
				PRINT_NOW ( IN_VEH ) 5000 1 //"Get back in the car!"
				flag_car_blip_displayed_tm5 = TRUE
				ENDIF
			ENDIF
 
			IF NOT IS_CAR_HEALTH_GREATER explosive_truck 900
			AND NOT IS_CAR_IN_AREA_3D explosive_truck 961.0 -1112.5 12.5 969.5 -1122.8 15.0 FALSE
			    EXPLODE_CAR explosive_truck
				ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE truck_x truck_y truck_z 0.0 0.0 0.0 4.0 0 0 0 4000
				GOTO mission_toni5_failed
			ENDIF
 
			IF countdown_tm5 = 0
			AND NOT IS_CAR_IN_AREA_3D explosive_truck 961.0 -1112.5 12.5 969.5 -1122.8 15.0 FALSE
				EXPLODE_CAR explosive_truck
				ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE truck_x truck_y truck_z 0.0 0.0 0.0 4.0 0 0 0 4000
				GOTO mission_toni5_failed
			ENDIF
 
	ENDWHILE
 
REQUEST_MODEL fshfctry_dstryd
PRINT_NOW ( JM1_3 ) 5000 2 //Activate the car bomb then get out of there!
FORCE_WEATHER WEATHER_SUNNY
 
		IF IS_CAR_DEAD explosive_truck
			PRINT_NOW ( WRECKED ) 5000 1
			GOTO mission_toni5_failed
		ENDIF
 
	WHILE NOT IS_EXPLOSION_IN_AREA EXPLOSION_CAR 961.0 -1112.5 12.5 969.5 -1122.8 15.0
		WAIT 0
 
			IF IS_CAR_DEAD explosive_truck
				ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE truck_x truck_y truck_z 0.0 0.0 0.0 4.0 0 0 0 4000
				GOTO explosion
			ENDIF
 
			GOSUB triad_AI
 
			GOSUB Truck_health
 
			GET_CAR_COORDINATES explosive_truck truck_x truck_y truck_z
 
			IF NOT IS_CAR_IN_AREA_3D explosive_truck 961.0 -1112.5 12.5 969.5 -1122.8 15.0 FALSE
				GOTO toni5_wait_for_van
			ENDIF
 
			IF NOT IS_PLAYER_IN_CAR player explosive_truck
		   	AND NOT IS_CAR_ARMED_WITH_BOMB explosive_truck CARBOMB_TIMEDACTIVE
		 		PRINT_NOW ( JM1_5 ) 5000 1 // The vehicle bomb's not set!
			ENDIF
 
			IF NOT IS_CAR_HEALTH_GREATER explosive_truck 900
			    EXPLODE_CAR explosive_truck
				ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE truck_x truck_y truck_z 0.0 0.0 0.0 4.0 0 0 0 4000
				GOTO explosion
			ENDIF
 
			IF countdown_tm5 = 0
				EXPLODE_CAR explosive_truck
				ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE truck_x truck_y truck_z 0.0 0.0 0.0 4.0 0 0 0 4000
				GOTO explosion
			ENDIF
 
	ENDWHILE
 
explosion:
 
 
	CLEAR_ONSCREEN_TIMER countdown_tm5
 
	SET_PLAYER_CONTROL Player Off
	SWITCH_WIDESCREEN ON
	SET_POLICE_IGNORE_PLAYER Player On
	SET_EVERYONE_IGNORE_PLAYER Player ON
 
	SET_FIXED_CAMERA_POSITION 940.279 -1136.787 16.550 0.0 0.0 0.0
	POINT_CAMERA_AT_POINT 941.065 -1136.169 16.522 JUMP_CUT
 
	REMOVE_BLIP blip1_tm5
	REMOVE_BLIP blip2_tm5
	WAIT 300
 
	SHAKE_CAM 300
    //ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE 965.8 -1111.9 15.5 0.0 0.0 0.0 4.0 0 0 0 4000
	ADD_EXPLOSION 965.8 -1111.9 15.5 EXPLOSION_HELI
	//ADD_ONE_OFF_SOUND 965.8 -1111.9 15.5 sound_test_1
	START_SCRIPT_FIRE 966.0 -1111.8 13.8 fish_Fire3
 
	//ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE 966.0 -1123.0 15.4 0.0 0.0 0.0 4.0 0 0 0 4000
	ADD_EXPLOSION 966.0 -1123.0 15.4 EXPLOSION_HELI
	//ADD_ONE_OFF_SOUND 966.0 -1123.0 15.4 sound_test_1
	WAIT 600
 
		SHAKE_CAM 400
		ADD_EXPLOSION 970.0 -1119.0 16.0 EXPLOSION_HELI
		WAIT 300
 
	SHAKE_CAM 300
	ADD_EXPLOSION 985.0 -1119.0 14.0 EXPLOSION_HELI
	WAIT 400
 
		SHAKE_CAM 400
		ADD_EXPLOSION 985.0 -1120.0 20.0 EXPLOSION_HELI
		WAIT 200
 
	SHAKE_CAM 300
	SET_FIXED_CAMERA_POSITION 960.5 -1094.0 21.1 0.0 0.0 0.0
	POINT_CAMERA_AT_POINT 961.2 -1094.7 20.8 JUMP_CUT
 
	ADD_EXPLOSION 969.2 -1104.0 18.3 EXPLOSION_HELI
	WAIT 300
 
		SHAKE_CAM 400
		ADD_EXPLOSION 968.4 -1119.2 17.4 EXPLOSION_HELI
		WAIT 200
 
	SHAKE_CAM 300
	ADD_EXPLOSION 979.4 -1103.9 18.9 EXPLOSION_HELI
	WAIT 300
 
		SHAKE_CAM 400
		ADD_EXPLOSION 976.0 -1108.3 21.4 EXPLOSION_HELI
		WAIT 300
 
	SHAKE_CAM 300
	ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE 969.8 -1104.9 18.7 0.0 0.0 0.0 5.0 0 0 0 5000
	//ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE 986.3 -1103.4 14.7 0.0 0.0 0.0 4.0 0 0 0 4000
	ADD_EXPLOSION 972.7 -1102.2 18.5 EXPLOSION_HELI
	ADD_EXPLOSION 986.3 -1103.4 14.7 EXPLOSION_HELI
	CREATE_OBJECT fish01 972.7 -1103.6 20.6 debris1_tm5
	CREATE_OBJECT fish01 972.7 -1103.2 20.6 debris2_tm5
	CREATE_OBJECT fish01 978.8 -1107.2 21.6 debris3_tm5
	CREATE_OBJECT fish01 979.8 -1105.2 21.6 debris4_tm5
	SET_OBJECT_DYNAMIC debris1_tm5 TRUE
	SET_OBJECT_DYNAMIC debris2_tm5 TRUE
	SET_OBJECT_DYNAMIC debris3_tm5 TRUE
	SET_OBJECT_DYNAMIC debris4_tm5 TRUE
	SET_OBJECT_VELOCITY debris1_tm5 -10.0 6.0 18.0
	SET_OBJECT_VELOCITY debris2_tm5 8.0 7.0 16.0
	SET_OBJECT_VELOCITY debris3_tm5 -7.0 10.0 14.0
	SET_OBJECT_VELOCITY debris4_tm5 9.0 6.0 15.0
	ADD_ONE_OFF_SOUND 969.8 -1104.9 18.7 sound_test_1
	//ADD_ONE_OFF_SOUND 971.7 -1101.2 17.5 sound_test_1
 
	WAIT 400
	SHAKE_CAM 500
 
	ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE 974.2 -1129.8 19.5 0.0 0.0 0.0 5.0 0 0 0 5000
	//ADD_MOVING_PARTICLE_EFFECT POBJECT_FIREBALL_AND_SMOKE 973.6 -1128.8 19.6 0.0 0.0 0.0 4.0 0 0 0 4000
	ADD_EXPLOSION 982.0 -1102.8 17.4 EXPLOSION_HELI
	ADD_EXPLOSION 973.6 -1128.8 19.6 EXPLOSION_HELI
		CREATE_OBJECT fish01 982.0 -1103.8 20.4 debris5_tm5
		CREATE_OBJECT fish01 982.0 -1103.0 20.4 debris6_tm5
		CREATE_OBJECT fish01 983.0 -1112.0 20.4 debris7_tm5
		CREATE_OBJECT fish01 985.0 -1108.0 19.4 debris8_tm5
		CREATE_OBJECT fish01 977.0 -1113.0 21.4 debris9_tm5
		CREATE_OBJECT fish01 976.0 -1115.0 21.4 debris10_tm5
		SET_OBJECT_DYNAMIC debris5_tm5 TRUE
		SET_OBJECT_DYNAMIC debris6_tm5 TRUE
		SET_OBJECT_DYNAMIC debris7_tm5 TRUE
		SET_OBJECT_DYNAMIC debris8_tm5 TRUE
		SET_OBJECT_DYNAMIC debris9_tm5 TRUE
		SET_OBJECT_DYNAMIC debris10_tm5 TRUE
		SET_OBJECT_VELOCITY debris5_tm5 -3.0 6.0 18.0
		SET_OBJECT_VELOCITY debris6_tm5 5.0 7.0 16.0
		SET_OBJECT_VELOCITY debris7_tm5 -6.0 7.0 17.0
		SET_OBJECT_VELOCITY debris8_tm5 8.0 9.0 16.0
		SET_OBJECT_VELOCITY debris9_tm5 -7.0 8.0 14.0
		SET_OBJECT_VELOCITY debris10_tm5 -1.0 10.0 14.0
	ADD_ONE_OFF_SOUND 974.2 -1129.8 19.5 sound_test_1
	//ADD_ONE_OFF_SOUND 983.0 -1103.8 18.4 sound_test_1
 
	SET_FADING_COLOUR 255 255 255
 
	DO_FADE 400 FADE_OUT
	IF NOT IS_PLAYER_DEAD player
		SWAP_NEAREST_BUILDING_MODEL 981.5 -1123.9 16.7 80.0 fishfctory fshfctry_dstryd
	ENDIF
	DO_FADE 400 FADE_IN
 
	START_SCRIPT_FIRE 979.3 -1106.1 14.7 fish_Fire2
	START_SCRIPT_FIRE 981.0 -1132.0 14.0 fish_fire4
	START_SCRIPT_FIRE 970.6 -1107.5 18.5 fish_fire6
	START_SCRIPT_FIRE 965.8 -1123.4 14.0 fish_fire7
 
	fish_factory_destroyed = 1
 
	WAIT 3000
 
	RELEASE_WEATHER
	SWITCH_WIDESCREEN OFF
	SET_PLAYER_CONTROL Player ON
	SET_POLICE_IGNORE_PLAYER Player OFF
	SET_EVERYONE_IGNORE_PLAYER Player OFF
	RESTORE_CAMERA_JUMPCUT
 
 
 
GOTO mission_toni5_passed
 
 
 // Mission toni5 failed
 
mission_toni5_failed:
 
PRINT_BIG ( M_FAIL ) 5000 1 //"Mission Failed"
RETURN
 
 
 
// mission toni5 passed
 
mission_toni5_passed:
 
flag_toni_mission5_passed = 1
PLAY_MISSION_PASSED_TUNE 1
PRINT_WITH_NUMBER_BIG ( M_PASS ) 30000 5000 1 //"Mission Passed!"
CLEAR_WANTED_LEVEL player
ADD_SCORE player 30000
REMOVE_BLIP frankie_contact_blip
ADD_SPRITE_BLIP_FOR_CONTACT_POINT 1455.7 -187.3 -100.0 RADAR_SPRITE_SAL frankie_contact_blip
SETUP_ZONE_PED_INFO FISHFAC DAY   ( 0) 0 0 0 (0 0 0 0) 0 //Fish factory  
SETUP_ZONE_PED_INFO FISHFAC NIGHT ( 0) 0 0 0 (0 0 0 0) 0
SWITCH_CAR_GENERATOR gen_car47 0
SWITCH_CAR_GENERATOR gen_car48 0
SWITCH_CAR_GENERATOR gen_car49 0
flag_frankie_switched_off = 0
REGISTER_MISSION_PASSED TM5
PLAYER_MADE_PROGRESS 1
REMOVE_BLIP toni_contact_blip
START_NEW_SCRIPT toni5_flames_loop
RETURN
 
 
 
// mission cleanup
 
mission_cleanup_toni5:
 
flag_player_on_mission = 0
flag_player_on_toni_mission = 0
REMOVE_BLIP blip1_tm5
REMOVE_BLIP blip2_tm5
CLEAR_ONSCREEN_TIMER countdown_tm5
CLEAR_ONSCREEN_COUNTER explosive_truck_health
MARK_MODEL_AS_NO_LONGER_NEEDED CAR_TRASHMASTER
MARK_MODEL_AS_NO_LONGER_NEEDED fshfctry_dstryd
SET_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1 //TEST
SET_FADING_COLOUR 1 1 1
MISSION_HAS_FINISHED
RETURN
 
 
 
triad_AI:
 
	IF IS_PLAYER_IN_ZONE Player PORT_W
	AND has_player_been_at_fish_before = 1
	AND clear_triads_threats = 0
 
		IF NOT IS_CHAR_DEAD	fish_triad1
			CLEAR_CHAR_THREAT_SEARCH fish_triad1
		ENDIF
		IF NOT IS_CHAR_DEAD	fish_triad2
			CLEAR_CHAR_THREAT_SEARCH fish_triad2
		ENDIF
		IF NOT IS_CHAR_DEAD	fish_triad3
			CLEAR_CHAR_THREAT_SEARCH fish_triad3
		ENDIF
		IF NOT IS_CHAR_DEAD	fish_triad4
			CLEAR_CHAR_THREAT_SEARCH fish_triad4
		ENDIF
		IF NOT IS_CHAR_DEAD	fish_triad5
			CLEAR_CHAR_THREAT_SEARCH fish_triad5
		ENDIF
		IF NOT IS_CHAR_DEAD	fish_triad6
			CLEAR_CHAR_THREAT_SEARCH fish_triad6
		ENDIF
 
		CLEAR_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1
 
		clear_triads_threats = 1
	ENDIF
 
	IF IS_PLAYER_IN_ZONE player FISHFAC	
		IF triads_spot_you = 0
			IF NOT IS_PLAYER_IN_ANY_CAR Player
 
				IF NOT IS_CHAR_DEAD	fish_triad1
					SET_CHAR_THREAT_SEARCH fish_triad1 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad2
					SET_CHAR_THREAT_SEARCH fish_triad2 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad3
					SET_CHAR_THREAT_SEARCH fish_triad3 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad4
					SET_CHAR_THREAT_SEARCH fish_triad4 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad5
					SET_CHAR_THREAT_SEARCH fish_triad5 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad6
					SET_CHAR_THREAT_SEARCH fish_triad6 THREAT_PLAYER1
				ENDIF
 
				SET_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1 //TEST
 
				triads_spot_you = 1
			ENDIF
 
			IF IS_CHAR_DEAD	fish_triad1
			OR IS_CHAR_DEAD fish_triad2
			OR IS_CHAR_DEAD fish_triad3
			OR IS_CHAR_DEAD fish_triad4
			OR IS_CHAR_DEAD fish_triad5
			OR IS_CHAR_DEAD fish_triad6
 
				IF NOT IS_CHAR_DEAD	fish_triad1
					SET_CHAR_THREAT_SEARCH fish_triad1 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad2
					SET_CHAR_THREAT_SEARCH fish_triad2 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad3
					SET_CHAR_THREAT_SEARCH fish_triad3 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad4
					SET_CHAR_THREAT_SEARCH fish_triad4 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad5
					SET_CHAR_THREAT_SEARCH fish_triad5 THREAT_PLAYER1
				ENDIF
				IF NOT IS_CHAR_DEAD	fish_triad6
					SET_CHAR_THREAT_SEARCH fish_triad6 THREAT_PLAYER1
				ENDIF
 
				SET_THREAT_FOR_PED_TYPE PEDTYPE_GANG_TRIAD THREAT_PLAYER1 //TEST
 
				triads_spot_you = 1
			ENDIF
		ENDIF
	ENDIF
 
 
 RETURN
 
 
 
Truck_health:
 
	IF NOT IS_CAR_DEAD explosive_truck 
 
		GET_CAR_HEALTH explosive_truck explosive_truck_health 
		explosive_truck_health2 = 1000 - explosive_truck_health
		IF explosive_truck_health2 > 100
			explosive_truck_health2 = 100
		ENDIF
		explosive_truck_health = explosive_truck_health2 
 
	ENDIF
 
RETURN
п · о · р
GTA III Grand Theft Auto III
Форматы файлов.b.a3d.anm.col.cfg.dff.dat.gxt.ide.ifp.img/.dir.ipl.raw/.sdt.rep.sc.scm.set.txd.zon
Документацияcarcols.datCHASE.DATCULLZONE.DATcuts.imgdefault.datfistfite.datflight.datgta3.exegta3.dat
gta3.imggta3.zonhandling.cfgmain.scmmap.datmap.zonobject.datparticle.cfgped.datpedgrp.dat
pedstats.datsfx.rawsurface.datTimeCyc.DATtracks.dattrain.datwater.datwaterpro.datweapon.dat
ИнструментыCLEOClump ViewerCol-IO‎Collision File Editor IIData toolDFF Viewerdffxbox2pcG-ToolsGTA Garage Mod Manager
GXT EditorGTA3 Limit AdjusterGTA3 Mission BuilderGTA3 PatcherIMG ToolKam's Max ScriptsMap Editor
Mod GeneratorMod InstallerMoo MapperPS2 TXD ModPS2 TXD ViewerResourse HackerRotation Calculator
RW AnalyzeViceTXDWater EditorSanny BuilderTXD ToolTXD WorkshopYAIEZModeler
Туториалыраздел в разработке
Классические МодыGPS RadarBye-Bye BikiniUltimate Stunt ParkThe SphereMiss LibertyIllandoIntercity HighwayShoreside Bridge
Rockstar HeightsLighthouse BridgeBlade FunparkOrbital CityLakeside IslandLiberty PenitentiaryJEM Island
Illando HelixCliff Climbing Mountain
Глобальные МодыReal GTA3Twenty TenSnow CityFrosted WinterUltimateBeta modX-box modBad BusinessGTA3 HDUltra mod
OpenTunnelsBack to the Future
МультиплеерMulti Theft AutoLiberty Unleashed
Исходники4x48ballambulanceasukaasusbcameracar_gencatcopcardebugdemodiablofiretruckfrankgates
genstufhealthhjhoodimportintrojoeykenjiloveluigimayhemmeatpickupsrampagerayrcswitch
taxitoniusjwantedyard