Search found 9 matches
- Sun Jan 18, 2015 11:26 am
- Forum: Support and Development
- Topic: creating an ide
- Replies: 19
- Views: 7095
Re: creating an ide
You could try using IUPLua, a GUI toolkit. It has the Scintilla library built in, which provides text editing functionality. Here is the example from the manual showing a basic source code editor: http://webserver2.tecgraf.puc-rio.br/iup/en/ctrl/images/iupscintilla.png http://webserver2.tecgraf.puc-...
- Sat Nov 02, 2013 4:54 pm
- Forum: General
- Topic: paint program help
- Replies: 3
- Views: 2241
Re: paint program help
You can do things such as change the drawing color outside of love.draw. You just have to do the actual drawing in love.draw.
I'm no expert, but for a painting program I would use canvases, although they don't work on really old/weak computers.
https://www.love2d.org/wiki/canvas
I'm no expert, but for a painting program I would use canvases, although they don't work on really old/weak computers.
https://www.love2d.org/wiki/canvas
- Sat Nov 02, 2013 8:58 am
- Forum: General
- Topic: Why use local variables?
- Replies: 12
- Views: 5779
Re: Why use local variables?
b is nil, so that last line would error.vrld wrote:Code: Select all
function newCounter() local i = 0 return function(inc) i = i + (inc or 1) return i end end a, b = newCounter() print(a(3)) --> 3 print(a(), b()) --> 4, 1
- Fri Nov 01, 2013 6:20 pm
- Forum: General
- Topic: LOVE users map
- Replies: 182
- Views: 128335
Re: LOVE users map
Palmview, Texas, USA
- Wed Dec 05, 2012 10:22 pm
- Forum: Support and Development
- Topic: Building Love2d with Vectors
- Replies: 11
- Views: 7615
Re: Building Love2d with Vectors
Using tables is very slow, as seen here: http://code.google.com/p/lua-vec/wiki/Benchmarks . Is there a way to build a modified version of lua and then make a modified Love2d? Did you notice that luajit is faster than lua-vec? Just use luajit-based love2d executables (as I always do). Yeah, I did no...
- Sat Dec 01, 2012 10:15 pm
- Forum: Support and Development
- Topic: Building Love2d with Vectors
- Replies: 11
- Views: 7615
Re: Building Love2d with Vectors
If you are using 2d vectors only, you can get away with using them as pairs of integers. So for example, a function that accepts two vectors looks like this: function sumVectors(x1,y1,x2,y2) -- do something here end There's very little overhead compared to using native vectors, and the gc will perf...
- Sat Dec 01, 2012 9:36 pm
- Forum: Support and Development
- Topic: Building Love2d with Vectors
- Replies: 11
- Views: 7615
Re: Building Love2d with Vectors
Thanks for the suggestions, I'll try them out. I think they'll suit my needs.
- Sat Dec 01, 2012 12:49 pm
- Forum: Support and Development
- Topic: Building Love2d with Vectors
- Replies: 11
- Views: 7615
Re: Building Love2d with Vectors
Using tables is very slow, as seen here: http://code.google.com/p/lua-vec/wiki/Benchmarks . Is there a way to build a modified version of lua and then make a modified Love2d?
- Sat Dec 01, 2012 1:17 am
- Forum: Support and Development
- Topic: Building Love2d with Vectors
- Replies: 11
- Views: 7615
Building Love2d with Vectors
I'm making a simple physics engine with Love2d to learn some physics. A lot of the calculations involve vectors, so I want to have vectors in Love2d. I know you can simulate vectors with just lua, but the performance isn't good. I found lua-vec http://code.google.com/p/lua-vec/ , which looks simple ...