Search found 265 matches
- Fri Mar 01, 2024 7:03 am
- Forum: Support and Development
- Topic: Scaling a shader centered at the mouse point
- Replies: 1
- Views: 2014
Re: Scaling a shader centered at the mouse point
A zoom is a scale operation, and if you want to scale something (like a UV coordinate) based on some point other than the origin, then you need to chain the operations carefully so the scale happens relative to that point. So say you have a 2D space, with a point A somewhere and a point B somewhere....
- Fri Mar 01, 2024 6:38 am
- Forum: Support and Development
- Topic: 2.5D effect?
- Replies: 3
- Views: 2093
Re: 2.5D effect?
For sure. There are probably a few different ways to do false 3D effects. Here's one, very hastily done: https://love2d.org/forums/viewtopic.php?p=258506#p258506 (Edit: to run it, you download that Parallax_Scrolling.love file, then either drag-and-drop it onto love.exe, or run the command line &quo...
- Thu Feb 29, 2024 9:25 pm
- Forum: Libraries and Tools
- Topic: Native open/save dialogs for Windows
- Replies: 2
- Views: 2912
- Sun Feb 25, 2024 5:18 pm
- Forum: Libraries and Tools
- Topic: Native open/save dialogs for Windows
- Replies: 2
- Views: 2912
Native open/save dialogs for Windows
This is an example of how to use the LuaJIT FFI to bind the (obsolete) GetOpenFileNameW() and GetSaveFileNameW() functions from WIN32 so that you can get native dialogs that properly display content on both ASCII and Unicode encodings. So things like the dialog title and the filename, as well as the...
- Mon Feb 19, 2024 12:08 pm
- Forum: Support and Development
- Topic: Trying to figure out collision with tiles in platformer game
- Replies: 11
- Views: 2266
Re: Trying to figure out collision with tiles in platformer game
I posted these two articles in another thread, but the subject was different so I'll repost them here instead of linking there.
Tutorials on how to make tile maps and handling tile collisions:
- https://sheepolution.com/learn/book/18
- https://jonathanwhiting.com/tutorial/collision/
Tutorials on how to make tile maps and handling tile collisions:
- https://sheepolution.com/learn/book/18
- https://jonathanwhiting.com/tutorial/collision/
- Sun Feb 18, 2024 9:19 pm
- Forum: Support and Development
- Topic: Tips & advice for making a small beginner project?
- Replies: 6
- Views: 776
Re: Tips & advice for making a small beginner project?
I'd like to learn to use the LOVE2D engine as a spare time thing, and I don't want to start off very ambitious, so I was wondering if anyone had good advice on how to start off once I've gotten through the basics of the engine? (...) Would this be a good place to start & work towards or should ...
- Sun Feb 18, 2024 9:03 pm
- Forum: Support and Development
- Topic: Need Beginners Help with Nil Value error
- Replies: 1
- Views: 482
Re: Need Beginners Help with Nil Value error
Hi. Read the error message, it's worth gold: main.lua:9: attempt to index field 'spriteSheet' (a nil value) It says the error is on your "main.lua" script, on line #9, which happens to be this: player.grid = anim8.newGrid( 12, 18, player.spriteSheet:getWidth(), player.spriteSheet:getHeight...
- Sun Feb 18, 2024 8:58 pm
- Forum: Support and Development
- Topic: Finding the visual center of a polygon
- Replies: 3
- Views: 560
Re: Finding the visual center of a polygon
Your image doesn't look like a polygon, but like something painted / raster data. Is your input shape polygonal, or is it a bitmap, or something else? Is it supposed to be animated? Is the center always in the same position, or do you need to calculate the nearest center towards some arbitrary point...
- Sat Feb 17, 2024 7:24 am
- Forum: Support and Development
- Topic: Spawning Endless Object With Conditions
- Replies: 2
- Views: 570
Re: Spawning Endless Object With Conditions
And a really quick question: If off screen objects are using memory like "setting a pipes X coordinate to -100" how could you actually destroy them once they are no longer used. The Lua language standard defines a memory managed environment, and the LuaJIT interpreter used by Löve follows...
- Wed Feb 14, 2024 8:26 am
- Forum: Support and Development
- Topic: Http requests
- Replies: 7
- Views: 1061
Re: Http requests
Was there a reason why you didn't post the actual code that causes the error?