Jump to content




Concept: http based rednet alternative


  • You cannot reply to this topic
7 replies to this topic

#1 M4sh3dP0t4t03

  • Members
  • 255 posts
  • LocationGermany

Posted 22 April 2013 - 03:28 AM

I had today the idea of a rednet alternative that isnt only limited to the server by making an API and a http server, over that the messages are send. I don't have any idea of http so I couldn't make it, but if someone has the needed coding knowledge and the money for renting a server for making this it would be nice for multiplayer games. So, what do you think about this idea?

#2 lieudusty

  • Members
  • 419 posts

Posted 22 April 2013 - 03:48 AM

I don't think thats possible without sockets.

#3 Sammich Lord

    IRC Addict

  • Members
  • 1,212 posts
  • LocationThe Sammich Kingdom

Posted 22 April 2013 - 04:13 AM

You can write a simple Node.js script to store all messages in a array then when you request a message it will just print out the message. But anything real-time needs to be with sockets.

#4 GravityScore

  • Members
  • 796 posts
  • LocationLand of Meh

Posted 22 April 2013 - 05:09 AM

It is possible without sockets, it will just spam HTTP.

For polling the server for a response, you could just have the script wait until a new message appears, and use http.request in a loop to avoid the request timeouts. I don't recommend this though, plus it wouldn't be very real time.

#5 jesusthekiller

  • Banned
  • 562 posts
  • LocationWrocław, Poland

Posted 22 April 2013 - 07:03 AM

Look at my WCON (signature)

#6 M4sh3dP0t4t03

  • Members
  • 255 posts
  • LocationGermany

Posted 22 April 2013 - 08:12 AM

View Postjesusthekiller, on 22 April 2013 - 07:03 AM, said:

Look at my WCON (signature)
I already know that, but that isn't exactly what I meant

#7 lieudusty

  • Members
  • 419 posts

Posted 22 April 2013 - 11:03 AM

View Postjesusthekiller, on 22 April 2013 - 07:03 AM, said:

Look at my WCON (signature)
Your method works but its not realtime. It has a delay on every update.

#8 jesusthekiller

  • Banned
  • 562 posts
  • LocationWrocław, Poland

Posted 22 April 2013 - 11:17 AM

Yes, it doesn't matter how you will do it, HTTP API will always have a delay tho.





2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users