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

Owner in NBT

Started by NeverCast, 26 March 2013 - 10:45 AM
NeverCast #1
Posted 26 March 2013 - 11:45 AM
Hello,

Could it be part of core ComputerCraft to store the user that either first placed or crafted the Computer/Turtle in both the Item NBT and TileEntity NBT.
This would be helpful for something I'm writing where I can Start/Stop/Reboot CC Computers from a Web Console, much like virtual machines. I want to provide a login for a user so that they cannot shutdown important computers that belong to other players ( Such as those controlling locks or Nuclear Cooling ).

In the chance that this request is rejected, can someone who knows their way around Forge offer another solution, perhaps an event hook for when a computer/turtle is placed? I'll attach the NBT entry myself.

- NC
Tiin57 #2
Posted 26 March 2013 - 12:06 PM
Hello,

Could it be part of core ComputerCraft to store the user that either first placed or crafted the Computer/Turtle in both the Item NBT and TileEntity NBT.
This would be helpful for something I'm writing where I can Start/Stop/Reboot CC Computers from a Web Console, much like virtual machines. I want to provide a login for a user so that they cannot shutdown important computers that belong to other players ( Such as those controlling locks or Nuclear Cooling ).

In the chance that this request is rejected, can someone who knows their way around Forge offer another solution, perhaps an event hook for when a computer/turtle is placed? I'll attach the NBT entry myself.

- NC
I could do it, but I doubt that it'll be included.
Cloudy #3
Posted 26 March 2013 - 12:13 PM
Eh… Not too fond doing this until there's a method in place to protect areas using forge.
immibis #4
Posted 26 March 2013 - 12:57 PM
Make the user store a per-computer password in a file with a certain name (eg .password where the . hides it from ls).
To access a computer through the web, enter a password matching the one in the file.
Computers without password files can't be accessed through the web.
NeverCast #5
Posted 26 March 2013 - 01:15 PM
Eh… Not too fond doing this until there's a method in place to protect areas using forge.
I would like that feature also in Forge, but makes sense that there needs to be more focused reasons to implement 'owning' a computer.

Make the user store a per-computer password in a file with a certain name (eg .password where the . hides it from ls).
To access a computer through the web, enter a password matching the one in the file.
Computers without password files can't be accessed through the web.
That'll work, Thanks immibis.


I could do it, but I doubt that it'll be included.
As a patch maybe?
Simon #6
Posted 26 March 2013 - 05:55 PM
Make the user store a per-computer password in a file with a certain name (eg .password where the . hides it from ls).
To access a computer through the web, enter a password matching the one in the file.
Computers without password files can't be accessed through the web.
Hmm, like this?
http://www.computercraft.info/forums2/index.php?/topic/9895-wip-web-inteface-for-uploading-and-downloading-scripts-to-servers/page__p__101502