On 3/3/01 5:27 AM, Sandro Boege ([EMAIL PROTECTED]) sent:
>what i would like to do is, place the 3 answers in random text fields,
>to prevent that the first answer is always the correct answer.

Not knowing your member or sprite layout, and for added flexibility, 
we'll get the fields you want to use from lists rather than member or 
sprite numbers. 

  --list of screen fields
  fieldList = [member("screenAnsA"), member("screenAnsB"), 
member("screenAnsC")]
  --list of original answers
  ansList = [member("origAnsA").text, member("origAnsB").text, 
member("origAnsC").text]
  repeat with x = 1 to 3
    ans = ansList[x]
    y = random(fieldList.count)
    fieldList[y].text = ans
    fieldList.deleteAt(y)
  end repeat

There are easier ways of doing this, but not without knowing/changing 
your sprite/cast layout.

Rich Shupe

[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi  To post messages to the list,
email [EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo.  Thanks!]

Reply via email to