Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- term.clear()
- rednet.open("back")
- print "DexCorp Technoligies v1.0"
- id, input = rednet.receive()
- print(input)
- if input == "new" then
- id, newname = rednet.receive()
- newacc = fs.open(newname, "w")
- newacc.writeLine(100)
- newacc.close()
- shell.run("startup")
- end
- handle = fs.open(input,"r")
- balance = tonumber(handle.readLine())
- if balance > 10 then
- balance = balance - 10
- else
- --no acceptance
- end
- handle.close()
- handle = fs.open(input,"w")
- handle.write(balance)
- handle.close()
- print ("Name:"..input)
- print ("Current Bal:"..tostring(balance+10))
- print ("New Bal:"..balance)
- print ("Accepted")
- sleep(5)
- shell.run("startup")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement