%%
%% *:Q_ConstructionProblem Content
%%
%% There's a problem at a construction site.
%%
%% Param1: The boss NPC who sent the PC to find the problem
%% Param2: Construction Site Scene
%%

Content
	name <Rowdy Foreman>
	requires <*:Q_ConstructionProblem>
	% desc <The foreman is refusing to work; the PC has to put a stop to it.>
	desc <現場監督が仕事を拒否している。PC はそれを解決しなければならない。>

	% E1 is the boss
	% E2 is the construction site
	% E3 is the on-site manager
	% E4 is the rowdy foreman
	% E5 is the mecha scene where a fight will take place
	Element3 <Prefab>
	Place3 <2 (Citizens) Pass Ally>
	Element4 <Prefab>
	Place4 <2 (Citizens) Pass Ally>
	Element5 <QuestScene>
	Place5 <2>
	Element6 <Prefab>
	Place6 </>

	%% P%id%01 = Have accepted challenge

	%% FAIL CONDITIONS:
	%% - E3 dies

	end <ifNPCDead %3% LoseSubPlot %plotid%>

	sub
		Persona 3
		greeting <if= PlotStatus %plotid% %id% else GoCheckFirst if= P%id%01 1 else GoExplain if= ArenaState %5% NAV_AS_Win else GoWaiting NewChat Say 2 SetPlotStatus %plotid% -1 ResetArena %5% AddChat 1>
		GoWaiting <NewChat Say 4>
		GoCheckFirst <if= PlotStatus %plotid% 0 else GoChat NewChat Say 1>
		GoChat <NewChat SayAnything>
		GoExplain <NewChat Say 5 AddChat 2>
		result1 <NewChat Say 6>
		result2 <ifNPCOK %4% else GoTrivialWin NewChat Say 7 QMemo %plotid% 9 P= %id%01 1 AddChat 3 AddChat 4>
		GoTrivialWin <NewChat Say 8  SetPlotStatus %plotid% -1>
		result3 <NewChat Say 10>
		result4 <AddSociable -d6 NewChat Say 11 AddChat 5>
		result5 <NewChat Say 12>
		% Msg1 <If %name1% didn't send you, you've got no business being in here.>
		% Msg2 <Now that %name4% has been dealt with, our work can continue.>
		% Msg4 <Let me know when you've convinced %name4% to go back to work.>
		% Msg5 <Ah, you must have been sent here by %name1%. My name's %name3%; I'm the manager of this project.>
		% Msg6 <Not much, no... We can't fire someone with senority, but as long as they're gone we can always promote someone else.>
		% Msg7 <The trouble is %name4%; \SPR %4% got into a big argument with me about how this project should be done and now \SPR %4% 's stopped working. None of the other workers will do anything either because %name4% has senority.>
		% Msg8 <We were having some personnel problems, but those are all cleared up now.>
		% Msg9 <%name3% revealed that %name1%'s project is being delayed by the foreman, %name4%.>
		% Msg10 <You can try, but I doubt it'll do any good... %name4% never listens to anyone.>
		% Msg11 <We can't. As I said, %name4% has senority. According to company rules \SPR %4% can't be fired.>
		% Msg12 <Look, just go and talk with \OPR %4% yourself. Maybe \SPR %4% 'll listen to you.>
		% Prompt1 <Doesn't it matter that %name4% is dead?>
		% CPrompt1 <ifNPCDead %4% Accept>
		% Prompt2 <Could you tell me what the problem is?>
		% Prompt3 <I'll have a talk with \OPR %4% .>
		% Prompt4 <Why don't you just fire \OPR %4% ?>
		% Prompt5 <Then why don't you quit?>
		Msg1 <%name1% に派遣されてきたのでないなら、%JS2がここにいる理由はないはず%JV_DESU%JV_YO。>
		Msg2 <ようやく %name4% のことが片付%JV_KIMASITA%JV_YO。これで仕事が再開でき%JV_MASU……。>
		Msg4 <では、%name4% を説得することができたら教えて%JV_KUDASAI。>
		Msg5 <ああ、%name1% に派遣されてきた%JV_N%JV_DESUKA。%JF2は %name3%、このプロジェクトのマネージャー%JV_DESU。>
		Msg6 <%JR_NO、特には……古株をクビにはでき%JV_MASEN%JG_GA、居なくなったのなら他の誰かを昇進させれば話は終わり%JV_DESU。>
		Msg7 <問題は %name4% %JV_DESU。\SPR %4%とはこのプロジェクトの進め方について激しい口論になって、それで\SPR %4%は働くのを止めてしまった%JV_N%JV_DESU。あれが一番の古参であるせいで、他の連中も何もしようとしない。>
		Msg8 <いくつか個人的な問題は発生した%JG_GA、これですべて解決し%JV_MASITA。>
		Msg9 <%name3% は、%name1% のプロジェクトが現場監督の %name4% のせいで遅れていると明らかにした。>
		Msg10 <やってみるといい%JV_DESYOU。けど上手くいくかどうかは疑問%JV_DESU%JV_NE…… %name4% は人の話を聞かないから。>
		Msg11 <無理%JV_DESU。さっき言ったとおり、%name4% は古株で、うちの会社の規定じゃ\SPR %4%をクビにするのは無理な%JV_N%JV_DESU>
		Msg12 <ほら、いいからとにかく自分で\SPR %4%と話してきて%JV_KUDASAI。%JS2が行けば、話くらいは聞くかもしれ%JV_MASENから。>
		Prompt1 <%JT_SOの生死にはこだわらない？>
		CPrompt1 <ifNPCDead %4% Accept>
		Prompt2 <何が問題になっているのか教えて%JG_R。>
		Prompt3 <%JT_SOと話をしてみ%JV_YOU。>
		Prompt4 <単に%JT_SOをクビにすれば済むんじゃないの%JV_KA_Q%JV_SIL？>
		Prompt5 <じゃあ%JS2が辞めれば%JV_SIL？>

		Persona 4
		% V1 = Have been challenged to mecha duel/have completed quarry arena
		% V2 = History message counter
		Greeting <ifSubPlotWon %plotid% else GoCheckQ1State if= V1 1 else GoChat Goto GoOpenArena>
		GoOpenArena <if= ArenaState %5% NAV_AS_Win else GoCheckQ2Loss Goto GoArenaWin>
		GoCheckQ2Loss <if= ArenaState %5% NAV_AS_Loss else GoCheckQ2Ready Goto GoArenaLoss>
		GoCheckQ2Ready <if= ArenaState %5% NAV_AS_Vacant else GoArenaFull ifG ComTime ArenaRecharge %5% else GoArenaBusy Goto GoOfferFight>
		GoArenaWin <if= ArenaWins %5% 5 else GoMinorWin Goto GoBigWin>
		*GoMinorWin <*BasicArenaWin %5% GoResetArena>
		*GoArenaLoss <*BasicArenaLoss %5% GoResetArena>
		GoResetArena <ResetArena %5%>
		*GoArenaFull <*ArenaIsFull %5%>
		*GoArenaBusy <*ArenaIsBusy %5%>
		GoBigWin <NewChat Say 15 History 16 V= 1 2 XPV 200 CashPrize Reward ArenaThreat %5% 500 GiveItem %6% Goto GoResetArena>
		GoOfferFight <NewChat Say 13 AddChat 10 AddChat 11 if= V2 0 V= 2 1 History 14>
		GoCheckQ1State <if= PlotStatus %plotid% %id% else GoNoMatch if= P%id%01 1 else GoNotYet  if= ArenaState %5% NAV_AS_Battle else GoCheckStatus Goto GoTrashTalk>
		*GoTrashTalk <*ArenaChallenge GoThemeInfo>
		*GoThemeInfo <*THEME_EXPO&Enemy NA>
		GoCheckStatus <if= ArenaState %5% NAV_AS_Ready else GoCheckWin Goto GoWaiting>
		*GoWaiting <*WaitingForDuel %5%>
		GoCheckWin <if= ArenaState %5% NAV_AS_Win else GoCheckChallenge NewChat Say 2>
		GoCheckChallenge <ResetArena %5% ifG ComTime ArenaRecharge %5% else GoLater if= V1 1 else GoFirstTime NewChat Say 3 AddChat 1 AddChat 2>
		GoFirstTime <NewChat Say 5 AddChat 3 AddChat 4>
		*GoLater <*ChallengeMeLater>
		GoNotYet <NewChat Say 4>
		GoNoMatch <if= PlotStatus %plotid% 0 else GoChat NewChat Say 1>
		GoChat <NewChat SayAnything>
		GoNoTalk <NewChat Say 6 AddChat 5>
		GoStartCombat <SetChallengerID %5% %4% SetChallengerHome %5% %2% MoveNPC %4% %5% PrepArena %5% 0 SetNPCTeam %4% 2>
		*GoChooseBattle <*StartArenaBattle %5% GoStartFight>
		GoStartFight <SavePos PrepArena %5% 70 Jump %5%>
		*GoRefuseBattle <*RefuseArenaFight %5%>
		*result1 <*MeetMeAtArena %5% GoStartCombat>
		*result2 <*RejectChallenge>
		result3 <NewChat Say 7 AddChat 6 AddChat 5>
		result4 <NewChat Say 8 AddChat 7 AddChat 5>
		result5 <NewChat Say 9 AddChat 8 AddChat 9>
		result6 <ifIntimidation HardSkillTar %threat% else GoNoTalk NewChat Say 10 XPV 100 SetArenaState %5% NAV_AS_Win>
		result7 <ifConversation HardSkillTar %threat% else GoNoTalk NewChat Say 10 XPV 100 SetArenaState %5% NAV_AS_Win>
		result8 <V= 1 1   SetArenaThreat %5% %threat%   QMemo %plotid% 11 Goto result1>
		result9 <NewChat Say 12>
		result10 <Goto GoChooseBattle>
		result11 <Goto GoRefuseBattle>
		% Msg1 <We've got a lot of work to do today. Personally, I'm trying to avoid it.>
		% Msg2 <You beat me... Go tell %name3% that everybody will get back to work.>
		% Msg3 <So, you think you can take me?>
		% Msg4 <If you've got something to talk about, you better do that with %name3% . I'm not gonna have any part in it.>
		% Msg5 <%name3% sent you to talk, didn't \OPR %3% ?>
		% Msg6 <There's no way I'm going to take orders from a pencil-necked paper-pusher like %name3%, who doesn't even know the first thing about construction.>
		% Msg7 <%name3% comes down here from \PPR %3% fancy school and starts telling us to do all kinds of things that make no sense. I'm not going to do that, and I won't subject my men to it either.>
		% Msg8 <Delaying a project isn't something I want to do, but I just don't believe in %name3%. It'd be a bigger waste of time to go along with \OPR %3% and then learn that everything's falling to bits.>
		% Msg9 <If you're so interested in this, why don't you take me up on a little wager? There's a big pit downstairs called %name5%. If you can beat me in mecha combat down there, I'll get back to work.>
		% Msg10 <Argh... you're right. Go tell %name3% that me and the boys will get back to work.>
		% Msg11 <You agreed to duel %name4% beneath the construction site as part of a wager to force \OPR %4% to go back to work.>
		% Msg12 <Suit yourself. I can stay here all day.>
		% Msg13 <Some of the guys are having a little match down below. How'd you like to join in?>
		% Msg14 <%name4% offered to let you join the mecha fights at %name2%.>
		% Msg15 <I knew you were a tough pilot when you kicked my arse six ways to Saturn... The tournament's over now, and you're our new champion. We don't have a trophy but you can take this hammer. When the men see it they'll know what it means.>
		% Msg16 <You were crowned champion of %name5%.>
		% Prompt1 <I know I can.>
		% Prompt2 <Not right now, maybe later.>
		% Prompt3 <Why aren't you working?>
		% Prompt4 <You should stop wasting time.>
		% Prompt5 <Is there anything I can do to change your mind?>
		% Prompt6 <You better accept it or this project will fail.>
		% Prompt7 <Sometimes you have to try new things.>
		% Prompt8 <Sounds good. Let's do it.>
		% Prompt9 <You've got to be joking.>
		% Prompt10 <I'd love to.>
		% CPrompt10 <ifChatNPCInPlay ifG PCMeks 0 Accept>
		% Prompt11 <Maybe some other time.>
		Msg1 <今日は仕事が山盛り%JV_M_DA%JV_NA。何とかしてサボってやる%JV_ZO。>
		Msg2 <%JS2の勝ち%JG_DA%JV_SIL_Rみんな仕事に戻ると %name3% に伝えて%JG_R。>
		Msg3 <へえ、%JF2に勝てると思ってるの%JV_KA_Q？>
		Msg4 <何か言いたいことがあるなら、%name3% に言いに行って%JG_R_AGG。%JF2は何の関係もないこと%JG_DANE。>
		Msg5 <%JS2は…… %name3% に雇われて来たの%JV_KA。>
		Msg6 <%name3% みたいな、建設のイロハも知らないヒョロヒョロのデスクワーカーの命令なんて聞く理由はない%JG_NE。>
		Msg7 <お上品なガッコウを出た %name3% が無意味な作業ばかり押しつけるから%JG_DAYO。%JF2はそんなことには従わないし、ウチの連中にもさせやしない%JV_ZO。>
		Msg8 <プロジェクトを遅らせたいわけじゃないけど、%name3% の言うことは信じない%JV_ZO。\SPR %3%の言うとおりにして建物が崩壊するほうがよっぽど無駄%JG_DANE。>
		Msg9 <そんなにご執心なら、ここで一つ賭けをしない%JV_KA_Q？ そこに %name5% って呼ばれてる大きな穴がある%JG_NDA%JV_SIL_Rそこで%JF2とメックで勝負して、%JS2が勝ったら仕事に戻ってやる%JG_YO。>
		Msg10 <くっ……%JS2の言うとおり%JG_DAYO。%JF2もウチの連中も仕事に戻ると %name3% に伝えるといい%JV_F_WA。>
		Msg11 <%name4% が仕事を再開する条件の一環として、\SPR %4%と建設現場の地下で決闘することになった。>
		Msg12 <なら好きにしてるといい%JV_F_WA。こっちはずっとこのままでも困らない%JV_Nだから%JV_NA。>
		Msg13 <ここの下でちょっとしたメックバトルがある%JG_NDA。%JS2も参加していく%JV_Q？>
		Msg14 <%name4% から、%name2% でのメック対決に参加するよう誘われた。>
		Msg15 <あんな手でノされちゃ、タフなパイロットだと認めるしかない%JG_SY%JV_SIL_Rトーナメントはこれで決着、%JS2がここの新しいチャンプ%JG_DAYO。ウチにはトロフィーの類はない%JG_GA、代わりにこのハンマーを受け取って%JG_R。ここの連中なら、これがどういうモノなのか見ただけで伝わる%JV_ZO。>
		Msg16 <%name5% の栄えあるチャンプになった。>
		Prompt1 <勝てる%JV_F_WA。>
		Prompt2 <今すぐじゃない、また後で。>
		Prompt3 <どうして仕事をしない%JV_F_NO？>
		Prompt4 <時間を無駄にするのはやめる%JG_NDA。>
		Prompt5 <どうすれば聞き入れてもらえる%JV_F_NO？>
		Prompt6 <素直に働いて%JG_R_AGG。仕事を台無しにする気%JV_KA_Q？>
		Prompt7 <時には違うやり方を試してみるべき%JG_DA。>
		Prompt8 <悪くない%JV_F_WA、それで決まり%JG_DA。>
		Prompt9 <また冗談を。>
		Prompt10 <いい%JV_F_WAね。>
		CPrompt10 <ifChatNPCInPlay ifG PCMeks 0 Accept>
		Prompt11 <また機会があれば。>

		MetaScene 3
		sub
			Room
			minimap <......#.#...2...#.#......>
			inv
				Trapdoor
				name <To Quarry>
				name_I18N <採石場入り口>
				desig <ENTRANCE %5%>
				MiniMapComponent 2
			end
		end

		MetaScene 5 2
		name <#'s Quarry>
		name_I18N <# の採石場>
		BoxMap
		RockyTiles
		MapWidth 17
		MapHeight 12
		terrain <INSIDE>
		special <SHOWALL SOLO ARENA NOPILLAGE>
		start <if= SelfArenaState NAV_AS_Ready else GoCheckBattle          Alert 1   SetSelfArenaState NAV_AS_Battle SetSelfArenaRecharge if# SelfChallengerID 0 ForceChat SelfChallengerID>
		GoCheckBattle <if= SelfArenaState NAV_AS_Battle else GoBoringStart Print 2>
		GoBoringStart <Print 3 Return>
		nu1 <if= T1 0 Return   if= SelfArenaState NAV_AS_Battle SetSelfArenaState NAV_AS_Loss  Alert 5 Print 5  LoseRenown  Goto GoEndBattle>
		nu2 <if= T2 0 Return   if= SelfArenaState NAV_AS_Battle SetSelfArenaState NAV_AS_Win   Alert 6 Print 6  AddSelfArenaWin  AddSelfArenaThreat d10  XPV 100 FacXP+ 5 1 AddRenown 1 ifNPCOK SelfChallengerID else GoEndBattle ForceChat SelfChallengerID Goto GoEndBattle>
		GoEndBattle <ifNPCOK SelfChallengerID MoveAndPacifyNPC SelfChallengerID SelfChallengerHome ClearSelfChallengerID>
		% Msg1 <You enter the quarry. Prepare to battle.>
		% Msg2 <The arena battle rages on.>
		% Msg3 <You enter the quarry. There's nothing interesting here.>
		% Msg5 <You have lost the battle.>
		% Msg6 <You have won the battle.>
		Msg1 <採石場に入った。戦いに備えろ。>
		Msg2 <採石場に入った。激しい戦いが繰り広げられている。>
		Msg3 <採石場に入った。特に目につくものはない。>
		Msg5 <戦いに敗れた。>
		Msg6 <戦いに勝った。>
		sub
			Team 1
			name <Player Team>
			SetEnemy 2
			ParaX 5
			ParaY 5

			Team 2
			name <Enemies>
			SetEnemy 1
			Deploy <if= SelfArenaState NAV_AS_Ready ifG SelfArenaForces 0 WMecha 2 SelfArenaThreat SelfArenaForces>
			ParaX 12
			ParaY 7
		end
	end
	inv
		NPC Construction Worker
		job <Manager>

		NPC Mecha Pilot
		job <Foreman>
		job_desig <LABOR>
		chardesc Passionate Melancholy

		Melee 23
		Name <Rock Hammer>
		Name_I18N <ロック・ハンマー>
		% desc <A massive hammer made of stone.>
		desc <岩石で作られた巨大なハンマー。>
		type <EXTEND STUN BRUTAL>
		category <WEAPON MELEE>
		SDL_PORTRAIT <item_warhammer.png>
		Acc 1
		mass -10
		fudge 35000
		Speed 3
	end

