dslayout - Simulate Nintendo 3DS Screens on the desktop.

Showcase your libraries, tools and other projects that help your fellow love users.
Post Reply
User avatar
Nawias
Prole
Posts: 9
Joined: Sun Apr 10, 2022 4:13 pm
Location: Poland

dslayout - Simulate Nintendo 3DS Screens on the desktop.

Post by Nawias »

I wanted to get into homebrew development for the Nintendo 3DS family, and LÖVE Potion looked like the easiest way in. So I started writing for the framework, but lacked a way to quickly test my game on the desktop before building.

That's why I created dslayout - a simple utility library that simulates lovepotion, handles 2 screens and simulates the touchscreen by mouse input. If you think it's of any use for you, check out my GitHub repository: https://github.com/Nawias/dslayout

I should point out that it's basically my first project with love2d or lovepotion. I barely even know lua :crazy: But don't worry, I'm no script kiddie either. You can check out my other repositories if you need proof of that ;)
User avatar
zorg
Party member
Posts: 3435
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: dslayout - Simulate Nintendo 3DS Screens on the desktop.

Post by zorg »

This looks fun to try out :3

One thing though, since you mentioned no "pointer hover"; since a touch screen basically just supports one type of click (i.e. one mouse button), hover technically could be mapped to something like either the thumb button (mouse id 4) or as a more common option, to the right button (2), no?
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
User avatar
Nawias
Prole
Posts: 9
Joined: Sun Apr 10, 2022 4:13 pm
Location: Poland

Re: dslayout - Simulate Nintendo 3DS Screens on the desktop.

Post by Nawias »

Thanks for the reply :)

As for the hover, the goal of this lib is just to simulate the behaviour of 3DS/2DS screens. There's no way to hover with a stylus, so it's just "touch or not". I see no point in implementing hover - it might create situations where it works on the desktop and then you're scratching your head on why it doesn't work on the hardware, or you might just end up creating a feature that is not accessible because you forgot you're making it for a console that doesn't support it :P

Still, it's open source, so you can add a feature if you need it - you're free to make a pull request ^^
User avatar
zorg
Party member
Posts: 3435
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: dslayout - Simulate Nintendo 3DS Screens on the desktop.

Post by zorg »

My mistake actually, i guess i misunderstood the readme; i thought the 2DS/3DS *did* support hover and you just didn't implement it. If it doesn't, then it makes sense why that's not supported by your library either.
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
User avatar
Nawias
Prole
Posts: 9
Joined: Sun Apr 10, 2022 4:13 pm
Location: Poland

Re: dslayout - Simulate Nintendo 3DS Screens on the desktop.

Post by Nawias »

I thought that rather than using love.graphics.translate it would be better to render the bottom screen into a canvas and draw it with an offset. So I did just that, as it better mimics drawing to 2 separate screens, but it looks worse. It's on a separate branch until I get some time to figure out how to make it better. If you want to check it out, feel free to download from canvas-draw branch.
User avatar
Nawias
Prole
Posts: 9
Joined: Sun Apr 10, 2022 4:13 pm
Location: Poland

Re: dslayout - Simulate Nintendo 3DS Screens on the desktop.

Post by Nawias »

Figured it out after a long break. I just needed to adjust alpha blending as stated on the official wiki.

It's merged to master now and looks good.
Post Reply

Who is online

Users browsing this forum: No registered users and 12 guests