[Tutor] Using time module to count off seconds before an event

valhalla tireseas@onetel.com
Wed Jun 18 15:21:04 2003


Hello
I am wanting to modify a guessing game script I have so that the player i=
s=20
given x number of seconds (e.g. 60 seconds) during which to guess the ans=
wer=20
before time's up and game is over.

I've read the documents at http://www.python.org/doc/lib/module-time.html=
 but=20
cannot see any description of the function I am after. It would be the=20
functional equivalent of 'sleep' except that it wouldn't sleep but would=20
rather 'count off' (actually print to stdout) the seconds for the user an=
d=20
then once these have elapsed an event would be triggered - so really the=20
inverse of sleep I suppose.

Any suggestions/pointers which function I'm looking for or - failing that=
 - a=20
work-around?

Cheers

Andy
=20
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
||  Reg. Linux User: 313143 ||
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
Sign the Petition:
http://www.PetitionOnline.com/endtcpa1/