Content
	name <Stupid Fungus>
	requires <*:Q_ConstructionProblem (Spinner|Asteroid)>
	% The construction site has been infested with spaceworms, and the boss hasn't
	% provided the funds for extermination.

	% E1 is the boss
	% E2 is the construction site
	% E3 is the foreman
	% E4 is the extermination scene
	element3 <Prefab>
	place3 <2 (Citizens) Pass Ally>
	element4 <QuestScene>
	Place4 <2>

	%
	% P%id%01 = Argument Counter
	%           Have told about problem (1), have secured funding (2)
	% P%id%02 = Have method to stop fungi from coming back
	%

	%% FAIL CONDITIONS:
	%% - E1 dies
	end <ifNPCDead %1% LoseSubPlot %plotid%>

	sub
		% Both the boss and the foreman get speaking roles this time around- if the
		% PC returns to speak with the boss, he may be able to convince him to pay for
		% a sensible de-fung'ing of the construction site.
		Persona 1
		% V%id%01 = Have argued the point already
		% If the PC has spoken to character 3, then he can talk to E1 and maybe get money.
		greeting <if= PlotStatus %plotid% %id% else %pop% if= P%id%01 1 else %pop% Goto .%id%_GoArgue>
		.%id%_GoArgue <if= v%id%01 0 else .%id%_GoArgue2 NewChat Say %id%01 V= %id%01 1 AddChat %id%01>
		.%id%_GoArgue2 <NewChat Say %id%02 AddChat %id%02>
		result%id%01 <NewChat Say %id%03 AddChat %id%03>
		result%id%02 <NewChat Say %id%04 AddChat %id%04 AddChat %id%05 AddChat %id%06 AddChat %id%07 AddChat %id%08>
		result%id%03 <Goto result%id%02>
		result%id%04 <NewChat Say %id%05>
		result%id%05 <NewChat Say %id%06 P= %id%01 2>
		result%id%06 <NewChat Say %id%07 P= %id%01 2>
		result%id%07 <NewChat Say %id%06 P= %id%01 2>
		result%id%08 <NewChat Say %id%08 P= %id%01 2>
		% Msg%id%01 <Have you found out from %name3% why construction has been delayed?>
		% Msg%id%02 <I'm still waiting for %name3% to finish construction.>
		% Msg%id%03 <That shouldn't be a big problem. I already provided funds for an exterminator.>
		% Msg%id%04 <This project is over budget already. There must be a better way... You're a cavalier, couldn't you just go kill all the fungus?>
		% Msg%id%05 <You do that.>
		% Msg%id%06 <You're probably right... some added expense at this point will save us headaches down the road. Tell %name3% that I'll arrange for a more thorough extermination.>
		% Msg%id%07 <Seriously? In that case, I guess there's nothing I can do... Tell %name3% that I'll provide extra funds for extermination.>
		% Msg%id%08 <Hmmm. Your numbers are sound... Tell %name3% that I'll provide extra funds for extermination.>
		% Prompt%id%01 <There's a fungus infestation at the site.>
		% Prompt%id%02 <%name3%'s still waiting for the exterminator.>
		% Prompt%id%03 <Apparently, the funds weren't enough.>
		% Prompt%id%04 <I'll see what I can do.>
		% Prompt%id%05 <Really, I think we need a professional.>
		% CPrompt%id%05 <ifConversation HardSkillTar %threat% Accept>
		% Prompt%id%06 <Without proper treatment they'll be back in a week.>
		% CPrompt%id%06 <ifScience HardSkillTar %threat% Accept>
		% Prompt%id%07 <It's been tried and failed. Now who's wasting money?>
		% CPrompt%id%07 <ifIntimidation HardSkillTar %threat% Accept>
		% Prompt%id%08 <By my calculations, you'll save money by doing this right.>
		% CPrompt%id%08 <ifShoppingKN HardSkillTar %threat% Accept>
		Msg%id%01 <どうして建設が遅れているのか、%name3% から聞き出した%JV_KA_Q？>
		Msg%id%02 <%name3% はまだ建設を終わらせられないの%JV_KA_Q？>
		Msg%id%03 <大した問題じゃないはず%JG_DA。駆除業者を雇う金はもう渡してある%JG_NDA。>
		Msg%id%04 <このプロジェクトはもう予算オーバーな%JG_NDA。もっとマシな方法……%JS2もメック乗りなら、ちょっと行って奴らを全滅させてはいただけない%JG_KANA？>
		Msg%id%05 <そうして%JG_R。>
		Msg%id%06 <それもそう%JV_KA……もう一押しで頭痛の種が消える%JV_Nだから。もっと本格的な駆除の手配を行うと %name3% に伝えて%JG_R。>
		Msg%id%07 <本当%JV_KA_Q？ なら仕方ない%JV_F_WA%JV_NA……駆除の予算を増やすと %name3% に伝えて%JG_R。>
		Msg%id%08 <ふむ。説得力のある数字%JG_DANE%JV_SIL_R駆除の予算を増やすと %name3% に伝えて%JG_R。>
		Prompt%id%01 <現場がキノコ生物で汚染されている%JV_F_WA。>
		Prompt%id%02 <%name3% は駆除業者の到着を待ってる%JV_F_WA。>
		Prompt%id%03 <じゃあ、金額が十分じゃなかった%JG_NDA。>
		Prompt%id%04 <やれるかどうか試してみる%JV_F_WA。>
		Prompt%id%05 <いや、プロに任せたほうがいい%JG_YO。>
		CPrompt%id%05 <ifConversation HardSkillTar %threat% Accept>
		Prompt%id%06 <きちんと始末しないと、一週間でまた生える%JV_ZO。>
		CPrompt%id%06 <ifScience HardSkillTar %threat% Accept>
		Prompt%id%07 <それはもうやったけどダメだった。ケチって損をしてるのはどっち%JV_M_DA？>
		CPrompt%id%07 <ifIntimidation HardSkillTar %threat% Accept>
		Prompt%id%08 <こちらの計算では、正しい対処こそが本当の節約になる%JV_ZO。>
		CPrompt%id%08 <ifShoppingKN HardSkillTar %threat% Accept>

		Persona 3
		% V%id%01 = Have discussed problem
		% V%id%03 = Have thanked PC for cleaning basement
		% rumor%id% <%name3% has been having problems with %name1%'s construction project.>
		rumor%id% <%name3% が %name1% の建設プロジェクトで問題を抱えている>
		greeting <ifSubPlotWon %plotid% else GoCheckProgress if= V%id%03 0 else GoChat NewChat Say 14 AddReact d10 V= %id%03 1>
		GoCheckProgress <if= PlotStatus %plotid% %id% else GoChat  if= v%id%01 1 else GoFirstTime NewChat Say 10 AddChat 9 AddChat 10>
		GoFirstTime <NewChat Say 1 AddChat 1 AddChat 2>
		*GoChat <*MISC_CHATTER>
		result1 <NewChat Say 2 V= %id%01 1 P= %id%01 1 QMemo %plotid% 6 AddChat 3 AddChat 4>
		result2 <AddCheerful d8 Goto result1>
		result3 <NewChat Say 3 AddChat 5 AddChat 6 AddChat 7 AddChat 8>
		result4 <NewChat Say 4>
		result5 <NewChat Say 5  P= %id%02 1>
		result6 <NewChat Say 7>
		result7 <NewChat Say 8  P= %id%02 1>
		result8 <NewChat Say 9>
		result9 <NewChat Say 11>
		result10 <NewChat Say 12 XPV 100 WinSubPlot %plotid%>
		% Msg1 <Yes, were you sent here by %name1%? It's about time that something was done...>
		% Msg2 <Construction has halted due to a fungus infestation. It's not even safe for the workbots to go there. %name1% hired an exterminator once, but now the fungi are back and stronger than ever.>
		% Msg3 <I don't think that's a good idea. We already tried that, remember? Pretty soon the fungus came back... What we really need is some kind of an expert.>
		% Msg4 <I think that would be best. Let me know what happens.>
		% Msg5 <Could it be as simple as that? You seem to know what you're talking about, so if you can make it work go for it.>
		% Msg6 <%name3% revealed that %name1%'s construction site is infested with space fungus.>
		% Msg7 <Fine. Do whatever you think is best... Come back and let me know when we can get back to work.>
		% Msg8 <Really? In that case, you should be qualified to handle the extermination. Come back and let me know when you're satisfied that the construction zone is safe.>
		% Msg9 <I know I am. If only %name1% were as reasonable as you...>
		% Msg10 <We will be able to begin construction as soon as the fungi are cleared out. Do you have any progress to report?>
		% Msg11 <Well, come see me when you do.>
		% Msg12 <Fantastic. You can tell %name1% that construction will resume as soon as possible.>
		% Msg14 <Thanks for clearing out the basement. It seems like this time the fungus are gonna stay gone.>
		% Prompt1 <Hold on, what's the matter?>
		% Prompt2 <I'm here. Everything will be fine now.>
		% Prompt3 <Why don't I just kill the fungi for you?>
		% Prompt4 <I'll talk to %name1% about the exterminator.>
		% Prompt5 <It's okay. After I kill them, wash the area to get rid of the spores.>
		% CPrompt5 <ifSurvivalKN SkillTar %threat% Accept>
		% Prompt6 <We don't need no stinking expert!>
		% Prompt7 <Just spray with sulfonanilide after I've killed the big ones.>
		% CPrompt7 <ifScience SkillTar %threat% Accept>
		% Prompt8 <You're probably right.>
		% Prompt9 <Nothing yet.>
		% Prompt10 <%name1% has agreed to provide extra funds.>
		% CPrompt10 <if= P%id%01 2 Accept>
		Msg1 <ああ、%name1% に雇われて来た%JV_N%JV_DESUKA？ いい加減何とかしないといけなかったところな%JV_N%JV_DESU……。>
		Msg2 <キノコ生物による汚染で建設が中断してい%JV_MASU。ワーカーボットですら安全ではない環境な%JV_N%JV_DESU。一度 %name1% が業者を手配して駆除した%JV_N%JV_DESU%JG_GA、奴ら前より強力になって戻ってきた%JV_N%JV_DESU%JV_YO。>
		Msg3 <それじゃ上手くい%JV_KIMASEN。それはもう試した%JV_DESYOU、違%JV_IMASUか？ キノコどもはあっという間にまた生えてくる……専門家の手が必要な%JV_N%JV_DESU。>
		Msg4 <それが一番だと思%JV_IMASU。伝えたら結果を教えて%JV_KUDASAI。>
		Msg5 <そんな単純でいい%JV_N%JV_DESUKA？ %JS2は詳しい人間のよう%JV_DESUから、それで上手くいくというのなら任せ%JV_MASU%JV_YO。>
		Msg6 <%name3% は %name1% の建設用地が宇宙キノコに汚染されていると明かした。>
		Msg7 <分か%JV_RIMASITA、好きなようにやって%JV_KUDASAI……建設が再開できる状態になったら、ここに戻って報告を。>
		Msg8 <本当%JV_DESUKA？ それなら、駆除するのは%JS2が適任%JV_DESU%JV_NE。一帯が安全になったと確信できたら、戻って報告して%JV_KUDASAI。>
		Msg9 <そう%JV_DESU%JV_YO。%name1% も%JS2のように物分りが良ければ……。>
		Msg10 <キノコどもが排除され次第、建設が再開でき%JV_MASU。何か報告があ%JV_RIMASUか？>
		Msg11 <じゃあ、片付いてから来て%JV_KUDASAI。>
		Msg12 <素晴らしい成果%JV_DESU。可能な限りすぐに建設を再開すると %name1% に伝えて%JV_KUDASAI。>
		Msg14 <地下の制圧に感謝%JV_S_SIMASU。キノコども、今度は生えてこないみたい%JV_DESU。>
		Prompt1 <ちょっと待って、何があった%JV_F_NO？>
		Prompt2 <その通り。これから全て解決する%JG_YO。>
		Prompt3 <キノコを殺してやればいいん%JV_DAROU？>
		Prompt4 <その業者について %name1% と話して来%JV_YOU。>
		Prompt5 <大丈夫、殺したら一帯を胞子ごと洗浄する%JV_N%JV_M_DA。>
		CPrompt5 <ifSurvivalKN SkillTar %threat% Accept>
		Prompt6 <専門家なんて必要ない%JV_ZO！>
		Prompt7 <駆除したらスルホンアニリンを撒けばいい%JV_F_WA。>
		CPrompt7 <ifScience SkillTar %threat% Accept>
		Prompt8 <じゃあ、それが正解なん%JV_DAROU。>
		Prompt9 <まだ何も。>
		Prompt10 <%name1% が駆除の予算を出してくれるって。>
		CPrompt10 <if= P%id%01 2 Accept>

		MetaScene 3
		sub
			room
			minimap <......###..#2#........1..>
			special <SHAREDPALETTE>
			desig <HOME>
			inv
				Elevator
				name <Sub-Basement>
				name_I18N <地下２階>
				desig <Entrance %4%>
				MiniMapComponent 2
				use <if= V1 1 else GoLocked Print 1 Exit Destination>
				Update <if= PlotStatus %plotid% %id% V= 1 1>
				GoLocked <Print 2>
				% Msg2 <There's nothing interesting in here.>
				Msg2 <ここには特に目を引くものはない。>
			end
		end

		MetaScene 4
		%% The fungus on this level is being produced by 4 spore-spewers.
		%% Until the PC destroys them, the fungus will keep spreading.
		name <%name3%'s Basement>
		name_I18N <%name3% 地下>
		type <Basement Private>
		terrain <GROUND>
		special <NOEXIT>

		MonkeyMap
		MapWidth 35
		MapHeight 35
		RockyTiles

		content <Fill Sub *STORAGE_X na>

		%% Upon entering the map, if there are any spore-spewers left then the random monster
		%% value will be set for Team 2. If the player outlined to the foreman a plan for
		%% getting rid of the fungus (P%id%02) or if the spore-spewers have been destroyed,
		%% then the final wave will be readied.

		% L1 = Initialization counter, reset upon exit
		% L2 = Initial number of spore-spewers
		% L3 = Number of spore-spewer monster upgrades
		% L4 = Final conflict started
		% L5 = Victory counter

		start <Print 1 if= PlotStatus %plotid% %id% if= L1 0 L= 1 1 if# P%id%02 0 else GoCheckSpores Retreat 3 Goto GoFinalConfrontation>
		GoCheckSpores <ifG T3 0 else GoFinalConfrontation  MonsterSet 2 %threat% MonsterUp 2 * 5 L3  L= 2 T3>
		GoFinalConfrontation <Alert 3  L= 4 1  MonsterOff 2  WMonster 2 %threat% 100>
		end <L= 1 0>

		% When all the fungus have been destroyed, check to see if this is the final confrontation.
		% If so, congratulations! You've won the mission. If not, nothing happens.
		nu2 <if= T2 0 if# L4 0 if= L5 0 Alert 2 XPV 100 L= 5 1 WinSubPlot %plotid%>
		% When a spore-spewer has been destroyed, check to see if the final conflict has started.
		% If not, check to make sure that one has actually been destroyed. Reset the spore-spewer
		% counter and add one to the monster upgrades. If this is the last spore-spewer start the
		% final confrontation.
		nu3 <if= L4 0  ifG L2 T3  L+ 3 1 L= 2 T3  MonsterUp 2 5  if= T3 0 Goto GoFinalConfrontation>

		% Msg1 <You enter the basement.>
		% Msg2 <That seems to be the last of the fungi.>
		% Msg3 <Just clear out the last of the fungi, and you'll be done.>
		Msg1 <地下に入った。>
		Msg2 <今のが最後のキノコだったようだ。>
		Msg3 <キノコを一匹残らず片付ければ、それで仕事は完了だ。>

		sub
			Team 1
			SetEnemy 2 3

			Team 2
			name <Monsters>
			type <Fungus>
			SetEnemy 1
			SetAlly 3

			Team 3
			name <Spore-Spewers>
			SetEnemy 1
			SetAlly 2

			Room
			sub
				StairsUp
				Destination -1
			end

			Room
			minimap <............1............>
			inv
				STC MUSHROOMPATCH-1
				name <Spore-Spewer>
				name_I18N <ばらまきキノコ>
				sdl_colors <36 140 46 36 140 46 121 109 150>
				update <ifSubPlotWon %plotid% DeleteSelf>
				SetTeam 3
				MiniMapComponent 1
			end

			Room
			minimap <............1............>
			inv
				STC MUSHROOMPATCH-1
				name <Spore-Spewer>
				name_I18N <ばらまきキノコ>
				sdl_colors <36 140 46 36 140 46 121 109 150>
				update <ifSubPlotWon %plotid% DeleteSelf>
				SetTeam 3
				MiniMapComponent 1
			end

			Room
			minimap <............1............>
			inv
				STC MUSHROOMPATCH-1
				name <Spore-Spewer>
				name_I18N <ばらまきキノコ>
				sdl_colors <36 140 46 36 140 46 121 109 150>
				update <ifSubPlotWon %plotid% DeleteSelf>
				SetTeam 3
				MiniMapComponent 1
			end

			Room
			minimap <............1............>
			inv
				STC MUSHROOMPATCH-1
				name <Spore-Spewer>
				name_I18N <ばらまきキノコ>
				sdl_colors <36 140 46 36 140 46 121 109 150>
				update <ifSubPlotWon %plotid% DeleteSelf>
				SetTeam 3
				MiniMapComponent 1
			end
		end
	end
	inv
		NPC Construction Worker
		job <Foreman>
	end

