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

A computercraft forum API

Started by emerald, 30 October 2016 - 01:44 PM
emerald #1
Posted 30 October 2016 - 02:44 PM
So, I had this idea of being able to post/get posts off of the computercraft forums in-game. I mean, I know it is probably possible already using the HTTP API but for many of us we do not understand HTTP, PHP or MySQL. I mean, I am going to learn it but it would just be soo easy to see an official API to post and "download" posts from the forums. My ideas were:
  • To be able to download code snippets. So, say you found a forum post and it had some code snippets but you wanted to download them onto your cc computer and there was no Pastebin link(Before you say just copy it into notepad ++ and put into a folder, remember some people play on servers). When making a code-snippet, you should maybe add a "name" for the snippet and then maybe do
    
    dat = forum.getCodeSNippet("forum link", "snippet name")
    
    To get save it to a variable.
  • Edit forum posts you created. So, say you wanted to make a program that automagicly updates the Pastebin/market download code, you could. So, basicaly it will replace a line of your will. maybe:
    
    forum.edit("page link", "usr name", "password", "replaced text here")
    
  • Use forum posts to host data! If they also added a forum.read(…) then you could update a forum post to host data(Maybe an online store?) I will give no example on how you may do this cause I have no idea :P/>
Thanks for reading my suggestion. I know at least 1 mod will see this cause this is only my second post.
EveryOS #2
Posted 03 November 2016 - 01:08 PM
Know what, you can probably already use the http API to do this! Isn't that great!?
emerald #3
Posted 03 November 2016 - 08:57 PM
Know what, you can probably already use the http API to do this! Isn't that great!?
Yes, but for people like me who don't understand HTTP and find it hard learning, this would be good.
H4X0RZ #4
Posted 03 November 2016 - 10:25 PM
To be able to download code snippets. So, say you found a forum post and it had some code snippets but you wanted to download them onto your cc computer and there was no Pastebin link(Before you say just copy it into notepad ++ and put into a folder, remember some people play on servers). When making a code-snippet, you should maybe add a "name" for the snippet and then maybe do
Just create a new paste on pastebin containing that code snippet. Problem solved.
Edit forum posts you created. So, say you wanted to make a program that automagicly updates the Pastebin/market download code, you could. So, basicaly it will replace a line of your will.
  1. There are many ways to intercept the connection between the computer and the server. I won't ever use this because it's way too easy to steal your data.
  2. You just have to edit the paste instead of creating a new one every time. Same goes for the "market code", although I'm not sure which "market" you are refering to.
Use forum posts to host data! If they also added a forum.read(…) then you could update a forum post to host data(Maybe an online store?) I will give no example on how you may do this cause I have no idea
Why should dan give away storage for free (which, if exploited correctly, might even turn out to be "endless"). Way too much for the devs to sandbox, and the gain is almost non-existant for them. If you need more space, abuse disk labels.
Edited on 03 November 2016 - 09:33 PM
emerald #5
Posted 06 November 2016 - 11:11 PM
To be able to download code snippets. So, say you found a forum post and it had some code snippets but you wanted to download them onto your cc computer and there was no Pastebin link(Before you say just copy it into notepad ++ and put into a folder, remember some people play on servers). When making a code-snippet, you should maybe add a "name" for the snippet and then maybe do
Just create a new paste on pastebin containing that code snippet. Problem solved.
Edit forum posts you created. So, say you wanted to make a program that automagicly updates the Pastebin/market download code, you could. So, basicaly it will replace a line of your will.
  1. There are many ways to intercept the connection between the computer and the server. I won't ever use this because it's way too easy to steal your data.
  2. You just have to edit the paste instead of creating a new one every time. Same goes for the "market code", although I'm not sure which "market" you are refering to.
Use forum posts to host data! If they also added a forum.read(…) then you could update a forum post to host data(Maybe an online store?) I will give no example on how you may do this cause I have no idea
Why should dan give away storage for free (which, if exploited correctly, might even turn out to be "endless"). Way too much for the devs to sandbox, and the gain is almost non-existant for them. If you need more space, abuse disk labels.
Thanks for explaining. I recently started learning HTML, JS, CSS, HTTP, PHP and MySQL(Because I own a game cheats website and I want to code it instead of using a website maker) so I may be able to do what I needed with CC on my own webserver.
TheRockettek #6
Posted 07 November 2016 - 06:50 AM
If you want free space, host a ghetto http server with windows IIS (like i did) or use pastevbin…
Emma #7
Posted 19 November 2016 - 01:29 AM
If you want free full-access website hosting, http://000webhost.com/ is good bet.