Jump to content

Hashtable Help


KFM182

Recommended Posts

I'm a new and i not understand how I can show all item in hashtable.

 

ex:

 

I try this.

 

on *:TEXT:*:#: {

 

had -m test te1 $nick

 

timer1 0 10 msg # $hget(test,te1)

}

for the bot say all in the hashtable bot he say only the last use this command

 

 

Link to comment
Share on other sites

alias hashtest {
  hadd -m test bleh $+ $rand(1,99999) hey $rand(1,99999)
  var %a = 1
  while ($hget(test,%a).item) {
    echo -a Item: $hget(test,%a).item Data: $hget(test,%a).data
    inc %a
  }
}

Item should different for each line. Data is what is stored for that item

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...