Content
	name <Supplies Went Missing>
	requires <*:Q_ConstructionProblem>
	% The trouble with construction is that someone stole the materials!

	% E1 is the boss
	% E2 is the construction site
	% E3 is the foreman
	element3 <Prefab>
	Place3 <2 (Citizens) Pass Ally>

	% P%id%01 = Memo update

	end <ifNPCDead %3% LoseSubPlot %plotid%>

	% The update will check SP1 to set the memo message
	update <if= P%id%01 0 ifSubPlotWon %plotid1% else .%id%_GoCheckLoss   P= %id%01 1 QMemo %plotid% %id%01>
	.%id%_GoCheckLoss <ifSubPlotLost %plotid1%                            P= %id%01 1 QMemo %plotid% %id%02>

	% Msg%id%01 <You have recovered %name3%'s building supplies. You should go see \OPR %3% in \SCENE NPCScene %3%.>
	% Msg%id%02 <You have lost %name3%'s building supplies. You should go see \OPR %3% in \SCENE NPCScene %3%.>
	Msg%id%01 <%name3% の建設資材を取り戻した。\SCENE NPCScene %3% に行って\SPR %3%に報告しよう。>
	Msg%id%02 <%name3% の建設資材を失った。\SCENE NPCScene %3% に行って\SPR %3%に報告しよう。>

	SubPlot1 <*:Q_StolenMaterials&ConstructionSite 3>

	sub
		Persona 3
		% V1 = Have revealed problem
		greeting <if= PlotStatus %plotid% %id% else GoChat if= V1 1 else GoFirstTime NewChat Say 3 AddChat 2 AddChat 5>
		GoFirstTime <NewChat Say 1 AddChat 1>
		*GoChat <*MISC_CHATTER>
		result1 <NewChat V= 1 1 Say 2 AddChat 3 AddChat 4 SetPlotStatus %plotid1% %id1% QMemo %plotid% 4>
		result2 <NewChat Say 5 SetPlotStatus %plotid% -1 AddReact d10>
		result3 <NewChat Say 6>
		result4 <NewChat Say 7 AddCheerful -d10>
		result5 <NewChat Say 8 SetPlotStatus %plotid% -2>
		% Msg1 <Yes, may I help you? We're very busy here right now.>
		% Msg2 <I wish I could tell you that things are proceeding well, but they aren't. The trouble is, we've been losing building materials.>
		% Msg3 <Have you found anything about the missing building materials?>
		% Msg4 <%name3% revealed that materials are being stolen from %name1%'s construction site.>
		% Msg5 <Fantastic! We'll be able to get back to work soon... You should report to %name1% .>
		% Msg6 <Ask around and see if you can uncover any clues. I'll help you in whatever way I can.>
		% Msg7 <If you can't find the materials and bring them back, then it'll be both of us who have failed, won't it? Search around and see what you can find out. I'll keep working on the project.>
		% Msg8 <The our project is lost... report back to %name1%.>
		% Prompt1 <I was send to hurry up the construction.>
		% Prompt1_1 <%name1% sent me to check your progress.>
		% Prompt2 <I've solved your materials problem.>
		% CPrompt2 <if= PlotStatus %plotid1% -1 Accept>
		% Prompt3 <I could find out what happened to them.>
		% Prompt4 <%name1% won't be pleased at your failure.>
		% Prompt5 <I think you better give up on those supplies...>
		% CPrompt5 <if= PlotStatus %plotid1% -2 Accept>
		Msg1 <うん、何か用事%JV_DESUKA？ ちょっと今はとても忙しい%JV_N%JV_DESU。>
		Msg2 <順調だと申し上げられれば良かった%JV_N%JV_DESU%JG_GA、残念ながらそうなってい%JV_MASEN。建設資材が盗まれてしまった%JV_N%JV_DESU。>
		Msg3 <盗まれた資材のこと、何か分か%JV_RIMASITA%JV_KA_Q？>
		Msg4 <%name3% は、%name1% の建設用地から資材が盗まれていると明かした。>
		Msg5 <最高%JV_DESU%JV_OJO_WA！ これですぐ仕事が再開でき%JV_MASU…… %name1% に報告にいって%JV_KUDASAI。>
		Msg6 <周りの者にも聞き込みをして、手がかりがないか調べるといい%JV_DESYOU。出来ることなら何でも手伝%JV_IMASU。>
		Msg7 <もし%JS2が資材を取り戻せなければ、失敗は%JF2たち両方の責任%JV_DESU、違%JV_IMASUか？ 何か手がかりがないか調べて回って%JV_KUDASAI。%JF2はプロジェクトを進めてお%JV_KIMASU。>
		Msg8 <ではこのプロジェクトは失敗%JV_DESU…… %name1% にそう報告して%JV_KUDASAI。>
		Prompt1 <建設を急がせるために派遣されてきた%JV_F_NO。>
		Prompt1_1 <%name1% に言われて、進捗の確認に来た%JV_F_NO。>
		Prompt2 <資材の問題は解決した%JV_F_WA。>
		CPrompt2 <if= PlotStatus %plotid1% -1 Accept>
		Prompt3 <資材がどうなったのか調べてみ%JV_YOU。>
		Prompt4 <%name1% は%JS2の失敗を喜ばない%JV_DAROU。>
		Prompt5 <資材のことは諦めたほうがいい%JV_F_WA……。>
		CPrompt5 <if= PlotStatus %plotid1% -2 Accept>
	end
	inv
		NPC Construction Worker
		job <Foreman>
	end

