# Trying to make something like a visual novel with a lot of booleans

**URL:** https://discourse.processing.org/t/trying-to-make-something-like-a-visual-novel-with-a-lot-of-booleans/22633
**Category:** Coding Questions
**Created:** [July 15, 2020, 10:48am UTC](https://discourse.processing.org/t/trying-to-make-something-like-a-visual-novel-with-a-lot-of-booleans/22633 "2020-07-15T10:48:57Z")
**Posts on this page:** 1
**Showing post:** 8

<div class="post-metadata">

### Author: ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)
#### Post date: [July 16, 2020, 11:47am UTC](https://discourse.processing.org/t/trying-to-make-something-like-a-visual-novel-with-a-lot-of-booleans/22633/8 "2020-07-16T11:47:27Z")

</div>

Hello,

I often use these:

> **[keyPressed() / Reference](https://www.processing.org/reference/keyPressed_.html)**
>
> The keyPressed() function is called once every time a key is pressed. The key that was pressed is stored in the key variable. For non-ASCII keys, use the keyCode varia…

> **[case / Reference](https://processing.org/reference/case.html)**
>
> Denotes the different names to be evaluated with the parameter in the switch structure.

> **[case / Reference](https://processing.org/reference/case.html)**
>
> Denotes the different names to be evaluated with the parameter in the switch structure.

And weave a web of code to unleash my creative vision.

In this example it is transition with time (can be a keyPressed() or other) and using case statements:

> [@Animation that transitions using frameCount](https://discourse.processing.org/t/animation-that-transitions-using-framecount/15378):
>
> A very simple example that transitions through scenes over time: // Author: GLV // Date: 2019-11-10 // Description: // Animate over time using frameCount // A very simple example that: // Uses frameCount to keep track of time // Fades in and out by modifying alpha component of HSB color // Cycles through HSB colors int scene = 0; int sec = 60; float alpha = 0; void setup() { size(500, 500); textSize(36); textAlign(CENTER, CENTER); colorMode(HSB, 360, 100, 100, 100); } void draw()…

`:)`

---

_[View the full topic](https://discourse.processing.org/t/trying-to-make-something-like-a-visual-novel-with-a-lot-of-booleans/22633)._
