Can someone make me a tappable overlay timer template?


#1

Can someone make me a tappable overlay timer template?

I can use them, I just need this.

We can do it, together if you want.

I just don’t have any idea how to start it off.

Would you like to co-code?? We can do that.


#2

Do you mean for timed choices or something else?


#3

Timed choices


#4

Okay, cool, I’ll send you mine.


#5

Oh, awesome, Thank you! :smiley:


#6

Okay, so I’m going to assume that we’re in zone 1 for this. If you’re in a different zone, change the numbers accordingly.

First you need to create overlays that look like regular episode choices, like such:

pv1_back_OPTION1_5660980839186432_c7b177a94a8b81021b4649b2b0d92d99

You would place the options like this, just like with regular overlays. The tappable part comes later. Create as many as you want.

@overlay OPTION1 create AND overlay OPTION1 scales to 1.0 1.0 AND overlay OPTION1 shifts to 20 215 AND overlay OPTION1 opacity 1.0
@overlay OPTION2 create AND overlay OPTION2 scales to 1.0 1.0 AND overlay OPTION2 shifts to 20 165 AND overlay OPTION2 opacity 1.0
@overlay OPTION3 create AND overlay OPTION3 scales to 1.0 1.0 AND overlay OPTION3 shifts to 20 115 AND overlay OPTION3 opacity 1.0

Then create a timer. It can look any way you want as long as the reader can see how much time they have left.

This is the slapdash one I just kind of threw together.
timer3timer2timer1timer0timeup

The timer overlays are not tappables, they’re just regular overlays. Place them directly on top of each other, like such:

@overlay TIMER0 create AND overlay TIMER0 scales to 1.0 1.0 AND overlay TIMER0 shifts to 110 300 in zone 1 AND overlay TIMER0 opacity 0
@overlay TIMER1 create AND overlay TIMER1 scales to 1.0 1.0 AND overlay TIMER1 shifts to 110 300 in zone 1 AND overlay TIMER1 opacity 0
@overlay TIMER2 create AND overlay TIMER2 scales to 1.0 1.0 AND overlay TIMER2 shifts to 110 300 in zone 1 AND overlay TIMER2 opacity 0
@overlay TIMER3 create AND overlay TIMER3 scales to 1.0 1.0 AND overlay TIMER3 shifts to 70 300 in zone 1 AND overlay TIMER3 opacity 1
@overlay TIME UP create AND overlay TIME UP scales to 1.0 1.0 AND overlay TIME UP shifts to 110 300 in zone 1 AND overlay TIME UP opacity 0

Now for the important part of the code that makes it behave like a timed choice.

&pause for 1.0 THEN overlay TIMER2 opacity 1.0 AND overlay TIMER3 clear THEN pause for 1.0 THEN overlay TIMER1 opacity 1.0 AND overlay TIMER2 clear THEN pause for 1.0 THEN overlay TIMER0 opacity 1.0 AND overlay TIMER1 clear THEN pause for 0.5 THEN overlay TIMER0 clear AND overlay OPTION1 shifts to 20 600 in zon2 1 AND overlay OPTION2 shifts to 20 600 in zone 1 AND overlay OPTION3 shifts to 20 215 in zone 1 AND overlay TIME UP opacity 1.0

The purpose of this code is to options 1 and 2 off the screen so you can’t see them anymore, leaving option 3 (the “time’s up” option) as the only clickable option on the screen.

The tappable part would just work like this:

tappable “OPTION1” {
@overlay TIMER0 shifts to 110 600 in zone 1 AND overlay TIMER1 shifts to 110 600 in zone 1 AND overlay TIMER2 shifts to 110 600 in zone 1 AND overlay TIMER3 shifts to 110 600 in zone 1 AND overlay TIME UP shifts to 70 600 in zone 1
@overlay OPTION1 opacity 0 AND overlay OPTION2 opacity 0 AND overlay OPTION3 opacity 0
NARRATOR
You clicked option 1.

} “OPTION2” {
@overlay TIMER0 shifts to 110 600 in zone 1 AND overlay TIMER1 shifts to 110 600 in zone 1 AND overlay TIMER2 shifts to 110 600 in zone 1 AND overlay TIMER3 shifts to 110 600 in zone 1 AND overlay TIME UP shifts to 70 600 in zone 1
@overlay OPTION1 opacity 0 AND overlay OPTION2 opacity 0 AND overlay OPTION3 opacity 0

NARRATOR
You clicked option 2.

} “OPTION3” {
@overlay TIMER0 shifts to 110 600 in zone 1 AND overlay TIMER1 shifts to 110 600 in zone 1 AND overlay TIMER2 shifts to 110 600 in zone 1 AND overlay TIMER3 shifts to 110 600 in zone 1 AND overlay TIME UP shifts to 70 600 in zone 1
@overlay OPTION1 opacity 0 AND overlay OPTION2 opacity 0 AND overlay OPTION3 opacity 0

NARRATOR
You clicked option 3… too slow, Joe.
}


#7

Here is the whole script without any notes in between:

