|
|
@ -37,9 +37,10 @@ public class ScreenStory extends RogueScreen implements MouseButtonHandler { |
|
|
|
private final TextPainter tp1; |
|
|
|
private final TextPainter tp1; |
|
|
|
private final TextPainter tp2; |
|
|
|
private final TextPainter tp2; |
|
|
|
private final ImagePainter img; |
|
|
|
private final ImagePainter img; |
|
|
|
private final NumAnimated layerAlpha = new NumAnimated(0, Easing.LINEAR, 0.8); |
|
|
|
private final NumAnimated layerAlpha = new NumAnimated(0, Easing.QUARTIC_OUT, 0.6); |
|
|
|
private final NumAnimated tx1alpha = new NumAnimated(0, Easing.LINEAR, 1); |
|
|
|
private final NumAnimated tx1alpha = new NumAnimated(0, Easing.BOUNCE_OUT, 1); |
|
|
|
private final NumAnimated tx2alpha = new NumAnimated(0, Easing.LINEAR, 1); |
|
|
|
private final NumAnimated tx2alpha = new NumAnimated(0, Easing.BOUNCE_OUT, 1); |
|
|
|
|
|
|
|
private final NumAnimated txProceedAlpha = new NumAnimated(0, Easing.CIRC_OUT, 1); |
|
|
|
|
|
|
|
|
|
|
|
private String nextImg, nextT1, nextT2; |
|
|
|
private String nextImg, nextT1, nextT2; |
|
|
|
|
|
|
|
|
|
|
@ -54,6 +55,7 @@ public class ScreenStory extends RogueScreen implements MouseButtonHandler { |
|
|
|
|
|
|
|
|
|
|
|
tx1alpha.setTo(0); |
|
|
|
tx1alpha.setTo(0); |
|
|
|
tx2alpha.setTo(0); |
|
|
|
tx2alpha.setTo(0); |
|
|
|
|
|
|
|
txProceedAlpha.setTo(0); |
|
|
|
|
|
|
|
|
|
|
|
layerAlpha.setTo(0); |
|
|
|
layerAlpha.setTo(0); |
|
|
|
layerAlpha.fadeIn(); |
|
|
|
layerAlpha.fadeIn(); |
|
|
@ -84,7 +86,7 @@ public class ScreenStory extends RogueScreen implements MouseButtonHandler { |
|
|
|
ttFinish.run(); |
|
|
|
ttFinish.run(); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
tx2alpha.fadeIn(); |
|
|
|
tx2alpha.fadeIn(); |
|
|
|
ttFinish.start(5); |
|
|
|
ttFinish.start(1.2); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|
}; |
|
|
@ -94,7 +96,7 @@ public class ScreenStory extends RogueScreen implements MouseButtonHandler { |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void run() |
|
|
|
public void run() |
|
|
|
{ |
|
|
|
{ |
|
|
|
//next.run();
|
|
|
|
txProceedAlpha.fadeIn(); |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
@ -105,7 +107,7 @@ public class ScreenStory extends RogueScreen implements MouseButtonHandler { |
|
|
|
{ |
|
|
|
{ |
|
|
|
super(screen); |
|
|
|
super(screen); |
|
|
|
|
|
|
|
|
|
|
|
TextPainter help = new TextPainter(Res.getFont("tiny"), AlignX.CENTER, RGB.WHITE.withAlpha(0.3), "Space / click to proceed."); |
|
|
|
TextPainter help = new TextPainter(Res.getFont("tiny"), AlignX.CENTER, RGB.WHITE.withAlpha(txProceedAlpha.mul(0.3)), "Space / click to proceed."); |
|
|
|
help.setRect(root.bottomEdge().growUp(root.height().perc(4))); |
|
|
|
help.setRect(root.bottomEdge().growUp(root.height().perc(4))); |
|
|
|
help.setVPaddingPercent(5); |
|
|
|
help.setVPaddingPercent(5); |
|
|
|
root.add(help); |
|
|
|
root.add(help); |
|
|
@ -129,8 +131,10 @@ public class ScreenStory extends RogueScreen implements MouseButtonHandler { |
|
|
|
tp2.setVPaddingPercent(19); |
|
|
|
tp2.setVPaddingPercent(19); |
|
|
|
|
|
|
|
|
|
|
|
updated.add(layerAlpha); |
|
|
|
updated.add(layerAlpha); |
|
|
|
|
|
|
|
updated.add(txProceedAlpha); |
|
|
|
updated.add(tx1alpha); |
|
|
|
updated.add(tx1alpha); |
|
|
|
updated.add(tx2alpha); |
|
|
|
updated.add(tx2alpha); |
|
|
|
|
|
|
|
|
|
|
|
updated.add(ttText1); |
|
|
|
updated.add(ttText1); |
|
|
|
updated.add(ttText2); |
|
|
|
updated.add(ttText2); |
|
|
|
updated.add(ttFinish); |
|
|
|
updated.add(ttFinish); |
|
|
|