Content
	name <Robot Rampage>
	requires <*:Q_ConstructionProblem>
	% desc <The construction robots have malfunctioned; the PC can repair them or destroy them.>
	desc <建設用ロボットが暴走を起こした。PC はこれを修理するか破壊することができる。>

	% E1 is the boss
	% E2 is the construction site
	% E3 is the robotics specialist
	% E4 is the basement full of robots
	Element3 <Prefab>
	Place3 <2 (Citizens) Pass Ally>

	Element4 <QuestScene>
	Place4 <2>

	sub
		Persona 3
		% This character just explains how to win the component; other than that he's
		% pretty useless. If the PC wins without destroying all the robots, then this
		% person will become a friend.
		% rumor%id% <%name3% is in charge of the robots for %name1%'s project.>
		rumor%id% <%name3% は %name1% のプロジェクトでロボットの監督をしている>
		% V1 = Have given victory speech
		% V2 = Have given first introduction
		greeting <if= PlotStatus %plotid% -1 else GoCheckQuest if= V1 0 else GoChat V= 1 1 if= SceneVar %4% 1 0 else GoBadWin PCFriend %3% NewChat Say 7>
		GoBadWin <NewChat Say 8>
		GoCheckQuest <if= PlotStatus %plotid% %id% else GoChat if= V2 1 else GoFirstTime NewChat Say 5 AddChat 3 AddChat 4>
		*GoFirstTime <*SomeoneSentPCToTalk %1% GoExplain>
		*GoChat <*MISC_CHATTER>
		GoExplain <V= 2 1 NewChat Say 1 QMemo %plotid% 2 AddChat 1 AddChat 2>
		Result1 <NewChat Say 3>
		Result2 <NewChat Say 4>
		Result3 <Goto GoExplain>
		Result4 <NewChat Say 6>
		% Msg1 <The construction robots on the lower level have malfunctioned. They haven't gone aggressive, exactly, it's just that they no longer seem to recognize the difference between human beings and building materials. It's pretty dangerous down there.>
		% Msg2 <%name3% told you that the construction robots at %name1%'s project have malfunctioned, making life dangerous for the workers.>
		% Msg3 <Not really. The control station here stopped working, so we can't even shut them down remotely. Personally I suspect industrial sabotage, though I shudder to think that one of our employees could be working for someone else.>
		% Msg4 <Destroying the robots is probably the only way we're going to get construction back on track. Please try to leave enough wreckage so we can figure out what went wrong.>
		% Msg5 <Do you have anything to report?>
		% Msg6 <Please do your best.>
		% Msg7 <The problem has been fixed, and we didn't even need to destroy all the robots. Thanks to you we'll be back on schedule in no time! You should go tell %name1% about what you've accomplished.>
		% Msg8 <The problem has been solved, so I guess it's time for us to get to work... and without any robots to do the heavy bits, either. You should go tell %name1% that the project is back on track.>
		% Prompt1 <Any idea what happened?>
		% Prompt2 <Don't worry, I can deal with them.>
		% Prompt3 <Could you remind me what's going on again?>
		% Prompt4 <Not yet. I'll be back when I do.>
		Msg1 <下層の建築ロボットがおかしくなった%JV_N%JV_DESU。攻撃的になったというか、建築資材と人間の区別が付かなくなってるみたいで。とても危険な状態%JV_DESU。>
		Msg2 <%name3% によると、%name1% のプロジェクトの建築用ロボットが暴走して、作業員に危険を及ぼしているらしい。>
		Msg3 <%JR_NO、何とも。ここにある制御ステーションも止まってしまって、遠隔で停止させることもでき%JV_MASEN。個人的には同業者の妨害工作を疑ってい%JV_MASUが……うちの従業員の誰かが犯人だなんて、考えるのも恐ろしい%JV_F_WA。>
		Msg4 <おそらく、ロボットを全て破壊してしまうのが建設を再開する唯一の方法%JV_DESYOU。ただ、原因究明のために残骸は十分に残しておいてほしい%JV_F_WA%JV_NA。>
		Msg5 <何か進展はあ%JV_RIMASITA%JV_KA_Q？>
		Msg6 <どうか最善を尽くして%JV_KUDASAI。>
		Msg7 <問題は解決して、さらにロボットを全部壊してしまわずに済%JV_MIMASITA……ありがとう、これですぐにスケジュールに追いつけ%JV_MASU！ %name1% に%JS2の功績を伝えに行って%JV_KUDASAI。>
		Msg8 <問題は解決して、これで仕事を再開でき%JV_MASU……重作業用のロボット抜きで、%JV_DESU%JG_GA。プロジェクトは再開したと %name1% に伝えに行って%JV_KUDASAI。>
		Prompt1 <原因に心当たりは？>
		Prompt2 <心配無用、こっちで何とかする%JV_F_WA。>
		Prompt3 <もう一度現状を説明してもらえる？>
		Prompt4 <%JR_NO、まだ。終わったら戻ってくる%JV_F_WA。>

		MetaScene 3
		sub
			room
			desig <HOME>
			minimap <......1.2..#3#..###......>
			special <SHAREDPALETTE>
			inv
				STC COMPUTER-1
				% Using this computer may repair the robots.
				MiniMapComponent 2
				PDir 6
				use <if= PlotStatus %plotid% %id% else GoQuestFinished Print 1>
				GoQuestFinished <Print 2>
				GoWin  <Print 3 WinSubPlot %plotid% XPV 100>
				GoLose <Print 5>
				GoNothing <Print 2>
				% Code Breaking and Science allow difficult skill rolls to fix the robots
				% Repair allows a relatively easy roll to fix the robots
				Clue_REPAIR        <if= PlotStatus %plotid% %id% else GoNothing  ifRepair        SkillTar %threat% else GoLose      Goto GoWin>
				Clue_SCIENCE       <if= PlotStatus %plotid% %id% else GoNothing  ifScience       HardSkillTar %threat% else GoLose  Goto GoWin>
				Clue_CODEBREAKING  <if= PlotStatus %plotid% %id% else GoNothing  ifCodeBreaking  HardSkillTar %threat% else GoLose  Goto GoWin>
				% Msg1 <This computer controls the robots for the construction site. The lights on its display are blinking wildly.>
				% Msg2 <This computer controls the robots for the construction site.>
				% Msg3 <You repair the computer and deactivate the malfunctioning robots.>
				% Msg5 <You can't repair this computer at your current skill level.>
				Msg1 <ここの建築用ロボットの制御用コンピュータだ。ディスプレイ上の表示が荒々しく点滅している。>
				Msg2 <このコンピュータがここの建築用ロボットを制御している。>
				Msg3 <コンピュータを修理して、暴走しているロボットを停止させた。>
				Msg5 <現在のスキルレベルではこのコンピュータを修理することはできない。>

				StairsDown
				desig <ENTRANCE %4%>
				MiniMapComponent 3
			end
		end

		MetaScene 4
		name <%name3%'s Basement>
		name_I18N <%name3% 地下>
		type <Basement Private>
		terrain <GROUND>
		special <NOEXIT>

		BoxMap
		MapWidth 17
		MapHeight 17
		RockyTiles

		NeededCells 3
		content <Fill Sub *STORAGE_X na>

		% L1 = Robots destroyed counter
		% L2 = Monster generation counter
		Start <Print 1 if= L2 0 if= PlotStatus %plotid% %id% L= 2 1 WMonster 2 %threat% 200>
		nu2 <if= T2 0 if= PlotStatus %plotid% %id% Print 2 XPV 100 SetPlotStatus %plotid% -1  L= 1 1>
		% Msg1 <You enter the robot construction site.>
		% Msg2 <That appears to be the last of the robots.>
		Msg1 <建築ロボットの作業現場に入った。>
		Msg2 <今のが最後のロボットだったようだ。>
		sub
			Room
			sub
				StairsUp
				Destination -1
			end

			Team 1
			SetEnemy 2

			Team 2
			name <Enemies>
			SetEnemy 1
			type <Robot>
		end
	end
	inv
		NPC Construction Worker
		job <Robot Wrangler>
		Science 5
	end


