Jump to content
  • Sky
  • Blueberry
  • Slate
  • Blackcurrant
  • Watermelon
  • Strawberry
  • Orange
  • Banana
  • Apple
  • Emerald
  • Chocolate
  • Charcoal

Ta©ti Tac0Z

Members
  • Content Count

    143
  • Joined

  • Last visited

  • Days Won

    5

Posts posted by Ta©ti Tac0Z

  1. also treads doesn't create an critical error in the main scope so a great way to run a thread in terms of debuging is by printing the error on the screen and start a blocking function such as computer.beep()

     

    funciton runThreadWithExelentDebuging(func)
      thread.create(function() 
        local syc, e = xpcall(func, debug.traceback)
    
        if syc == false then
          //syc is false this means an error was genrated in func
          require("term").clear()
          print(e)
          require("computer").beep(500,10) //calling computer.beep to avoid other threads or the main scope to redraw the screen
        end
      end)
    end
    
    --disclamer: this is not tested

     

  2. the function xpcall should give you a traceback witch will tell you what line the error is genratet

    usage:

    syc, e = xpcall(functionToRun, debug.traceback)
    --[[ syc: true or false: where false means that there was an error
    e: a full error message i.e:
    line bla-bla-bla: bad argument bla-bla-bla
    traceback:
    at line bla-bla-bla in function bla-bla-bla
    ...
    
    ]]

     

  3. local h = require("internet").open("108.61.112.194", 25444)
    h:setTimeout(1000)
    os.sleep(2)
    
    h:write("login (password removed - actuel password should be here)")
    h:flush()
    
    
    while true do
      
      pcall(function()
        print(h:read(1000))
      end)
      os.sleep(1)
    end 
    
    h:close()

    nothing ever happens sems that the read request just timesout evrey time. acording to the wiki: "The read method on the returned buffer is blocking. Read will wait until some data is available to be read" but there are data there is the start RconRocket message in the start and poeple writeing in chat. so what is going on here? please somebody?

  4. OHHH WOW ok

     

    so i tryed it out:

     

    local h = require("component").internet.connect("108.61.112.194", 25444)
    
    while true do
      print("trying to connect...")
    
      if h.finishConnect() then
        break
      end
    
      os.sleep()
    end
    h.write("login rfdfhasjdahl")
    h.write("login fdsfhjdhfks")
    os.sleep(1)
    print(h.read(10000)) 
    
    h:close()

    so amasing this program prints out: "RconRocket V2.4.8.0" (what my irl rcon client allways starts with)

     

    but it sems that the handle does not have a flush function

    when useing the internet apis open function the read function just timesout

     

     

  5. yeah i do recall the wiki saying some thing about TCP. acording to wikipedia: TCP stands for the 'Transmission Control Protocol'. surfing a little bit more on the internet indicates that TCP is more of a wide spred term. (sems to be a category more that a actuel thing it self - where TCP is described as the component that let other types of internet protocals work)

    so what does TCP include? what is posible with the TCP part of the internet card?

  6. BETA version 1.6 changelog:

    -added the CMD program window: a loot like the windows CMD and the openos shell

     

    COMEING UP:

    -finish the app store window

     

    KNOWEN bug:

    -CMD prints out a syntask error when reporting a error made by other programs

     

    On 10/6/2018 at 10:30 PM, Ta©ti Tac0Z said:

    to download the new version:

    On 10/3/2018 at 8:21 PM, Ta©ti Tac0Z said:
    On 9/24/2018 at 7:41 PM, Ta©ti Tac0Z said:

    first command:

    
    
    
    wget http://packages.noahtg.com/tactiOS/0.1/installOrUpdateOS.lua /installOrUpdateOS.lua -f

      

    and then secount:

    
    
    
    /installOrUpdateOS.lua

    or click on the 'update OS' button in tactiOS settings window if you have a older version of tactiOS

    i'll happyly resive feedback and suggestions

     

  7. BETA VERSION 1.5 changelog:

    -fixed unesesary 'os.sleep(1)' in 'fileExplore' Window

    -added and finished the fileEditor Window, now fully works (requested by Elektron72)

    COMEING UP:

    -finish the app store window

    to download the new version:

    On 10/3/2018 at 8:21 PM, Ta©ti Tac0Z said:
    On 9/24/2018 at 7:41 PM, Ta©ti Tac0Z said:

    first command:

    
    
    wget http://packages.noahtg.com/tactiOS/0.1/installOrUpdateOS.lua /installOrUpdateOS.lua -f

      

    and then secount:

    
    
    /installOrUpdateOS.lua

    or click on the 'update OS' button in tactiOS settings window if you have a older version of tactiOS

    i'll happyly resive feedback and suggestions

  8. BETA VERSION 1.4 changelog:

    -fixed MASIVE keyboard input lag

    -comeing even closer to finish the file editor (save new file, load and open is still not working but all other functions sems to be working -

    am sorry for not being done with the file editor for long time ago altho am really happy as how it turned out now i'll finish it as soon as i can)

    two download this new version:

    On 9/24/2018 at 7:41 PM, Ta©ti Tac0Z said:

    first command:

    
    wget http://packages.noahtg.com/tactiOS/0.1/installOrUpdateOS.lua /installOrUpdateOS.lua -f

     

    and then secount:

    
    /installOrUpdateOS.lua

    or click on the 'update OS' button in tactiOS settings window if you have a older version of tactiOS

  9. BETA version 1.3 changelog:

    -made maximasied windows more clean looking

    -build in program 'file editor' has been added (altho its not done yet)

      (currenly only openable in the 'file explore' program

     

    current knowen bugs:

    -windows some times refuses to listen to control inputs (close button, maximise button, etc) sems to be when a lot of windows is open at the same time

    -windows doesn't get focused as they should while minimising and unminimising

     

    8 hours ago, Ta©ti Tac0Z said:

    to download the new version:

    ether use the mothod apove or (if you have the old version) use the 'Update OS' button in the settings window found under menu

    if you use the 'Update OS' button then keep in mind that it maybe a good idea to update twise (given that the installer as updated two)

     

    i'll happyly resive feedback and suggestions

  10. BETA version 1.2 changelog:

    -added a digigal clock in the process line witch will contact my web server to get time evrey 2 min (currencly useing "Europe/Berlin" timezone - will be changeable in the future)

    -some installer changes and fixes

    technical infomation:

    as said the OS will update the time and date evrey 120 sec altho the clock is going but just localy (meaning that if you pause the game the clock will go out of sync until it updates)

    there is currectly a beep sound on update mainly for debuging will be removed in next version

     

    to download the new version:

    ether use the mothod apove or (if you have the old version) use the 'Update OS' button in the settings window found under menu

    if you use the 'Update OS' button then keep in mind that it maybe a good idea to update twise (given that the installer as updated two)

     

  11. FIRST OPEN BETA:

    the first open beta can now be downloaded by running the following commands in the openOS terminal:

     

    first command:

    wget http://packages.noahtg.com/tactiOS/0.1/installOrUpdateOS.lua /installOrUpdateOS.lua -f

     

    and then secount:

    /installOrUpdateOS.lua

     

    (remeber to install openOS to a hard drive if you haven't)

  12. the thread api is really simple but really power full a simple exaple chould be the following:

    local thread = require("thread")
    local event = require("event")
    local keyb = require("keyboard")
    local computer = require("computer")
    
    thread.create(function()--creating the thread
        while true do--beeping loop
          local e,_,_,key = event.pull("key_down")
            --this is a timple while loop witch will beep evreying time you press on enter
            if keyb.keys.enter == key then
              computer.beep()
            end
      end
    end)
    
    print([[as you can see after this print function we have a print(math.huge) basicly locking up the 'main-scope' forever
    but becuse the 'beeping loop' is inside a thread (witch creates a new so called 'scope' the 'beeping loop' is not effected
    
    now when you press Ctrl, Alt + C you'll notice that you need to do it two times becuse the computer will interupt
    the thread first in that oder
    
    a simple explasion of the thread api is simply to run a function witch is almost not effected by the 'main scope' and other threads
    
    lua is 'one-thread-only' meaning that lua doesn't make a new irl thread (a new process nor a new process in java) so the
    thread api is really laying to you and emulating/facking an extra thread besicly the computer will go back and forward
    betwine the 'main scope' and the threads thats why you have too have a yielding fuction (os.sleep, event.pull, ect) in the thread and 'main scope' else it will block evrying thing]])
    
    os.sleep(math.huge)

     

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.