Digital Workshop

Welcome to the Digital Workshop Message Boards
It is currently November 15th, 2024, 11:55 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: two teams changed
PostPosted: March 28th, 2007, 7:58 pm 
Offline

Joined: September 11th, 2006, 2:38 pm
Posts: 125
I designed an eductional game for two teams.I have two pages the first page has buttons like Q! Q2 Q3 Q4 ..etc . the second page has the question (reading).I want if i clike on the button q1 and go to the second page when i return to the first page this will be the cue of the second team and so on.
teamA then teamB then teamA then team b and so on.
How can this be done?


For this message opuslover has been thanked by : mackavi


Top
 Profile  
 
 Post subject: If Else
PostPosted: March 29th, 2007, 10:22 am 
Offline
Godlike
Godlike
User avatar

Joined: March 21st, 2007, 10:44 am
Posts: 3188
Location: UK
Opus: Evolution
Hi OpusLover,

If you are simply trying to keep track of which teams turn it is, then store it in a variable and use and if else

var myTurnText // set this at pub run
var myTurn ='A' // set this at pub run


//Run this when you load the second page

function theTurn ()
{
if (myTurn == 'A')
{
myTurnText = 'Team A Turn'
myTurn = 'B'
}
else
{
myTurnText = 'Team B Turn'
myTurn = 'A'
}

//Display myTurnText in a text Box on page two!


Top
 Profile Visit website  
 
 Post subject:
PostPosted: April 1st, 2007, 10:17 am 
Offline

Joined: September 11th, 2006, 2:38 pm
Posts: 125
mac Thanks as usual you're the fastest to answer. But as I told you i'm a novice specially in Function .I knw the sentax and how to call it. But i need more explanation if you can or a small example.


For this message opuslover has been thanked by : mackavi


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Google [Bot] and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group