• Welcome to Valhalla Legends Archive.
 

Channel List Bug.

Started by LordNevar, March 14, 2005, 07:20 PM

Previous topic - Next topic

LordNevar

I have been having a problem with the ops being assigned to the top of my channel list. When I join a channel, it lists them to the top just fine, but does not add any of the other info, not there ping or the assigned tooltip. Also when an ops joins, or rejoins, it adds the ping and partial tool top text, but does not say if there an ops or not, assigns the proper flag, but sticks them at the bottom of the channel list. Here is my code for User & Join.


With Main.Channel
    If Not CheckChannel(Username) Then
    If (BNFLAGS_OP And Flags) = BNFLAGS_OP Or (BNFLAGS_SYSOP And Flags) = BNFLAGS_SYSOP Then
        .ListItems.Add 1, , Username, , IconCode(Message, Username, Flags)
        .ListItems(Main.Channel.ListItems.Count).ListSubItems.Add , , , PingCode(ping, Flags)
        .ListItems(Main.Channel.ListItems.Count).ToolTipText = Username & " Is Here With A Ping Of " & ping & "ms" & " And Is A Channel Operator."
    Else
        .ListItems.Add , , Username, , IconCode(Message, Username, Flags)
        .ListItems(Main.Channel.ListItems.Count).ListSubItems.Add , , , PingCode(ping, Flags)
        .ListItems(Main.Channel.ListItems.Count).ToolTipText = Username & " Is Here With A Ping Of " & ping & "ms"
    End If
    End If
    End With


Any comments or help would be appreciated, this has been a long lasting bug in my bot, I have been busy working on other thing's and haven't payed much attention to this particular glitch, but I am winding down on most of the bugs, and figured it may be time to fix this one.

A good fortune may forbode a bad luck, which may in turn disguise a good fortune.
The greatest trick the Devil ever pulled, was convincing the world he didn't exsist.

Soul Taker

This is obvious, you're putting them at the top of the list, then trying to add their information by referencing them as 'Main.Channel.ListItems.Count', which will give you the last person on the list.

LordNevar

Ugh..... It's always the simplest thing, thanxs for pointing that out for me Soul.

Problem has been fixed, thanxs to Souls fast response.

A good fortune may forbode a bad luck, which may in turn disguise a good fortune.
The greatest trick the Devil ever pulled, was convincing the world he didn't exsist.