//================================================================= public override FSNSnapshot.Layer GenerateNextLayerImage(FSNSnapshot.Layer curLayer, params FSNProcessModuleCallParam[] callParams) { FSNSnapshot.Layer newLayer = curLayer.Clone(); foreach (var callParam in callParams) { if (callParam.segment.type == FSNScriptSequence.Segment.Type.Text) // ** 텍스트 세그먼트 처리 ** { var textSeg = callParam.segment as Segments.Text; // 타입 변환 switch (textSeg.textType) // * 텍스트 종류에 따라 처리 분기 { case Segments.Text.TextType.Normal: AddNormalText(newLayer, textSeg, callParam.setting); break; case Segments.Text.TextType.Clear: ClearTextsToDirection(newLayer, callParam.setting.CurrentFlowDirection); break; case Segments.Text.TextType.Options: ClearTextsToDirection(newLayer, callParam.setting.CurrentFlowDirection); // 선택지 텍스트는 clear를 먼저 한 뒤에 표시 ShowOptionTexts(newLayer, textSeg, callParam.setting); break; case Segments.Text.TextType.LastOption: AddLastOptionText(newLayer, textSeg, callParam.setting); break; } } else if (callParam.segment.type == FSNScriptSequence.Segment.Type.Control && (callParam.segment as Segments.Control).controlType == Segments.Control.ControlType.Clear) // Clear 명령에 반응 { ClearTextsToDirection(newLayer, callParam.setting.CurrentFlowDirection); } else if (callParam.segment.type == FSNScriptSequence.Segment.Type.HardClone) // 레이어 Hard-Clone { newLayer.MakeAllElemsHardClone(); } } return(newLayer); }