%%
%%  *:Q_DEBUG
%%
%%  This quest will load a debug construction problem and activate it.
%%

Content
	name <Debugging Frame>
	requires <*:Q_DEBUG>

	% E1 is the person who will be giving the mission.
	% E2 is the CavClub
	% E3 is the urban scene
	% E4 is the constuction site
	Element1 <NewNPC 0 0>
	Place1 <2 (Citizens) ally pass>
	Element2 <Scene CavClub>
	Element3 <Scene Urban>
	Element4 <QuestScene>
	Place4 <3>

	% SubPlot1 is the mission.
	subplot1 <*:Q_DConstructionProblem 1 4>

	sub
		Persona 1
		% rumor0 <%name1% needs a cavalier for a mission of some kind.>
		rumor0 <%name1% は何かのミッションにメック乗りを必要としている>
		greeting <if= PlotStatus %plotid% %id% else GoCheckFirst if= PlotStatus %plotid1% -1 else GoCheckLoss NewChat Say 1 SetPlotStatus %plotid% -1>
		GoCheckLoss <if= PlotStatus %plotid1% -2 else GoCheckFirst SetPlotStatus %plotid% -2 Goto GoEndInLoss>
		*GoEndInLoss <*MissionWasFailure na na na>
		GoCheckFirst <if= PlotStatus %plotid% 0 else GoChat Goto GoOfferQuest>
		*GoOfferQuest <*DoYouWantAJob GoStartQuest>
		GoStartQuest <SetPlotStatus %plotid% %id% SetPlotStatus %plotid1% %id1% EndChat Say 2 Exit %4% SeekGate %3%>
		GoChat <NewChat SayAnything>
		% Msg1 <I hear that you succeeded. The debugging of the mission is now over.>
		% Msg2 <Return here after solving the construction problem for absolutely nothing.>
		Msg1 <成功したらしいな。ミッションのデバッグは終了だ。>
		Msg2 <建設の問題を解決したらここに戻れ。一切何も得られない。>

		MetaScene 1
		sub
			room
			desig <HOME>
			minimap <#&&&#&...&&.1.&&...&&&-&&>
		end

		STC QS_ConstructionSite
		name <the # Project>
		name_I18N <プロジェクト・#>
		entrance <*BUILDING>
		SetID 4
	end

