Posted 29 November 2014 - 04:47 PM
Why is CraftServer so useful?
Have you ever wanted a few computers to be able to access the same variables? Have you ever wanted a place to store all of your data? Well, CraftServer may just be the solution for you. CraftServer alone is a pretty simple code. It's only about 35 lines. The client you use to interact with CraftServer makes the difference.
Users will have the ability to create their own clients to interact with a network of CraftServers. This way, users can have all of the features they want. You may be asking, what's this 'client' you're talking about? Well, a client is basically a manager. When you want to get, set, or delete a variable, you talk with the manager instead of the servers directly. Managers should manage storage space, manage variables across multiple CraftServers, and be able to handle any incoming requests. A client should also allow for a user to view data in the servers without using rednet (For example, a console)
How does it work?
A CraftServer works by saving variables to a file. It has a small bit of code to do extremely basic transfers. The reason the built-in code is so small is to allow for more variables to be stored on the computer. This is the reason a client is needed to interact with a server. You can find the updated code below.
Note, the current code has not yet been tested and requires ComputerCraft 1.6+ The CraftServer code should work fine, but ShadowServer is in early alpha.
CraftServer code
ShadowServer (My client to interact with CraftServer)
Have you ever wanted a few computers to be able to access the same variables? Have you ever wanted a place to store all of your data? Well, CraftServer may just be the solution for you. CraftServer alone is a pretty simple code. It's only about 35 lines. The client you use to interact with CraftServer makes the difference.
Users will have the ability to create their own clients to interact with a network of CraftServers. This way, users can have all of the features they want. You may be asking, what's this 'client' you're talking about? Well, a client is basically a manager. When you want to get, set, or delete a variable, you talk with the manager instead of the servers directly. Managers should manage storage space, manage variables across multiple CraftServers, and be able to handle any incoming requests. A client should also allow for a user to view data in the servers without using rednet (For example, a console)
How does it work?
A CraftServer works by saving variables to a file. It has a small bit of code to do extremely basic transfers. The reason the built-in code is so small is to allow for more variables to be stored on the computer. This is the reason a client is needed to interact with a server. You can find the updated code below.
Note, the current code has not yet been tested and requires ComputerCraft 1.6+ The CraftServer code should work fine, but ShadowServer is in early alpha.
CraftServer code
ShadowServer (My client to interact with CraftServer)
Edited on 29 November 2014 - 03:50 PM