Results 1 to 10 of 10

Thread: Need Script for Logout at certain hour

  1. #1
    iBot User Diemitri's Avatar
    Join Date
    Jun 2014
    Location
    Mexico
    Posts
    15
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    3 Post(s)
    Reputation
    31
    Rep Power
    3

    Red face Need Script for Logout at certain hour

    maybe something like this....


    if time("8:32")
    else
    setcavebot("off")
    wait(1000,1500)
    else
    logout()
    end
    Without the darkness, how we recognize the light. Do not fear your negative force, they are part of you, they are part of everything.

  2. #2
    iBot User sto1p's Avatar
    Join Date
    Feb 2012
    Posts
    483
    Mentioned
    32 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    120 Post(s)
    Reputation
    31
    Rep Power
    5
    Quote Originally Posted by Diemitri View Post
    maybe something like this....


    if time("8:32")
    else
    (kill monster Add)
    setcavebot("off")
    wait(1000,1500)
    else
    logout()
    end

  3. #3
    Moderator Drakke's Avatar
    Join Date
    Jun 2012
    Location
    Sweden
    Posts
    1,898
    Mentioned
    216 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    390 Post(s)
    Reputation
    366
    Rep Power
    10
    @Diemitri

    I havent tried this but
    Lua Code:
     
    if time() == "8:32:00" then
    setcavebot("off") 
    while battlesigned do
    wait(6000)
    end
    logout()
    end

  4. #4
    iBot User Diemitri's Avatar
    Join Date
    Jun 2014
    Location
    Mexico
    Posts
    15
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    3 Post(s)
    Reputation
    31
    Rep Power
    3
    i dont understand the part of '(kill monster Add)


    Thanks
    Without the darkness, how we recognize the light. Do not fear your negative force, they are part of you, they are part of everything.

  5. #5
    iBot User Diemitri's Avatar
    Join Date
    Jun 2014
    Location
    Mexico
    Posts
    15
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    3 Post(s)
    Reputation
    31
    Rep Power
    3
    @Drakke

    Thanks

    You so kind bro, but it doesnt work u.u....
    Without the darkness, how we recognize the light. Do not fear your negative force, they are part of you, they are part of everything.

  6. #6
    iBot User
    Join Date
    Aug 2013
    Posts
    70
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    27 Post(s)
    Reputation
    29
    Rep Power
    4
    hello, put this action as a refill checker. Replace the Xs, the Ys and the Z by the waypoint range of hunting ground. Replace also the gotolabel("Leave") name by the waypoint name that gets ur char out of hunt in ur script.

    PHP Code:
    if (posy yyyyy and posy >= yyyyy) and (posx xxxxx and posx xxxxx) and (posz == z) and (target.id == 0then


    if time() > '08:00:00' then
              setlooting
    ("no")
              
    setsettings("Settings\\Targeting\\Monsters\\OnlyIfTrapped","yes")
              
    settargeting("yes")
              
    gotolabel("Leave"
              
    wait(15000)
    end



    end 
    Then in some waypoint when ur char its at depot depositing put this
    PHP Code:
    if ((pzone == true) and time() > '08:00:00' then
    wait
    (1500)
            
    closetibia()
            
    wait(1500)
            
    message("Logout Message: Tibia client has been closed because logout time limit as been reached")
        
    end  
     
        wait
    (10001500)
        
    setcavebot("no")
        
    wait(10002500)
        
    setlooting("no")
        
    wait(10002500)
        
    settargeting("no")
        
    wait(10002500)
        
    setalerts("no"
    Test if it works. hope it helped u

  7. #7
    Focus Group Gryllz's Avatar
    Join Date
    Jun 2012
    Location
    Dubai
    Posts
    3,481
    Mentioned
    89 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    236 Post(s)
    Reputation
    342
    Rep Power
    10
    @Diemitri

    This one works:

    Lua Code:
     
    local SSTIME = "08:31"
    local a = os.date("%X")
    local POZNO = "08:33"
     
    if (a >= SSTIME and a < POZNO) and connected then
        setcavebot("no")
        wait(1000, 1500)
        logout()
    end

  8. #8
    iBot User
    Join Date
    Mar 2014
    Posts
    32
    Mentioned
    11 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    15 Post(s)
    Reputation
    13
    Rep Power
    3
    Quote Originally Posted by Gryllz View Post
    @Diemitri

    This one works:

    Lua Code:
     
    local SSTIME = "08:31"
    local a = os.date("%X")
    local POZNO = "08:33"
     
    if (a >= SSTIME and a < POZNO) and connected then
        setcavebot("no")
        wait(1000, 1500)
        logout()
    end
    What's os.date?

  9. #9
    Focus Group Gryllz's Avatar
    Join Date
    Jun 2012
    Location
    Dubai
    Posts
    3,481
    Mentioned
    89 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    236 Post(s)
    Reputation
    342
    Rep Power
    10
    Quote Originally Posted by Warior1 View Post
    What's os.date?
    Lua's function, leaves your pc's date.

    P.S. Dont talk to me ela

  10. #10
    iBot User Diemitri's Avatar
    Join Date
    Jun 2014
    Location
    Mexico
    Posts
    15
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    3 Post(s)
    Reputation
    31
    Rep Power
    3
    Quote Originally Posted by mi2bru View Post
    hello, put this action as a refill checker. Replace the Xs, the Ys and the Z by the waypoint range of hunting ground. Replace also the gotolabel("Leave") name by the waypoint name that gets ur char out of hunt in ur script.

    PHP Code:
    if (posy yyyyy and posy >= yyyyy) and (posx xxxxx and posx xxxxx) and (posz == z) and (target.id == 0then


    if time() > '08:00:00' then
              setlooting
    ("no")
              
    setsettings("Settings\\Targeting\\Monsters\\OnlyIfTrapped","yes")
              
    settargeting("yes")
              
    gotolabel("Leave"
              
    wait(15000)
    end



    end 
    Then in some waypoint when ur char its at depot depositing put this
    PHP Code:
    if ((pzone == true) and time() > '08:00:00' then
    wait
    (1500)
            
    closetibia()
            
    wait(1500)
            
    message("Logout Message: Tibia client has been closed because logout time limit as been reached")
        
    end  
     
        wait
    (10001500)
        
    setcavebot("no")
        
    wait(10002500)
        
    setlooting("no")
        
    wait(10002500)
        
    settargeting("no")
        
    wait(10002500)
        
    setalerts("no"
    Test if it works. hope it helped u

    Wow... it look so awesome and pro... i will test ... Thanks for you time
    Without the darkness, how we recognize the light. Do not fear your negative force, they are part of you, they are part of everything.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •