# id 450001380 (Hidden Street : Split Road of Destiny), field 450001380
CUTSCENEDONE = "CutSceneDone"
if not field.hasProperty(CUTSCENEDONE):
    sm.createQuestWithQRValue(34125, "370=2;380=1;390=2;310=2;320=2;330=2")
    sm.lockInGameUI(True, False)
    sm.removeAdditionalEffect()
    sm.blind(True, 255, 0, 0, 0, 0)
    sm.spawnNpc(3003113, -270, 165)
    sm.showNpcSpecialActionByTemplateId(3003113, "summon", 0)
    sm.spawnNpc(3003112, 175, 165)
    sm.showNpcSpecialActionByTemplateId(3003112, "summon", 0)
    sm.resetNpcSpecialActionByTemplateId(3003113)
    sm.showNpcSpecialActionByTemplateId(3003113, "damaged", -1)
    sm.zoomCamera(0, 2000, 0, 100, 206)
    sm.sendDelay(1000)
    sm.blind(False, 0, 0, 0, 0, 1500)
    sm.setSpeakerType(3)
    sm.setParam(37)
    sm.setColor(1)
    sm.setInnerOverrideSpeakerTemplateID(3003112) # Rino
    sm.sendNext("Here's the exit! And look, there are no Slaws blocking this path.")
    sm.sendSay("This way, go on--")
    sm.forcedMove(False, 30)
    sm.sendDelay(1000)
    sm.playSound("Sound/Foot.img/cave/0", 200)
    sm.sendDelay(500)
    sm.playSound("Sound/Foot.img/cave/1", 200)
    sm.sendDelay(300)
    sm.playSound("Sound/Foot.img/cave/2", 200)
    sm.sendDelay(500)
    sm.playSound("Sound/Foot.img/cave/1", 200)
    sm.sendDelay(300)
    sm.setInnerOverrideSpeakerTemplateID(3003113) # Kao
    sm.sendNext("...Stop!")
    sm.changeBGM("SoundEff.img/ArcaneRiver/thrill", 0, 0)
    sm.zoomCamera(1500, 1000, 1500, 20, 106)
    sm.forcedMove(True, 20)
    sm.sendDelay(1000)
    sm.sendDelay(1000)
    sm.sendNext("...You can't go that way!")
    sm.sendDelay(500)
    sm.showFadeTransition(0, 1000, 1000)
    sm.sendDelay(500)
    sm.zoomCamera(0, 2000, 0, -300, 200)
    sm.removeOverlapScreen(500)
    sm.sendDelay(500)
    sm.zoomCamera(4000, 2000, 4000, -50, 200)
    sm.sendNext("#h0#, you have to believe me. Rino's leading you into a trap.")
    sm.sendSay("The Fountain of Reflection... That's where I found my missing memories, and learned the truth about Rino.")
    sm.sendSay("...And learned how I lost my memories in the first place!")
    sm.blind(True, 255, 0, 0, 0, 250)
    sm.sendDelay(250)
    sm.lockInGameUI(False, True)
    sm.warp(450001300)
    field.setProperty(CUTSCENEDONE, True)
else:
    sm.lockInGameUI(True, False)
    sm.spawnNpc(3003113, -270, 165)
    sm.spawnMob(8641010, 658, 177, False)
    sm.showNpcSpecialActionByTemplateId(3003113, "summon", 0)
    sm.lockInGameUI(False, True)
    while sm.hasMobsInField():
        sm.waitForMobDeath()

sm.warp(450001340)

