GoLÖVE?
-
- Prole
- Posts: 11
- Joined: Fri Apr 05, 2013 1:10 am
GoLÖVE?
Would it be difficult to combine LÖVE with the Go programming language? Is LÖVE heavily dependent on dynamic language properties? I note there was a lov8 project that used Javascript and V8 instead of Lua https://code.google.com/p/lov8/
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: GoLÖVE?
I'm not an authority on this subject, but I don't think it would be easy, at least not if you want to keep it lovely.
Help us help you: attach a .love.
- kikito
- Inner party member
- Posts: 3153
- Joined: Sat Oct 03, 2009 5:22 pm
- Location: Madrid, Spain
- Contact:
Re: GoLÖVE?
Go is an awesome language and I think it has big potential for games.
Pros:
Pros:
- The roots are clean and small (a bit like Lua on that regard)
- Creating & using libraries is simpler than in Lua
- Go does some extremely interesting stuff with threads. Lua's concurrency model can't really hold a candle to that. Games could benefit from this in a number of ways.
- It's quite fast. I can't say for sure, but I think it is faster than Lua.
- Go is not designed to be as embeddable as Lua. Creating a "love-like" program in Go, which accepted zip files, would be messier. It would probably be much simpler to create a library instead of a runtime.
- Go is not available in many platforms: mac, win, linux, and that's it. I realize that LÖVE is the same, but Lua exists in mobile phones.
When I write def I mean function.
-
- Prole
- Posts: 11
- Joined: Fri Apr 05, 2013 1:10 am
Re: GoLÖVE?
If one can dump one's own events on the LÖVE event queue, then you can get "reasonably close" to a concurrency architecture close to Go's.kikito wrote:
- Lua's concurrency model can't really hold a candle to that. Games could benefit from this in a number of ways.
- kikito
- Inner party member
- Posts: 3153
- Joined: Sat Oct 03, 2009 5:22 pm
- Location: Madrid, Spain
- Contact:
Re: GoLÖVE?
Mmm I think you haven't thought that through. I was talking about channels and goroutines.
When I write def I mean function.
- slime
- Solid Snayke
- Posts: 3162
- Joined: Mon Aug 23, 2010 6:45 am
- Location: Nova Scotia, Canada
- Contact:
Re: GoLÖVE?
I believe LÖVE 0.9.0's new Channel API for threads is somewhat based on Go's channels.
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: GoLÖVE?
I'll freely admit I may have borrowed some ideas from go for that...
Which is also, coincidentally, the reason why there's a blocking send in that api.
Which is also, coincidentally, the reason why there's a blocking send in that api.
Re: GoLÖVE?
Go is still relatively new, isn't it? It's developed by Google, so it wouldn't be all that surprising if Android got Go support at some point.
My game called Hat Cat and the Obvious Crimes Against the Fundamental Laws of Physics is out now!
- kikito
- Inner party member
- Posts: 3153
- Joined: Sat Oct 03, 2009 5:22 pm
- Location: Madrid, Spain
- Contact:
Re: GoLÖVE?
That is so cool!bartbes wrote:I'll freely admit I may have borrowed some ideas from go for that...
Which is also, coincidentally, the reason why there's a blocking send in that api.
When I write def I mean function.
-
- Prole
- Posts: 11
- Joined: Fri Apr 05, 2013 1:10 am
Re: GoLÖVE?
kikito wrote:Mmm I think you haven't thought that through.
Ditto.
Me too. If you have some kind of asynchronous queue that you can dump stuff into and set up callbacks on, then you effectively have channels. In fact, you could have the queue serve as all the channels, so long as you're careful. (No functions that run for long at all.) Also that fancy concurrent switch thingy Go has, you can implement the equivalent that way. It's all a bit more verbose and less elegant. Lua has coroutines. That about covers it, I think. It's not as elegant or as bulletproof as what Go gives you, but it's workably close enough.kikito wrote:I was talking about channels and goroutines.
Who is online
Users browsing this forum: Google [Bot] and 2 guests