Share

HeXHub

The forum address has changed, you have been automatically redirected. Please update any bookmarks to use the new URL.

Subscribe

HexScript:Broadcast and SendData

You are viewing a single message from this topic. View all messages.

  1. 2009-08-17 17:38:51 UTC
    I wonder about difference between these commands in the HexScript plugin, cause I wrote a script to fix the $UserIP bug. But when i use SendData. it causes no effect, but with Broadcast this command works correctly.
    Some code:
    OnUserJoined = function (iUserId)
    local usr = Hex.User(iUserId)
    local ops={}
    local ips=""
    nickr = usr:GetNick()
    ipr = usr:GetIPString()
    while bResult == true do
    if tusr:GetAccessLevel()>20000 then table.insert(ops,tusr:GetUserID()) end

    bResult = tusr:Next()
    end

    ips="$UserIP "..nickr.." "..ipr.."$$|"
    for id=1,#ops do
    print(Hex.User(ops[id]):GetNick())
    Hex.User(ops[id]):SendData(ips)
    -- Hex.Broadcast(ips)
    end

    nickr and ipr contains thing of the user, that was just connected.
< Previous | 1 | Next >

Add a Reply

This forum does not allow anonymous participation.

Log in to add a reply. Not registered? Create an account to participate and receive email updates when replies are posted to this topic.