749 posts
Location
BOO!!
Posted 11 April 2016 - 02:30 AM
While making a suggestion is useless for me, since I can't use the latest version of CC, I would still like to make a suggestion.
I think you should have server API
You may think you could just make an http post, and then use PHP on the recieving end to echo it back to all wi-fi enabled in-game lua computers, but not everyone has the servers to do that
While I'm not sure it's going to be used in the right way (an example of this is an un-moderated modified-lua coded forum) I think some server API should be added.
453 posts
Location
Holland
Posted 11 April 2016 - 07:59 PM
but what does it do? be more specific with your suggestions, For example, provide a list of fuctions with their possible arguments and return values, and a description of what the function does
Edited on 11 April 2016 - 05:59 PM
749 posts
Location
BOO!!
Posted 11 April 2016 - 08:11 PM
but what does it do? be more specific with your suggestions, For example, provide a list of fuctions with their possible arguments and return values, and a description of what the function does
if http and server then
serverID = 'fgdffsdfdffedf'
if not server.exists(server.encode(serverID))then
server.create(sever.encode(serverID))
end
if server.connected(server.encode(serverID)) then
print(server.get())
end
server.post( someRandomNumber )
end
In addition, you could have subServers
Edited on 11 April 2016 - 06:20 PM
44 posts
Posted 19 April 2016 - 11:50 PM
How about we just let computers open raw TCP sockets. :P/>
2427 posts
Location
UK
Posted 20 April 2016 - 10:56 AM
How about we just let computers open raw TCP sockets. :P/>
http://minecraft.curseforge.com/projects/cctweaks
1426 posts
Location
Does anyone put something serious here?
Posted 20 April 2016 - 05:50 PM
How about we just let computers open raw TCP sockets. :P/>
http://minecraft.cur...ojects/cctweaks
Yeah, but CCTweaks shouldn't have to exist. This is the sort of thing that should be in 'vanilla' CC.
724 posts
Posted 20 April 2016 - 08:41 PM
I doubt it's too hard for me to understand this suggestion. Do you suggest a way to open server in game, which would be accessible from any other CC computer in game ignoring range or any other condition? Why would you use modems then? Positioning only?
997 posts
Location
Wellington, New Zealand
Posted 25 April 2016 - 06:16 AM
but what does it do? be more specific with your suggestions, For example, provide a list of fuctions with their possible arguments and return values, and a description of what the function does
if http and server then
serverID = 'fgdffsdfdffedf'
if not server.exists(server.encode(serverID))then
server.create(sever.encode(serverID))
end
if server.connected(server.encode(serverID)) then
print(server.get())
end
server.post( someRandomNumber )
end
In addition, you could have subServers
I don't understand this code.
So, first, you create a server if it doesn't exist. That part makes sense, although your code doesn't tell me what a server actually is.
Then, if that server is connected, you "get" and print the result of the "getting". What does that actually mean?
Then, you post a variable that you haven't shown here. What does that mean?
Edited on 25 April 2016 - 07:18 AM
749 posts
Location
BOO!!
Posted 25 April 2016 - 12:52 PM
I don't understand this code.
So, first, you create a server if it doesn't exist. That part makes sense, although your code doesn't tell me what a server actually is.
Then, if that server is connected, you "get" and print the result of the "getting". What does that actually mean?
Then, you post a variable that you haven't shown here. What does that mean?
Just assume someRandomNumber is unseen code with a value created by math.ran or whatever
As for server, look
here
Edited on 25 April 2016 - 10:54 AM
1243 posts
Location
Indiana, United States
Posted 25 April 2016 - 02:42 PM
Given your naming and your link, I would say you're either talking about making a Rednet server API, so creating Rednet servers would be simpler (no defined protocol). Or, you're talking about HTTP. I don't know what you mean, but neither suggestion makes a whole lot of sense. If you could clarify, that'd be good.
Edited on 25 April 2016 - 12:42 PM
749 posts
Location
BOO!!
Posted 25 April 2016 - 02:48 PM
Given your naming and your link, I would say you're either talking about making a Rednet server API, so creating Rednet servers would be simpler (no defined protocol). Or, you're talking about HTTP. I don't know what you mean, but neither suggestion makes a whole lot of sense. If you could clarify, that'd be good.
Http requires you create your own serverside (with PHP) if you want to make a computercraft server. My apis just allows you to communicate without doing that
If you noticed I said 'MP' in the title
Edited on 25 April 2016 - 12:48 PM
1140 posts
Location
Kaunas, Lithuania
Posted 25 April 2016 - 03:51 PM
Are you suggesting a way for the ComputerCraft computer to create an actual internet server? So you could use for things like hosting actual websites? Please rephrase your idea (the whole idea, not just a part of it), because nobody here seems to understand what your suggestion is.
749 posts
Location
BOO!!
Posted 25 April 2016 - 04:49 PM
Are you suggesting a way for the ComputerCraft computer to create an actual internet server? So you could use for things like hosting actual websites? Please rephrase your idea (the whole idea, not just a part of it), because nobody here seems to understand what your suggestion is.
internet server? Yes, but not compatible with browser
hosting actual websites? Nope. Not a hyper-text-markup-language or PHP server. That's exactly what I'm trying to avoid.
724 posts
Posted 26 April 2016 - 07:30 AM
While making a suggestion is useless for me, since I can't use the latest version of CC, …
While I'm not sure it's going to be used in the right way …
These two arguments plus completely not understood suggestion make me sad. :(/>
1243 posts
Location
Indiana, United States
Posted 27 April 2016 - 03:17 AM
Are you talking about inter-server or intra-server communication?
Inter-server (without an external server) would require another port (or some hackery with the MC port) on all CC servers to be opened, which doesn't make sense.
Of course, intra-server communication is already possible with Rednet, in which case you're asking about an abstraction layer of sorts that could easily be built by a user.
As I said above, none of this makes sense, so I hope I'm wrong about what you mean.
997 posts
Location
Wellington, New Zealand
Posted 27 April 2016 - 09:37 AM
I don't understand this code.
So, first, you create a server if it doesn't exist. That part makes sense, although your code doesn't tell me what a server actually is.
Then, if that server is connected, you "get" and print the result of the "getting". What does that actually mean?
Then, you post a variable that you haven't shown here. What does that mean?
Just assume someRandomNumber is unseen code with a value created by math.ran or whatever
As for server, look
here
Okay, a server is a device that provides functionality to other computers.
So what you're saying is, when you run `server.create(stuff)`, a new computer spawns into existence next to where you're standing?
If not, then you're going to have to be more specific about what you actually want to happen.
749 posts
Location
BOO!!
Posted 27 April 2016 - 12:54 PM
I don't understand this code.
So, first, you create a server if it doesn't exist. That part makes sense, although your code doesn't tell me what a server actually is.
Then, if that server is connected, you "get" and print the result of the "getting". What does that actually mean?
Then, you post a variable that you haven't shown here. What does that mean?
Just assume someRandomNumber is unseen code with a value created by math.ran or whatever
As for server, look
here
Okay, a server is a device that provides functionality to other computers.
So what you're saying is, when you run `server.create(stuff)`, a new computer spawns into existence next to where you're standing?
If not, then you're going to have to be more specific about what you actually want to happen.
Let's say this
Daniel Ratcliffe just gets a lot of servers. He decides to use them to improve his mod, and add THAT server API. However, they are not active. The server.create tells the server 'your needed'
1426 posts
Location
Does anyone put something serious here?
Posted 27 April 2016 - 01:24 PM
Daniel Ratcliffe just gets a lot of servers.
Servers cost money. How are you going to fund them? Dan is self employed and so money doesn't exactly grow on trees for him. Setting up your own server and then using CCTweaks's TCP socket API to communicate with it is by far the best way to achieve this.
1610 posts
Posted 28 April 2016 - 12:38 AM
This is a really bad idea. There are plenty of free PHP web hosts that you can use if you really need a server, and there's no point in adding functionality like this into the mod because it doesn't fit at all with the theme or the fact that CC uses Lua, and not PHP…
997 posts
Location
Wellington, New Zealand
Posted 28 April 2016 - 07:27 AM
Let's say this
Daniel Ratcliffe just gets a lot of servers. He decides to use them to improve his mod, and add THAT server API. However, they are not active. The server.create tells the server 'your needed'
Oh, so you want a way to send data between different Minecraft servers / singleplayer games.
So what do `server.post` and `server.get` do?
749 posts
Location
BOO!!
Posted 28 April 2016 - 12:50 PM
Let's say this
Daniel Ratcliffe just gets a lot of servers. He decides to use them to improve his mod, and add THAT server API. However, they are not active. The server.create tells the server 'your needed'
Oh, so you want a way to send data between different Minecraft servers / singleplayer games.
So what do `server.post` and `server.get` do?
That's how you actually send/recieve data
726 posts
Location
Rem is best girl
Posted 30 April 2016 - 05:35 PM
I believe that just using php would be the good way :P/>
Also if there was like a server api which lets people connect from servers to other servers. What if on one server a griefer/hacker abuses it and may do some like spam thingy :P/> (if you know what i mean)
#COMPUTER CRAFT SERVER API = DDOS SOFTWARE CONFIRMED /o\