e
This commit is contained in:
1 parent
1a92ff1bd2
commit
91bf28a728
65 files changed
+2587
-240
No files matched your search
@@ -1,7 +1,5 @@
|
||||
local object = {}
|
||||
local file = fs.open("/computers/0/bios.lua", "r")
|
||||
local bios = file.readAll()
|
||||
file.close()
|
||||
local bios = ""
|
||||
|
||||
function object.getData()
|
||||
return bios
|
||||
@@ -12,8 +10,14 @@ function object.setData(data)
|
||||
end
|
||||
|
||||
function object.saveData()
|
||||
local file=fs.open("/bios.lua", "w")
|
||||
local file=fs.open("/AceVM/computers/"..tostring(aceVM.id).."/bios.lua", "w")
|
||||
file.write(bios)
|
||||
file.close()
|
||||
end
|
||||
|
||||
newComponent("bios", object)
|
||||
function aceVM.components.bios(id)
|
||||
local file = fs.open("/AceVM/computers/"..tostring(id).."/bios.lua", "r")
|
||||
bios = file.readAll()
|
||||
file.close()
|
||||
aceVM.newComponent("bios", object)
|
||||
end
|
||||
Reference in new issue
Block a user