This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

The tcl version

Old posts that have not been replied to for several years.
Locked
m
metroid
Owner
Posts: 771
Joined: Wed Jun 16, 2004 2:46 am

The tcl version

Post by metroid »

I want to make a 'you need tcl version 8.4 for this script to work' but i don't remember how it's done.

I made a sloppy attempt at it, but ofcourse this is useless with different tcl version :x

Code: Select all

if {![regexp {.*/tcl8.4|.*/tcl8.5} [info library]]} {
  putlog "ERROR: You cannot run mute.tcl without tcl version 8.4 or higher"
  } else {
  # execute script
What i'm looking for is someone to tell me how it's done properly :)
I remember there was something with package require, but i can't remember what exactly.
g
greenbear
Owner
Posts: 733
Joined: Mon Sep 24, 2001 8:00 pm
Location: Norway

Post by greenbear »

Maybe something like this

Code: Select all

if {![info tclversion]>="8.4"} {
  putlog "ERROR: You cannot run mute.tcl without tcl version 8.4 or higher"
  return
}
m
metroid
Owner
Posts: 771
Joined: Wed Jun 16, 2004 2:46 am

Post by metroid »

I think that was the one, Thanks :)
Locked