18 lines
429 B
Vue
18 lines
429 B
Vue
<script setup lang="ts">
|
|
const { onRender } = useScreen();
|
|
const store = useAchievementsScreen();
|
|
|
|
onRender((ctx) => {
|
|
if (!store.fadeToBlack.active) return;
|
|
if (store.fadeToBlack.isOutro && store.fadeToBlack.opacity === 0) return;
|
|
|
|
ctx.globalAlpha = store.fadeToBlack.opacity;
|
|
ctx.fillStyle = "#000000";
|
|
ctx.fillRect(0, 0, LOGICAL_WIDTH, LOGICAL_HEIGHT);
|
|
}, 9999);
|
|
|
|
defineOptions({
|
|
render: () => null,
|
|
});
|
|
</script>
|