Exemplo n.º 1
0
void SceneScriptUG15::SceneFrameAdvanced(int frame) {
	if (Actor_Query_Goal_Number(kActorFreeSlotA) == 300) {
		float x, y, z;
		Actor_Query_XYZ(kActorMcCoy, &x, &y, &z);
		if (-160.0f <= x
		 && z < 220.0f
		) {
			Actor_Set_Goal_Number(kActorFreeSlotA, 301);
		}
	}
	if (frame == 61) {
		Ambient_Sounds_Play_Sound(583, 80, 0, 0, 99);
	}
	if (Game_Flag_Query(677) && !Game_Flag_Query(682)) {
		float x, y, z;
		Actor_Query_XYZ(kActorMcCoy, &x, &y, &z);
		if (-180.0f <= x
		 && z < 220.0f
		 && !Game_Flag_Query(724)
		) {
			Game_Flag_Set(724);
			Game_Flag_Set(682);
			Scene_Loop_Set_Default(3);
			Scene_Loop_Start_Special(kSceneLoopModeOnce, 2, true);
			Actor_Set_Goal_Number(kActorMcCoy, 390);
			Actor_Query_XYZ(kActorFreeSlotA, &x, &y, &z);
			if (-200.0f < x
			 &&  -62.0f > x
			) {
				Actor_Set_Goal_Number(kActorFreeSlotA, 309);
			}
		}
	}
	//	return false;
}
Exemplo n.º 2
0
bool ScriptKP05::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(0, -802.0f, 0.0f, 972.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(420);
			Set_Enter(46, 43);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(0, -1142.0f, 0.0f, 932.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(575);
			Set_Enter(47, 44);
		}
		return true;
	}
	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(0, -868.0f, 0.0f, -68.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(576);
			Async_Actor_Walk_To_XYZ(0, -868.0f, 0.0f, -216.0f, 0, false);
			Set_Enter(9, 46);
		}
		return true;
	}
	return false;
}
Exemplo n.º 3
0
bool SceneScriptUG04::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -172.0f, 16.29f, -735.0f, 0, true, false, 0)) {
			Game_Flag_Set(kFlagUG04toUG03);
			Set_Enter(kSetUG03, kSceneUG03);
		}
		return true;
	}

	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 0.0f, -1.74f, -2400.0f, 0, true, false, 0)) {
			Game_Flag_Set(kFlagUG04toUG05);
			Set_Enter(kSetUG05, kSceneUG05);
		}
		return true;
	}

	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 164.0f, 11.87f, -1013.0f, 0, true, false, 0)) {
			Game_Flag_Set(kFlagUG04toUG06);
			Set_Enter(kSetUG06, kSceneUG06);
		}
		return true;
	}
	return false;
}
Exemplo n.º 4
0
bool SceneScriptBB07::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -615.0f, 252.59f, -1018.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Overlay_Remove("BB07OVER");
			Game_Flag_Set(300);
			Set_Enter(22, 6);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -619.0f, 252.59f, -1136.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Overlay_Remove("BB07OVER");
			Game_Flag_Set(364);
			Set_Enter(102, 120);
		}
		return true;
	}
	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -551.0f, 252.59f, -1004.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Overlay_Remove("BB07OVER");
			Game_Flag_Set(362);
			Set_Enter(2, 7);
		}
		return true;
	}
	return false;
}
Exemplo n.º 5
0
bool SceneScriptCT08::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -183.0f, 0.0f, 128.0f, 0, true, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(kFlagCT08toCT09);
			Set_Enter(kSetCT09, kSceneCT09);
		}
		return true;
	}

	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -11.0f, 0.0f, -156.0f, 0, true, false, 0)) {
			Loop_Actor_Walk_To_XYZ(kActorMcCoy, 0.0f, 0.0f, -102.0f, 0, false, false, 0);
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(kFlagCT08toCT51);
			Set_Enter(kSetCT08_CT51_UG12, kSceneCT51);
		}
		return true;
	}

	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -143.0f, 0.0f, -92.0f, 0, true, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(kFlagCT08toCT06);
			Set_Enter(kSetCT06, kSceneCT06);
		}
		return true;
	}
	return false;
}
Exemplo n.º 6
0
bool SceneScriptBB04::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -92.0f, -26.6f, 45.0f, 0,  true, false, false)) {
			Player_Loses_Control();
			Loop_Actor_Walk_To_XYZ(kActorMcCoy, -15.0f, -25.17f, 45.0f, 0, false, false, false);
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(kFlagBB04toBB02);
			Game_Flag_Set(kFlagBB02ElevatorDown);
			Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB02);
		}
		return true;
	}

	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -107.0f, -26.6f, 397.0f, 0, true, false, false)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(kFlagBB04toBB03);
			Set_Enter(kSetBB03, kSceneBB03);
		}
		return true;
	}
	return false;
}
Exemplo n.º 7
0
void ScriptAR02::sub_402CE4() {
	Dialogue_Menu_Clear_List();
	if (Actor_Clue_Query(0, 93)) {
		DM_Add_To_List_Never_Repeat_Once_Selected(550, 8, 5, 2);
	}
	if (Actor_Clue_Query(0, 44)) {
		DM_Add_To_List_Never_Repeat_Once_Selected(560, 6, 5, 7);
	}
	Dialogue_Menu_Add_DONE_To_List(570);
	Dialogue_Menu_Appear(320, 240);
	int answerValue = Dialogue_Menu_Query_Input();
	Dialogue_Menu_Disappear();
	switch (answerValue) {
	case 550:
		Actor_Says(0, 145, 11);
		Actor_Says(20, 30, 11);
		Actor_Says(0, 160, 11);
		Actor_Says(20, 40, 11);
		Actor_Says(0, 165, 11);
		Actor_Says(20, 50, 11);
		Actor_Says(0, 170, 11);
		Actor_Says(20, 60, 11);
		Actor_Says(0, 175, 11);
		Game_Flag_Set(370);
		break;
	case 560:
		Actor_Says(0, 150, 11);
		Actor_Says(20, 140, 11);
		Actor_Says(0, 185, 11);
		Actor_Says(20, 150, 11);
		Actor_Says(20, 160, 11);
		Actor_Says(0, 190, 11);
		Actor_Says(20, 170, 11);
		Actor_Says(0, 195, 11);
		Actor_Says(20, 180, 11);
		Actor_Says(20, 190, 11);
		Actor_Says(20, 200, 11);
		Actor_Says(0, 200, 11);
		Actor_Says(20, 210, 11);
		Actor_Says(20, 220, 11);
		Actor_Says(20, 230, 11);
		Game_Flag_Set(370);
		break;
	case 570:
		if (Actor_Clue_Query(0, 57)) {
			Actor_Says(0, 1315, 11);
		} else {
			Actor_Says(0, 940, 13);
			Actor_Says(20, 70, 12);
			Actor_Says(20, 90, 12);
			Actor_Says(0, 180, 15);
			Actor_Says(20, 100, 14);
			Actor_Says(20, 110, 12);
			Actor_Says(20, 120, 13);
			Actor_Modify_Friendliness_To_Other(20, 0, -1);
			Actor_Clue_Acquire(0, 57, 0, 20);
		}
		break;
	}
}
Exemplo n.º 8
0
bool SceneScriptUG16::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -322.0f, -34.0f, -216.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(355);
			Set_Enter(87, kSceneUG15);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -322.0f, -34.0f, -404.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(153);
			Set_Enter(87, kSceneUG15);
		}
		return true;
	}
	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -316.78f, -34.88f, -533.27f, 0, 1, false, 0)) {
			Actor_Face_Heading(kActorMcCoy, 0, false);
			Loop_Actor_Travel_Stairs(kActorMcCoy, 13, 1, 0);
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(551);
			Set_Enter(36, kSceneDR06);
		}
		return true;
	}
	return false;
}
Exemplo n.º 9
0
void SceneScriptUG16::PlayerWalkedIn() {
	Game_Flag_Set(715);
	if (!Game_Flag_Query(595)) {
		Actor_Set_Goal_Number(kActorLuther, 403);
	}
	if (!Game_Flag_Query(556) && Actor_Query_Is_In_Current_Set(kActorLuther)) {
		Player_Loses_Control();
		Loop_Actor_Walk_To_XYZ(kActorMcCoy, 120.29f, -35.67f, 214.8f, 310, 0, false, 0);
		Actor_Face_Actor(kActorMcCoy, kActorLuther, true);
		Actor_Says(kActorLuther, 0, 6);
		Actor_Says(kActorLuther, 30, 13);
		Actor_Change_Animation_Mode(kActorLuther, 17);
		Actor_Says(kActorLance, 0, 17);
		Actor_Says(kActorMcCoy, 5710, 14);
		Actor_Says(kActorLuther, 40, 13);
		Actor_Says(kActorLuther, 50, 15);
		Actor_Says(kActorLance, 20, 12);
		Actor_Says(kActorLuther, 60, 23);
		Actor_Says(kActorMcCoy, 5715, 14);
		Actor_Says(kActorLance, 30, 16);
		Actor_Says(kActorLuther, 70, 6);
		Player_Gains_Control();
		Game_Flag_Set(556);
	}
}
Exemplo n.º 10
0
bool ScriptTB06::ClickedOnItem(int itemId, bool a2) {
	if (itemId == 84 && !Loop_Actor_Walk_To_Item(0, 84, 12, 1, false)) {
		Actor_Face_Item(0, 84, true);
		Actor_Clue_Acquire(0, 65, 1, -1);
		Item_Pickup_Spin_Effect(942, 341, 368);
		Item_Remove_From_World(84);
		Actor_Voice_Over(4160, 99);
		Game_Flag_Set(519);
		return true;
	}
	if (itemId == 108 && !Loop_Actor_Walk_To_Item(0, 108, 12, 1, false)) {
		Actor_Face_Item(0, 108, true);
		Actor_Clue_Acquire(0, 53, 1, -1);
		Item_Remove_From_World(108);
		Item_Pickup_Spin_Effect(955, 390, 368);
		Actor_Says(0, 8775, 3);
		Game_Flag_Set(520);
		return true;
	}
	if (itemId == 82 && !Loop_Actor_Walk_To_Item(0, 82, 12, 1, false)) {
		Actor_Face_Item(0, 82, true);
		Actor_Says(0, 5285, 3);
		return true;
	}
	if ((itemId == 103 || itemId == 104 || itemId == 105) && !Loop_Actor_Walk_To_Item(0, 103, 24, 1, false)) {
		Actor_Face_Item(0, 103, true);
		Actor_Voice_Over(2380, 99);
		Actor_Voice_Over(2390, 99);
		Actor_Voice_Over(2400, 99);
		return true;
	}
	return false;
}
Exemplo n.º 11
0
bool ScriptNR08::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(0, -1102.88f, 0.0f, 107.43f, 0, 1, false, 0)) {
			Game_Flag_Set(547);
			Set_Enter(13, 58);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(0, -724.7f, 0.0f, 384.24f, 0, 1, false, 0)) {
			Actor_Face_Heading(0, 505, false);
			Loop_Actor_Travel_Stairs(0, 4, 1, 0);
			Game_Flag_Set(440);
			Set_Enter(56, 59);
		}
		return true;
	}
	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(0, -1663.33f, 0.65f, 342.84f, 0, 1, false, 0)) {
			Actor_Face_Heading(0, 831, false);
			Footstep_Sound_Override_On(2);
			Loop_Actor_Travel_Stairs(0, 6, 1, 0);
			Footstep_Sound_Override_Off();
			Game_Flag_Set(614);
			Set_Enter(58, 62);
		}
	}
	return false;
}
Exemplo n.º 12
0
bool SceneScriptCT03::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -745.09f, -619.09f, 293.36f, 0, 1, false, 0)) {
			Game_Flag_Set(71);
			Set_Enter(4, 13);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -604.38f, -616.15f, 221.6f, 0, 1, false, 0)) {
			Game_Flag_Set(70);
			Set_Enter(27, 14);
		}
		return true;
	}
	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -150.0f, -621.3f, 357.0f, 0, 1, false, 0)) {
			Game_Flag_Set(72);
			Async_Actor_Walk_To_XYZ(kActorMcCoy, -67.0f, -621.3f, 477.0f, 0, false);
			Set_Enter(5, 16);
		}
		return true;
	}
	return false;
}
Exemplo n.º 13
0
bool SceneScriptRC01::ClickedOnActor(int actorId) {
	if (actorId == kActorOfficerLeary && Global_Variable_Query(kVariableChapter) == 1) {
		if (!Loop_Actor_Walk_To_Actor(kActorMcCoy, kActorOfficerLeary, 36, true, false)) {
			Actor_Face_Actor(kActorMcCoy, kActorOfficerLeary, true);
			Actor_Face_Actor(kActorOfficerLeary, kActorMcCoy, true);
			if (Actor_Query_Goal_Number(kActorOfficerLeary) == kGoalOfficerLearyRC01WalkToCrowd) {
				Actor_Set_Goal_Number(kActorOfficerLeary, kGoalOfficerLearyDefault);
			}
			if (Game_Flag_Query(kFlagRC01GotOfficersStatement)) {
				Actor_Says(kActorMcCoy, 4535, 13);
				Game_Flag_Set(kFlagRC01McCoyAndOfficerLearyTalking);
				if (Actor_Clue_Query(kActorOfficerLeary, kClueCrowdInterviewA) && !Actor_Clue_Query(kActorMcCoy, kClueCrowdInterviewA)) {
					Actor_Face_Object(kActorOfficerLeary, "70_1", true);
					Actor_Says(kActorOfficerLeary, 100, 15);
					Actor_Face_Actor(kActorOfficerLeary, kActorMcCoy, true);
					Actor_Clue_Acquire(kActorMcCoy, kClueCrowdInterviewA, true, kActorOfficerLeary);
					Game_Flag_Reset(kFlagRC01McCoyAndOfficerLearyTalking);
				} else if (Actor_Clue_Query(kActorOfficerLeary, kClueCrowdInterviewB) && !Actor_Clue_Query(kActorMcCoy, kClueCrowdInterviewB)) {
					Actor_Face_Object(kActorOfficerLeary, "70_5", true);
					Actor_Says(kActorOfficerLeary, 120, 19);
					Actor_Face_Actor(kActorOfficerLeary, kActorMcCoy, true);
					Actor_Says(kActorOfficerLeary, 130, 14);
					I_Sez("JM: Did it have a huge, ugly piece of chrome on it?");
					Actor_Clue_Acquire(kActorMcCoy, kClueCrowdInterviewB, true, kActorOfficerLeary);
					Game_Flag_Reset(kFlagRC01McCoyAndOfficerLearyTalking);
				} else {
					Actor_Says(kActorOfficerLeary, 90, 16);
					I_Sez("JM: This officer has a talent for vivid metaphors.");
					if (!Game_Flag_Query(kFlagRC01McCoyAndOfficerLearyArtMetaphor)) {
						I_Sez("DL: What is that supposed to mean?  I didn't write this line...");
						Actor_Says(kActorMcCoy, 4540, 16);
						Game_Flag_Set(kFlagRC01McCoyAndOfficerLearyArtMetaphor);
					}
					Game_Flag_Reset(kFlagRC01McCoyAndOfficerLearyTalking);
				}
			} else {
				I_Sez("MG: Hey, leave that officer alone. Can't you see he's busy?");
				I_Sez("JM: (...mmm, donuts...)");
				Game_Flag_Set(kFlagRC01GotOfficersStatement);
				Actor_Clue_Acquire(kActorMcCoy, kClueOfficersStatement, true, kActorOfficerLeary);
				Actor_Says(kActorMcCoy, 4515, 13);
				Game_Flag_Set(kFlagRC01McCoyAndOfficerLearyTalking);
				Actor_Says(kActorOfficerLeary, 40, 13);
				if (!Game_Flag_Query(kFlagRC02Entered)) {
					Actor_Says(kActorOfficerLeary, 50, 14);
					Actor_Says(kActorOfficerLeary, 60, 15);
					I_Sez("MG: It's all fun and games until someone loses a tiger cub.");
					Actor_Says(kActorMcCoy, 4520, 18);
					Actor_Says(kActorOfficerLeary, 70, 16);
					Actor_Says(kActorMcCoy, 4525, 14);
					Actor_Says(kActorOfficerLeary, 80, 18);
					Actor_Says(kActorMcCoy, 4530, 15);
				}
				Game_Flag_Reset(kFlagRC01McCoyAndOfficerLearyTalking);
			}
		}
		return true;
	}
	return false;
}
Exemplo n.º 14
0
bool SceneScriptUG06::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 23.0f, 0.0f, 321.0f, 0, true, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(kFlagUG06toUG04);
			Set_Enter(kSetUG04, kSceneUG04);
		}
		return true;
	}

	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 66.0f, 0.0f, -90.0f, 0, true, false, 0)) {
			Actor_Face_Heading(kActorMcCoy, 0, false);
			Loop_Actor_Travel_Stairs(kActorMcCoy, 17, 1, kAnimationModeIdle);
			Loop_Actor_Walk_To_XYZ(kActorMcCoy, 66.0f, 153.0f, -446.0f, 0, false, false, 0);
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(kFlagUG06toNR01);
			Set_Enter(kSetNR01, kSceneNR01);
		}
		return true;
	}
	return false;
}
Exemplo n.º 15
0
bool ScriptCT12::ClickedOnActor(int actorId) {
	if (actorId == 28) {
		Actor_Face_Actor(0, 28, true);
		Actor_Says(0, 8910, 16);
	}
	if (actorId == 24 && Global_Variable_Query(1) == 4 && Game_Flag_Query(671) && Game_Flag_Query(703)) {
		Actor_Face_Actor(24, 0, true);
		Actor_Face_Actor(0, 24, true);
		Actor_Says(0, 710, 3);
		Actor_Says(24, 20, 3);
		Actor_Says(0, 715, 3);
		Actor_Says(24, 30, 3);
		Actor_Says(0, 720, 3);
		Actor_Says(24, 40, 3);
		Actor_Says(24, 50, 3);
		Actor_Says(24, 60, 3);
		Actor_Says(0, 725, 3);
		Actor_Says(24, 70, 3);
		Actor_Says(24, 80, 3);
		Actor_Says(24, 90, 3);
		Actor_Says(24, 100, 3);
		Actor_Says(24, 110, 3);
		Game_Flag_Set(629);
		Game_Flag_Set(666);
		Actor_Set_Goal_Number(0, 400);
	}
	return false;
}
Exemplo n.º 16
0
bool ScriptHC03::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(0, 607.0f, 0.14f, 9.0f, 0, 1, false, 0)) {
			Game_Flag_Set(387);
			Set_Enter(8, 31);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(0, 628.0f, 2.04f, -123.0f, 0, 1, false, 0)) {
			if (Game_Flag_Query(388)) {
				Game_Flag_Set(319);
				Game_Flag_Reset(479);
				Game_Flag_Set(259);
				Game_Flag_Set(388);
				Music_Stop(2);
				Set_Enter(75, 87);
			} else {
				Scene_Loop_Set_Default(6);
				Scene_Loop_Start_Special(2, 5, 1);
				Game_Flag_Set(388);
			}
		}
		return true;
	}
	return false;
}
Exemplo n.º 17
0
bool SceneScriptUG01::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -32.0f, -50.13f, -1350.0f, 12, true, false, 0)) {
			Game_Flag_Set(kFlagUG01toUG10);
			Set_Enter(kSetUG10, kSceneUG10);
		}
		return true;
	}

	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -70.0f, -50.13f, -500.0f, 0, true, false, 0)) {
			Actor_Face_Heading(kActorMcCoy, 768, false);
			Loop_Actor_Travel_Ladder(kActorMcCoy, 12, true, 0);
			Game_Flag_Set(kFlagUG01toRC03);
			Game_Flag_Reset(kFlagMcCoyInUnderground);
			Game_Flag_Set(kFlagMcCoyInRunciters);
			Set_Enter(kSetRC03, kSceneRC03);
		}
		return true;
	}

	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -126.0f, -50.13f, -286.0f, 0, true, false, 0)) {
			Game_Flag_Set(kFlagUG01toUG02);
			Set_Enter(kSetUG02, kSceneUG02);
		}
		return true;
	}
	return false;
}
Exemplo n.º 18
0
bool SceneScriptCT12::ClickedOnActor(int actorId) {
	if (actorId == 28) {
		Actor_Face_Actor(kActorMcCoy, kActorHowieLee, true);
		Actor_Says(kActorMcCoy, 8910, 16);
	}
	if (actorId == 24 && Global_Variable_Query(kVariableChapter) == 4 && Game_Flag_Query(671) && Game_Flag_Query(703)) {
		Actor_Face_Actor(kActorOfficerGrayford, kActorMcCoy, true);
		Actor_Face_Actor(kActorMcCoy, kActorOfficerGrayford, true);
		Actor_Says(kActorMcCoy, 710, 3);
		Actor_Says(kActorOfficerGrayford, 20, 3);
		Actor_Says(kActorMcCoy, 715, 3);
		Actor_Says(kActorOfficerGrayford, 30, 3);
		Actor_Says(kActorMcCoy, 720, 3);
		Actor_Says(kActorOfficerGrayford, 40, 3);
		Actor_Says(kActorOfficerGrayford, 50, 3);
		Actor_Says(kActorOfficerGrayford, 60, 3);
		Actor_Says(kActorMcCoy, 725, 3);
		Actor_Says(kActorOfficerGrayford, 70, 3);
		Actor_Says(kActorOfficerGrayford, 80, 3);
		Actor_Says(kActorOfficerGrayford, 90, 3);
		Actor_Says(kActorOfficerGrayford, 100, 3);
		Actor_Says(kActorOfficerGrayford, 110, 3);
		Game_Flag_Set(629);
		Game_Flag_Set(666);
		Actor_Set_Goal_Number(kActorMcCoy, 400);
	}
	return false;
}
Exemplo n.º 19
0
bool ScriptBB08::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(0, 204.0f, 0.1f, 94.0f, 0, 1, false, 0)) {
			Actor_Face_Heading(0, 256, false);
			Footstep_Sound_Override_On(2);
			Loop_Actor_Travel_Ladder(0, 8, 1, 0);
			Footstep_Sound_Override_Off();
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(218);
			Set_Enter(24, 10);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(0, 247.0f, 0.1f, 27.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(506);
			Set_Enter(102, 120);
		}
		return true;
	}
	return false;
}
Exemplo n.º 20
0
bool SceneScriptBB07::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -615.0f, 252.59f, -1018.0f, 0, true, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Overlay_Remove("BB07OVER");
			Game_Flag_Set(kFlagBB07toBB05);
			Set_Enter(kSetBB05, kSceneBB05);
		}
		return true;
	}

	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -619.0f, 252.59f, -1136.0f, 0, true, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Overlay_Remove("BB07OVER");
			Game_Flag_Set(kFlagBB07toBB12);
			Set_Enter(kSetBB12, kSceneBB12);
		}
		return true;
	}

	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -551.0f, 252.59f, -1004.0f, 0, true, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Overlay_Remove("BB07OVER");
			Game_Flag_Set(kFlagBB07toBB06);
			Set_Enter(kSetBB06_BB07, kSceneBB06);
		}
		return true;
	}
	return false;
}
Exemplo n.º 21
0
bool ScriptAR02::ClickedOnItem(int itemId, bool a2) {
	if (itemId == 106) {
		if (!Loop_Actor_Walk_To_XYZ(0, -386.96f, 0.0f, -1078.45f, 12, 1, false, 0)) {
			Actor_Face_Actor(0, 16, true);
			if (!Game_Flag_Query(331)) {
				Actor_Says(16, 0, 14);
				Actor_Says(0, 55, 18);
				Actor_Says(16, 10, 14);
				Actor_Says(0, 60, 18);
				Actor_Says(16, 20, 14);
				Game_Flag_Set(331);
			} else if (Game_Flag_Query(331) && !Game_Flag_Query(367)) {
				Actor_Says(0, 65, 21);
				Actor_Says(16, 30, 14);
				Actor_Says(16, 40, 14);
				Actor_Says(0, 70, 18);
				Actor_Says(16, 50, 14);
				Game_Flag_Set(367);
			} else {
				Actor_Says(0, 8527, 14);
			}
			return true;
		}
	}
	return false;
}
Exemplo n.º 22
0
bool SceneScriptCT11::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 121.0f, 9.68f, -42.0f, 0, 1, false, 0)) {
			Game_Flag_Set(304);
			Set_Enter(31, kSceneCT09);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -300.0f, 9.68f, 66.0f, 0, 1, false, 0)) {
			Loop_Actor_Walk_To_XYZ(kActorMcCoy, -400.0f, 9.68f, -70.0f, 0, 1, false, 0);
			Game_Flag_Set(86);
			Set_Enter(4, kSceneCT12);
		}
		return true;
	}
	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 290.0f, 0.0f, 635.0f, 0, 1, false, 0)) {
			Game_Flag_Set(531);
			Game_Flag_Reset(176);
			Game_Flag_Set(177);
			Set_Enter(7, kSceneDR01);
		}
		return true;
	}
	return false;
}
Exemplo n.º 23
0
bool SceneScriptUG17::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 1000.0f, 67.96f, -1539.0f, 0, 1, false, 0)) {
			Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
			Ambient_Sounds_Remove_All_Looping_Sounds(1);
			Game_Flag_Set(353);
			Set_Enter(87, kSceneUG15);
		}
		return true;
	}
	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 1013.0f, 67.96f, -1892.0f, 0, 1, false, 0)) {
			Actor_Face_Heading(kActorMcCoy, 89, false);
			if (Global_Variable_Query(kVariableChapter) == 5) {
				Actor_Says(kActorMcCoy, 8522, 14);
			} else {
				Loop_Actor_Travel_Ladder(kActorMcCoy, 10, 1, 0);
				Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
				Ambient_Sounds_Remove_All_Looping_Sounds(1);
				Game_Flag_Set(448);
				Set_Enter(17, kSceneTB03);
			}
		}
		return true;
	}
	return false;
}
Exemplo n.º 24
0
void SceneScriptCT11::SceneLoaded() {
	Obstacle_Object("TRASH CAN", true);
	Unobstacle_Object("BOX NORTHWEST 1", true);
	Unobstacle_Object("BOX SOUTH 1", true);
	if (Global_Variable_Query(kVariableChapter) < 4) {
		if (!Game_Flag_Query(645)) {
			Item_Add_To_World(115, 951, 33, 640.21f, 30.0f, 470.0f, 512, 12, 12, false, true, false, true);
			Scene_2D_Region_Add(0, 505, 316, 513, 321);
			Game_Flag_Set(725);
		}
		if (!Actor_Clue_Query(kActorMcCoy, kClueCar)) {
			Scene_2D_Region_Add(1, 412, 258, 552, 358);
		}
	} else {
		if (Game_Flag_Query(725)) {
			Item_Remove_From_World(115);
			Game_Flag_Reset(725);
			Game_Flag_Set(645);
		}
		Unobstacle_Object("BRIDGE SUPPORT", true);
		Unobstacle_Object("BODY", true);
		Unobstacle_Object("HEADLIGHTS", true);
		Unobstacle_Object("LICENSE PLATE-FRONT", true);
		Unobstacle_Object("LICENSE PLATE-REAR", true);
		Unobstacle_Object("BRAKE DISC RF", true);
		Unobstacle_Object("TIRE RF", true);
		Unobstacle_Object("RIM RF", true);
		Unobstacle_Object("DOOR RIGHT", true);
		Unobstacle_Object("BUMPER REAR", true);
	}
	Unclickable_Object("TRASH CAN");
}
Exemplo n.º 25
0
void ScriptMA04::sub_403DA8() {
	if (!Loop_Actor_Walk_To_Scene_Object(0, "BED-SHEETS", 12, 1, false)) {
		Actor_Says(0, 8530, 12);
		Music_Stop(4);
		if (sub_402820() || sub_402758()) {
			Overlay_Remove("MA04OVER");
		}
		Player_Loses_Control();
		Game_Flag_Set(647);
		if ((Game_Flag_Query(40) || Game_Flag_Query(41)) && Global_Variable_Query(1) == 1) {
			if (Actor_Query_Goal_Number(19) == 599) {
				Actor_Put_In_Set(19, 91);
				Actor_Set_At_Waypoint(19, 33, 0);
			}
			Game_Flag_Set(678);
			Global_Variable_Set(1, 2);
			Chapter_Enter(2, 10, 50);
			if (Query_Difficulty_Level() != 0) {
				if (!Game_Flag_Query(723)) {
					Global_Variable_Increment(2, 200);
				}
			}
		} else {
			Set_Enter(10, 50);
		}
		Scene_Loop_Start_Special(1, 3, 0);
	}
}
Exemplo n.º 26
0
bool ScriptMA04::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(0, -7099.0f, 954.0f, 1866.0f, 0, 1, false, 0)) {
			Game_Flag_Set(36);
			Set_Enter(10, 49);
		}
		return true;
	}
	if (exitId == 1) {
		float x, y, z;
		Actor_Query_XYZ(0, &x, &y, &z);
		if (z <= 1677.0f || !Loop_Actor_Walk_To_XYZ(0, -7199.0f, 955.0f, 1675.0f, 0, 1, false, 0)) {
			if (sub_402888()) {
				Overlay_Remove("MA04OVER");
			}
			Loop_Actor_Walk_To_XYZ(0, -7199.0f, 955.0f, 1675.0f, 0, 0, false, 1);
			Game_Flag_Set(62);
			if (Global_Variable_Query(1) != 2 && Global_Variable_Query(1) != 3) {
				Async_Actor_Walk_To_XYZ(0, -7199.0f, 956.17f, 1568.0f, 0, false);
			}
			Set_Enter(51, 51);
		}
		return true;
	}
	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(0, -7115.0f, 954.0f, 1742.0f, 0, 1, false, 0)) {
			int sounds[] = {252, 405, 404, 407, 406};
			Ambient_Sounds_Play_Sound(sounds[Random_Query(0, 4)], 50, 0, 0, 0);
			Delay(3000);
			Loop_Actor_Walk_To_XYZ(0, -7139.0f, 954.0f, 1746.0f, 0, 1, false, 1);
		}
	}
	return false;
}
Exemplo n.º 27
0
bool SceneScriptDR02::ClickedOnExit(int exitId) {
	if (exitId == 0) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -835.0f, -0.04f, -118.0f, 0, true, false, 0)) {
			Async_Actor_Walk_To_XYZ(kActorMcCoy, -727.0f, -0.04f, -118.0f, 0, false);
			Game_Flag_Set(kFlagDR02toDR01);
			Set_Enter(kSetDR01_DR02_DR04, kSceneDR01);
		}
		Ambient_Sounds_Adjust_Looping_Sound(219, 12, -101, 1);
		Ambient_Sounds_Adjust_Looping_Sound(98, 14, -101, 1);
		return true;
	}

	if (exitId == 1) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -1162.0f, 7.18f, -322.0f, 0, true, false, 0)) {
			if (Global_Variable_Query(kVariableChapter) > 2) {
				Actor_Says(kActorMcCoy, 8522, 15);
			} else {
				Game_Flag_Set(kFlagDR02toDR03);
				Set_Enter(kSetDR03, kSceneDR03);
			}
		}
		return true;
	}

	if (exitId == 2) {
		if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -1258.0f, 7.18f, -314.0f, 0, true, false, 0)) {
			Game_Flag_Set(kFlagDR02toBB01);
			Game_Flag_Reset(kFlagMcCoyInDNARow);
			Game_Flag_Set(kFlagMcCoyInBradburyBuilding);
			Set_Enter(kSetBB01, kSceneBB01);
		}
		return true;
	}
	return false;
}
Exemplo n.º 28
0
void AIScriptClovis::OtherAgentEnteredCombatMode(int otherActorId, int combatMode) {
	if (Game_Flag_Query(653) && Actor_Query_In_Set(kActorMcCoy, kSetKP07)) {
		Game_Flag_Set(697);
		Game_Flag_Set(714);
		// return true;
	}
	// return false;
}
Exemplo n.º 29
0
bool SceneScriptCT04::ClickedOn3DObject(const char *objectName, bool a2) {
	if (objectName) {
		if (!Game_Flag_Query(137) && !Game_Flag_Query(169) && !Actor_Query_Goal_Number(kActorTransient)) {
			Game_Flag_Set(137);
			Actor_Set_Goal_Number(kActorTransient, 2);
		}
		if (Game_Flag_Query(169) && !Game_Flag_Query(170) && !Game_Flag_Query(171) && !Game_Flag_Query(172) && Global_Variable_Query(1) == 1) {
			if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -147.41f, -621.3f, 724.57f, 0, 1, false, 0)) {
				Player_Loses_Control();
				Actor_Face_Heading(kActorMcCoy, 792, false);
				Actor_Put_In_Set(kActorTransient, 99);
				Actor_Set_At_XYZ(kActorTransient, 0, 0, 0, 0);
				Actor_Change_Animation_Mode(kActorMcCoy, 40);
				Actor_Voice_Over(320, kActorVoiceOver);
				Actor_Voice_Over(330, kActorVoiceOver);
				Actor_Voice_Over(340, kActorVoiceOver);
				Game_Flag_Set(170);
				Game_Flag_Set(173);
			}
			return false;
		}
		if (Game_Flag_Query(170)) {
			if (Game_Flag_Query(172)) {
				Actor_Voice_Over(270, kActorVoiceOver);
				Actor_Voice_Over(280, kActorVoiceOver);
			} else if (Game_Flag_Query(171)) {
				Actor_Voice_Over(250, kActorVoiceOver);
				Actor_Voice_Over(260, kActorVoiceOver);
			} else {
				Actor_Voice_Over(230, kActorVoiceOver);
				Actor_Voice_Over(240, kActorVoiceOver);
				Game_Flag_Reset(173);
			}
			return true;
		}
		if (Game_Flag_Query(174)) {
			if (!Loop_Actor_Walk_To_Waypoint(kActorMcCoy, 75, 0, 1, false)) {
				Actor_Face_Heading(kActorMcCoy, 707, false);
				Actor_Change_Animation_Mode(kActorMcCoy, 38);
				Ambient_Sounds_Play_Sound(553, 45, 30, 30, 0);
				Actor_Voice_Over(1810, kActorVoiceOver);
				Actor_Voice_Over(1820, kActorVoiceOver);
				return true;
			}
			return false;
		}
		if (!Loop_Actor_Walk_To_Waypoint(kActorMcCoy, 75, 0, 1, false)) {
			Actor_Face_Heading(kActorMcCoy, 707, false);
			Actor_Change_Animation_Mode(kActorMcCoy, 38);
			Actor_Clue_Acquire(kActorMcCoy, kClueLicensePlate, 1, -1);
			Item_Pickup_Spin_Effect(952, 392, 225);
			Game_Flag_Set(174);
			return true;
		}
	}
	return false;
}
Exemplo n.º 30
0
bool AIScriptLucy::Update() {
	float x, y, z;

	if (Global_Variable_Query(kVariableChapter) == 3 && Actor_Query_Goal_Number(kActorLucy) < 200) {
		Actor_Set_Goal_Number(kActorLucy, 200);
	}
	if (Actor_Query_Goal_Number(kActorLucy) == 230 && Player_Query_Current_Scene() == 37) {
		Actor_Set_Goal_Number(kActorLucy, 233);
	}
	if (Global_Variable_Query(kVariableChapter) == 4 && Actor_Query_Goal_Number(kActorLucy) < 300) {
		Actor_Set_Goal_Number(kActorLucy, 300);
	}
	if (Global_Variable_Query(kVariableChapter) == 4
			&& Actor_Query_Goal_Number(kActorLucy) == 599
			&& Actor_Query_Which_Set_In(kActorLucy) != 99) {
		if (Actor_Query_Which_Set_In(kActorLucy) != Player_Query_Current_Set()) {
			Actor_Put_In_Set(kActorLucy, kSetFreeSlotI);
			Actor_Set_At_Waypoint(kActorLucy, 41, 0);
		}
	}
	if (Game_Flag_Query(616) && Actor_Query_Goal_Number(kActorLucy) == 201) {
		Actor_Put_In_Set(kActorLucy, kSetHF03);
		Actor_Set_At_Waypoint(kActorLucy, 371, 156);
		Actor_Set_Goal_Number(kActorLucy, 250);
	}
	if (Actor_Query_Goal_Number(kActorLucy) > 229
			&& Actor_Query_Goal_Number(kActorLucy) < 239
			&& Actor_Query_Goal_Number(kActorLucy) != 232
			&& Player_Query_Current_Scene() == 37
			&& Actor_Query_Which_Set_In(kActorLucy) == 40
			&& !Game_Flag_Query(701)
			&& Actor_Query_Inch_Distance_From_Actor(kActorLucy, kActorMcCoy) < 84
			&& !Player_Query_Combat_Mode()
			&& Actor_Query_Friendliness_To_Other(kActorLucy, kActorMcCoy) > 40) {
		Actor_Set_Goal_Number(kActorLucy, 232);
	}
	if (Actor_Query_Goal_Number(kActorLucy) == 235) {
		Actor_Query_XYZ(kActorMcCoy, &x, &y, &z);
		if (z > -875.0f) {
			Game_Flag_Set(586);
			Actor_Set_Goal_Number(kActorLucy, 236);
		}
	}
	if (Actor_Query_Goal_Number(kActorLucy) == 237) {
		Actor_Query_XYZ(kActorMcCoy, &x, &y, &z);
		if (x > 350.0f) {
			Game_Flag_Set(585);
			Actor_Set_Goal_Number(kActorLucy, 238);
		}
	}

	return false;
}