;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;






[@SinQuest_Start]
{
#ACT
FormatStr "FLD_SINUSERNAME='%s'" %USERNAME

ReadValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINUSERNAME,FLD_SINMAINSTEP,FLD_SINSTEP_READY" [@SinQuest_Start_0]

[@SinQuest_Start_0()]
#ACT
mov A1 %ARG(1)
mov D1 %ARG(2)
mov D2 %ARG(3)



#IF
Equal A1 ""

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_0

#ACT
break

#IF
Equal D1 3
Equal D2 1
#ACT
goto @SinQuest_Ending_3
break

#IF
Equal D1 3
Equal D2 0
#ACT
goto @SinQuest_Ending_2
break

#IF
Equal D1 2
Equal D2 1
#ACT
goto @SinQuest_diary_0_4
break

#IF
Equal D1 2
Equal D2 0
#ACT
goto @SinQuest_diary_2
break

#IF
Equal D1 1
Equal D2 2
#ACT
goto @SinQuest_1_6
break

#IF
Equal D1 1
Equal D2 0
#ACT
goto @SinQuest_Start_1
break

#IF

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_1

#ACT
break

[@SinQuest_Start_1]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_2

[@SinQuest_0_2]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_3

[@SinQuest_0_3]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_4

[@SinQuest_0_4]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_5

[@SinQuest_0_5]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_6

[@SinQuest_0_5]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_7

[@SinQuest_0_6]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_8

[@SinQuest_0_7]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_9

[@SinQuest_0_8]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_10

[@SinQuest_0_9]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_11

[@SinQuest_1_0]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_12

[@SinQuest_1_1]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_13

[@SinQuest_1_2]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_14

[@SinQuest_1_3]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_15

[@SinQuest_9_0]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_16

[@SinQuest_1_4]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_17

[@SinQuest_1_5]
#IF
#ACT
FormatStr "FLD_SINUSERNAME='%s'" %USERNAME
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINMAINSTEP=1"
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINSTEP_READY=2"
give 魔灵牌 1

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_18

[@SinQuest_1_6]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_19

[@SinQuest_diary_2]
#IF
checkitem 航海日志 1

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_20


#ELSESAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_21

[@SinQuest_diary_0_1]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_22

[@SinQuest_diary_0_2]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_23

[@SinQuest_diary_0_3]
#IF
checkitem 航海日志 1

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_24

#ACT
goto @SQ_SemiReward_1
break
#ELSEACT
break

#ELSESAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_25

[@SQ_SemiReward_1]
#IF
checkjob warrior
#ACT
mov A0 "SinGiSun"
mov D0 1
mov D1 0
mov D2 0
mov D3 0
goto @EveryThingReward
take 航海日志 1
FormatStr "FLD_SINUSERNAME='%s'" %USERNAME
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINMAINSTEP=2"
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINSTEP_READY=1"
break

#ELSEACT
goto @SD_SemiReward_2
break

[@SD_SemiReward_2]
#IF
checkjob wizard
#ACT
mov A0 "SinGiSun"
mov D0 1
mov D1 1
mov D2 0
mov D3 0
goto @EveryThingReward
take 航海日志 1
FormatStr "FLD_SINUSERNAME='%s'" %USERNAME
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINMAINSTEP=2"
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINSTEP_READY=1"
break

#ELSEACT
mov A0 "SinGiSun"
mov D0 1
mov D1 2
mov D2 0
mov D3 0
goto @EveryThingReward
take 航海日志 1
FormatStr "FLD_SINUSERNAME='%s'" %USERNAME
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINMAINSTEP=2"
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINSTEP_READY=1"
break

[@SinQuest_diary_0_4]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_26

[@SinQuest_Ending_2]
#IF
checkitem 遗骸 1
#ACT
mov A0 "SinGiSun"
mov D0 3
mov D1 1
mov D2 0
mov D3 0
goto @EveryThingReward
take 遗骸 1
FormatStr "FLD_SINUSERNAME='%s'" %USERNAME
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINMAINSTEP=3"
UpdateValueSql "TBL_SinGiSunQuest" %A9 "FLD_SINSTEP_READY=1"
set [204] 1

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_27


#ELSESAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_28

#ELSEACT
break

[@SinQuest_Ending_3]

#SAY
#INCLUDE [..\Convert_Def\QuestDiary\SinGiSun\SinHyunMiNpc.txt] @Convert_SinHyunMiNpc_29

}
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;