This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
gendalf's profile picture

simple questions

Started by gendalf, 31 May 2012 - 07:47 AM
gendalf #1
Posted 31 May 2012 - 09:47 AM
what is the difference between
io.read() and read() ?

delete button don't work?
MysticT #2
Posted 31 May 2012 - 06:24 PM
From the io api:

function read( _sFormat )
    if _sFormat and _sFormat ~= "*l" then
        error( "Unsupported format" )
    end
    return _G.read()
end
There's no difference since it just calls read(), but you can't give it any parameters (just the format, and only supports one, so it's kinda usless), so you can't use a replacement char (like "*" for passwords) or an history table (when using up and down to go through the previous commands).
gendalf #3
Posted 04 June 2012 - 03:32 PM
how to make it read in a row? so when i press enter it dont go down until last 'read' in program
D3matt #4
Posted 04 June 2012 - 05:59 PM
how to make it read in a row? so when i press enter it dont go down until last 'read' in program
You want to read the same line multiple times? Just save it to a variable.
luke100 #5
Posted 09 June 2012 - 06:38 PM
Mam problem z dyskietkom
mianowicie zainstalowałem sobie 3 mody tales of kingdom, Exterdent Workbench, i Computercraft
Crafting dyskietki jest identyczny co crafting monety w tales of kingdom i złotego kiofa w modzie workbench
nie wiem co robić nie moge kożystać z dyskietek

myslałem nad zmianom craftingu ale nie wiem jak to sie robi i czy wogule sie da

PS mam minecrafta 1.2.5