示例#1
0
 public Reader(string[] linesToBeRead, Action onFinished)
 {
     _chatBox          = new ChatBox("", 840, DefaultFont.Value, CurrentOptions.MillisPerTextCharacter, 32);
     _chatBoxTransform = new Transform2(new Vector2(120, 912));
     _lines            = new Queue <string>(linesToBeRead);
     _onFinished       = onFinished;
     Input.On(Control.A, Advance);
     _box = new ImageBox {
         Transform = new Transform2(new Size2(1920, 1080)), Image = "Convo/ChatBox"
     };
     _chatBox.ShowMessage(_lines.Dequeue());
 }
示例#2
0
 public DialogueReader(IEnumerable <DialogueElement> lines, Action onFinished, Action <DialogueElement> onAdvance)
 {
     _chatBox          = new ChatBox("", 840, DefaultFont.Value, CurrentOptions.MillisPerTextCharacter, 32);
     _chatBoxTransform = new Transform2(new Vector2(120, 912));
     _lines            = new Queue <DialogueElement>(lines);
     _onFinished       = onFinished;
     _onAdvance        = onAdvance;
     Input.On(Control.A, Advance);
     _box = new ImageBox {
         Transform = new Transform2(new Size2(1920, 1080)), Image = "Convo/ChatBox"
     };
     _chatBox.ShowMessage(_lines.Dequeue().Line);
     _onAdvance(lines.First());
 }
示例#3
0
 public ScanDataReader(string[] linesToBeRead, Action onFinished)
 {
     _chatBox = new ChatBox("", 630, DefaultFont.Value, CurrentOptions.MillisPerTextCharacter, 32)
     {
         SoundsEnabled = false
     };
     _chatBoxTransform = new Transform2(new Vector2(260, 450));
     _lines            = new Queue <string>(linesToBeRead);
     _onFinished       = onFinished;
     Input.On(Control.A, Advance);
     _box = new ImageBox {
         Transform = new Transform2(new Vector2(0, 0), new Size2(1920, 1080)), Image = "Convo/ScanDataView"
     };
     _chatBox.ShowMessage(_lines.Dequeue());
 }