Jump to content

countdown timer


Captain Gore-tex

Recommended Posts

I am trying to set a zone where on entering a player has 30 secs of time to enter an answer to a question. Here is what I have done so far but have become stuck.

 

created a variable with value 30

 

created a timer with a set interval (not countdown) to 1 second and when a timer tick occurs to decrement it by one

 

Set the timer to start on entering zone and the question to be asked, so far so good.

 

I then move to the player input (answer to the question) this is where I become stuck

 

Can set it if the timer is greater than 0 AND the answer is correct to show a message and stop timer but then struggle to add two additional bits; if the timer is greater than 0 AND the answer is incorrect to show a message or if the timer is at 0 regardless of answer to show another different message.

 

I run out of the ability to add the AND bits.

 

Could someone post the correct conditional tests and actions to compile in what order.

 

Thanks

Link to comment

Since you're using the Builder, just do a nested IF statement; check two of the criteria and if that's good, check the other one. If everything is true, you'll enter the inner IF statement.

 

===============================================

I believe Captain Gore-tex is aware that displaying a Message Box while an Input Box is active will crash a Garmin Player. That's why he's waiting for the player to input something before checking the timer. I wanted to make a notation here for clarification.

Link to comment

Is your question 'attached' to an item or something?

 

I guess what I'm asking is, if they answer incorrectly how are you getting back to the top to ask the question again?

 

what I planned was for for a player to enter a zone which would start the timer counting down, a message box would pop up asking for an input. If it is answered correctly before the timer got to zero then the timer would stop and a congratulatory message box would open and the next zone would become active/visible. if however the incorrect answer is given but within the time a try again message is displayed, the player leaves and re-enters the zone and the question pops up again. If however the timer gets to zero a 'punishment' zone becomes active resulting in a diversion away from the route to collect different information before continuing.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...