Page 1 of 2

Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 7:49 am
by Pie
I've been looking for quite a while now, and I can't find anything related with Love2D using oAuth.
I'm basically looking for a way to post on Twitter by using Love2D.

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 10:45 am
by kikito
You might find more stuff if you look for "oauth with Lua" instead of "oauth with Love2d". I just found this (I have not tried it):

https://github.com/ignacio/LuaOAuth

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 3:37 pm
by Pie
kikito wrote:You might find more stuff if you look for "oauth with Lua" instead of "oauth with Love2d". I just found this (I have not tried it):

https://github.com/ignacio/LuaOAuth
I've looked into that, but it said "module 'base64' not found"

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 3:41 pm
by zorg
Because it has dependencies that you need to manually put in place (you can use other mechanisms too though):

Code: Select all

dependencies = {
	"lua >= 5.1",
	"luasocket",
	"luasec",
	"luacrypto",
	"lbase64"
}
I'd also guess that some modifications will be in order to get this working with löve, but that's just my guess.

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 4:05 pm
by kikito
As far as I know, luasocket is already included in LÖVE. Luasec, luacrypto and lbase64 are not. If they are all pure-lua functions, you can probably add them to your project relatively easily. If they are binary libraries, then it will be significantly more difficult - using binary libs with LÖVE is kinda hard, especially if you want to support multiple platforms.

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 4:11 pm
by Pie
zorg wrote:Because it has dependencies that you need to manually put in place (you can use other mechanisms too though):

Code: Select all

dependencies = {
	"lua >= 5.1",
	"luasocket",
	"luasec",
	"luacrypto",
	"lbase64"
}
I'd also guess that some modifications will be in order to get this working with löve, but that's just my guess.
Where would I find the ones that work and how would I modify them for löve?

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 5:23 pm
by kikito
If you have to ask that question, then this task might be a bit too much for you right now. I recommend that you set it aside for now, try something simpler, and try it again in the future, when you have a firmer grasp of LÖVE and Lua.

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 5:27 pm
by Pie
kikito wrote:If you have to ask that question, then this task might be a bit too much for you right now. I recommend that you set it aside for now, try something simpler, and try it again in the future, when you have a firmer grasp of LÖVE and Lua.
I guess it is, but I also thought it'd be as easy a doing it in Python. Anyway, thanks for trying to help.

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 5:35 pm
by bobbyjones
Communicating with web APIs usually require HTTPS which Löve currently does not provide. And Google wants the web to only use HTTPS so it is becoming more and more common.

Re: Using Love2D to Post on Twitter?

Posted: Mon Feb 15, 2016 8:26 pm
by Ekamu
bobbyjones wrote:Communicating with web APIs usually require HTTPS which Löve currently does not provide. And Google wants the web to only use HTTPS so it is becoming more and more common.
I've been wondering about that myself... Its unavoidable. (<_<)