| View previous topic :: View next topic |
| Author |
Message |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Tue Jun 13, 2006 4:50 am Post subject: Announce: Tarot script |
|
|
A New, original script by yours trully
| Code: |
###################################################################
# Tarot.tcl by Rosc (copyright C.Leonhardt 2006) rosc2112 at yahoo com
# http://members.dandy.net/~fbn/tarot.tcl.txt
#
# The *first* eggdrop tcl tarot script, well, at least the first I've seen ;)
# I whipped this up in about an hour, most of which was writing the card descriptions.
#
# Commands:
# .tarot 1 or .tarot single for a 1-card spread
# .tarot 3 or .tarot for a 3-card spread
# .tarot help brief helpfile
#
# History:
# June 10 2006 - Initial creation.
###################################################################
|
Will upload to the archive as well. |
|
| Back to top |
|
 |
chelle21 Voice
Joined: 29 Sep 2006 Posts: 3
|
Posted: Fri Sep 29, 2006 7:43 am Post subject: |
|
|
Tcl error [tarot]: bad format string "%s"
it appears when i try to do the tarot reading |
|
| Back to top |
|
 |
De Kus Revered One

Joined: 15 Dec 2002 Posts: 1361 Location: Germany
|
Posted: Fri Sep 29, 2006 9:11 am Post subject: |
|
|
You will help the author when posting the full error from errorInfo and your TCL version. If the error occurs within a format or scan it should be not bad for anything 8.x at least. _________________ De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens... |
|
| Back to top |
|
 |
chelle21 Voice
Joined: 29 Sep 2006 Posts: 3
|
Posted: Fri Sep 29, 2006 11:49 am Post subject: |
|
|
| Edited: You were asked to post the results of '.set errorInfo' not post something that is already known (the script) - Alchera |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Fri Sep 29, 2006 4:51 pm Post subject: |
|
|
| chelle21 wrote: | Tcl error [tarot]: bad format string "%s"
it appears when i try to do the tarot reading |
I have the script, I don't need to see another copy of it. I need to see the output of .set errorInfo and I need to know what version of eggdrop and tcl you're using.
The script works fine for me, so if there is an error with the "format" command, I'd suspect it's your version of eggdrop and/or tcl. |
|
| Back to top |
|
 |
De Kus Revered One

Joined: 15 Dec 2002 Posts: 1361 Location: Germany
|
Posted: Fri Sep 29, 2006 5:14 pm Post subject: |
|
|
I just looked over the TCL man pages and it seems %s for clock came with TCL 8.4, so you are encuraged to upgrade. If not possible just remove the clock format and just make [unixtime] the seed for the "randomness". _________________ De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens... |
|
| Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Fri Sep 29, 2006 5:38 pm Post subject: |
|
|
Thanks De Kus, I didn't realize the clock format command was only in the newer tcl's, so I made the following minor change to the script:
| Code: |
# newer tcl's can use the clock format command.
#set tarotseed [clock format [clock seconds] -format "%s"]
set tarotseed [unixtime]
|
I'll upload the fix as well to the url posted above for the script. |
|
| Back to top |
|
 |
De Kus Revered One

Joined: 15 Dec 2002 Posts: 1361 Location: Germany
|
Posted: Sat Sep 30, 2006 7:05 am Post subject: |
|
|
clock format is older, but the format string %s is kind of new... well tcl 8.4 isnt actually really new . _________________ De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens... |
|
| Back to top |
|
 |
chelle21 Voice
Joined: 29 Sep 2006 Posts: 3
|
Posted: Sat Sep 30, 2006 10:06 am Post subject: |
|
|
that worked. thank u guys. sorry for being a newbie  |
|
| Back to top |
|
 |
elamont Voice
Joined: 20 Feb 2007 Posts: 1
|
Posted: Tue Feb 20, 2007 2:50 pm Post subject: |
|
|
Thanks so much for asking that question. I was wondering the same thing.
Erin
EDIT: removed spam links - user |
|
| Back to top |
|
 |
metroid Owner
Joined: 16 Jun 2004 Posts: 771
|
Posted: Wed Feb 21, 2007 2:54 pm Post subject: |
|
|
not sure if you know, but [clock format [clock seconds] -format %s] is infact the exact same as [clock seconds]  |
|
| Back to top |
|
 |
|