EXT. BLACK ONE PANEL - NIGHT
@overlay TIMER0 create AND overlay TIMER0 scales to 1.0 1.0 AND overlay TIMER0 shifts to 110 300 in zone 1 AND overlay TIMER0 opacity 0
@overlay TIMER1 create AND overlay TIMER1 scales to 1.0 1.0 AND overlay TIMER1 shifts to 110 300 in zone 1 AND overlay TIMER1 opacity 0
@overlay TIMER2 create AND overlay TIMER2 scales to 1.0 1.0 AND overlay TIMER2 shifts to 110 300 in zone 1 AND overlay TIMER2 opacity 0
@overlay TIMER3 create AND overlay TIMER3 scales to 1.0 1.0 AND overlay TIMER3 shifts to 110 300 in zone 1 AND overlay TIMER3 opacity 1
@overlay TIME UP create AND overlay TIME UP scales to 1.0 1.0 AND overlay TIME UP shifts to 70 300 in zone 1 AND overlay TIME UP opacity 0
@overlay OPTION1 create AND overlay OPTION1 scales to 1.0 1.0 AND overlay OPTION1 shifts to 20 215 AND overlay OPTION1 opacity 1.0
@overlay OPTION2 create AND overlay OPTION2 scales to 1.0 1.0 AND overlay OPTION2 shifts to 20 165 AND overlay OPTION2 opacity 1.0
@overlay OPTION3 create AND overlay OPTION3 scales to 1.0 1.0 AND overlay OPTION3 shifts to 20 115 AND overlay OPTION3 opacity 1.0

&pause for 1.0 THEN overlay TIMER2 opacity 1.0 AND overlay TIMER3 clear THEN pause for 1.0 THEN overlay TIMER1 opacity 1.0 AND overlay TIMER2 clear THEN pause for 1.0 THEN overlay TIMER0 opacity 1.0 AND overlay TIMER1 clear THEN pause for 0.5 THEN overlay TIMER0 clear AND overlay OPTION1 shifts to 20 600 in zone 1 AND overlay OPTION2 shifts to 20 600 in zone 1 AND overlay OPTION3 shifts to 20 215 in zone 1 AND overlay TIME UP opacity 1.0

tappable “OPTION1” {
@overlay TIMER0 shifts to 110 600 in zone 1 AND overlay TIMER1 shifts to 110 600 in zone 1 AND overlay TIMER2 shifts to 110 600 in zone 1 AND overlay TIMER3 shifts to 110 600 in zone 1 AND overlay TIME UP shifts to 70 600 in zone 1
@overlay OPTION1 opacity 0 AND overlay OPTION2 opacity 0 AND overlay OPTION3 opacity 0
NARRATOR
You clicked option 1.

} “OPTION2” {
@overlay TIMER0 shifts to 110 600 in zone 1 AND overlay TIMER1 shifts to 110 600 in zone 1 AND overlay TIMER2 shifts to 110 600 in zone 1 AND overlay TIMER3 shifts to 110 600 in zone 1 AND overlay TIME UP shifts to 70 600 in zone 1
@overlay OPTION1 opacity 0 AND overlay OPTION2 opacity 0 AND overlay OPTION3 opacity 0

NARRATOR
You clicked option 2.

} “OPTION3” {
@overlay TIMER0 shifts to 110 600 in zone 1 AND overlay TIMER1 shifts to 110 600 in zone 1 AND overlay TIMER2 shifts to 110 600 in zone 1 AND overlay TIMER3 shifts to 110 600 in zone 1 AND overlay TIME UP shifts to 70 600 in zone 1
@overlay OPTION1 opacity 0 AND overlay OPTION2 opacity 0 AND overlay OPTION3 opacity 0

NARRATOR
You clicked option 3… too slow, Joe.
}


#8

And a few notes:

  1. The reason I move the options off the screen or change their opacity instead of just clearing them is because sometimes clearing tappable overlays before they’re pressed can result in an error. This might be fixed later when they’re out of beta (and thanks to @EliseC for bringing this to my attention!)
    Same for the timer overlays: If you choose an option really fast and the timer overlays are cleared before they can finish counting down, the code will still try to run as if they’re there, but it won’t be able to find them, which would result in an error message. You can clear them later in the scene or just leave them there until the scene changes and they’re cleared automatically.

  2. To make the “choice” overlays, I just made a regular choice in my story, opened it on mobile previewer, took a screenshot on my phone, emailed it to myself, then cut out the choices in photoshop and turned them into PNGs so I could upload them as overlays.

  3. The placement for the timers and “choice” overlays may not work for any overlays you upload yourself, so it’ll be up to you to check your script and make sure they’re placed correctly and looking good!

  4. You could also place a special option 4 off screen to start with (an option that the player only gets if the timer finishes counting down before they can click something) and then move it onto the screen once the timer finishes, and remove all of options 1, 2 and 3 instead of leaving one of them as the “time up” choice.
    To do that, you’d just use these extra lines of code:

When you’re placing the option overlays:
@overlay OPTION4 create AND overlay OPTION4 scales to 1.0 1.0 AND overlay OPTION4 shifts to 20 600 AND overlay OPTION4 opacity 1.0

The countdown code would change to this:
&pause for 1.0 THEN overlay TIMER2 opacity 1.0 AND overlay TIMER3 clear THEN pause for 1.0 THEN overlay TIMER1 opacity 1.0 AND overlay TIMER2 clear THEN pause for 1.0 THEN overlay TIMER0 opacity 1.0 AND overlay TIMER1 clear THEN pause for 0.5 THEN overlay TIMER0 clear AND overlay OPTION1 shifts to 20 600 in zone 1 AND overlay OPTION2 shifts to 20 600 in zone 1 AND overlay OPTION3 shifts to 20 600 in zone 1 AND overlay OPTION4 shifts to 20 215 AND overlay TIME UP opacity 1.0

And you would of course add an extra option on to the end of the tappable code:

“OPTION4” {
@overlay TIME UP clear

NARRATOR
You didn’t pick a choice and now you’re about to face the consequences. :slight_smile: :slight_smile: :slight_smile:
}