"Questions that don't deserve their own thread" thread

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Locked
mojimi
Prole
Posts: 2
Joined: Mon Oct 10, 2016 12:48 am

Re: "Questions that don't deserve their own thread" thread

Post by mojimi »

pgimeno wrote:Hi mojimi, welcome to the forum.

The problem is rounding. You can't expect that grid to look exactly like it would look if it was originally made of tiles and then stretched. That will only happen in certain conditions (exact integer multiples, no bilinear filtering).

You can, however, use a quad to paint the image with repetition instead of drawing it multiple times. Take a look at [wiki](Image):setWrap[/wiki].
Ah of course! I guess that's why games have a set of resolutions you can choose from.

Should I use a quad for repetition even though I'm making a (hopefully randomly generated) tile based grid map?
User avatar
pgimeno
Party member
Posts: 3637
Joined: Sun Oct 18, 2015 2:58 pm

Re: "Questions that don't deserve their own thread" thread

Post by pgimeno »

If each tile is going to be different, that's obviously not going to work. Drawing the tiles "pixel-perfect" to a canvas and then stretching the canvas while drawing it will work.
User avatar
sherpal
Prole
Posts: 17
Joined: Wed Sep 14, 2016 9:29 am
Location: Belgium

Re: "Questions that don't deserve their own thread" thread

Post by sherpal »

Hello,
I have a very simple question about making multiplayer online games. Should I encrypt game messages when transmitting them to other party members? I'm not talking about passwords or so, but just plain game info like "player1 uses ability a".

Thank you for the answer :)
User avatar
raidho36
Party member
Posts: 2063
Joined: Mon Jun 17, 2013 12:00 pm

Re: "Questions that don't deserve their own thread" thread

Post by raidho36 »

No, but you should compress them.
User avatar
sherpal
Prole
Posts: 17
Joined: Wed Sep 14, 2016 9:29 am
Location: Belgium

Re: "Questions that don't deserve their own thread" thread

Post by sherpal »

Thanks for your answer!
raidho36 wrote:No, but you should compress them.
Could you explain this a tiny bit more? Specifically, what size of data shouldn't I exceed while sending messages?
In the Networking with UDP tutorial, one can read
Tutorial:Networking with UDP wrote:Additionally UDP datagrams have limited sizes; the luasocket Documentation specifically notes that it doesn't support anything over 8k, and frankly you should assume much less.
but the "assume much less" is a bit vague.

And, is there a "morally minimal" amount of data I should send at once?

Thanks again!
smunnelsnakzruule
Prole
Posts: 8
Joined: Thu Oct 13, 2016 12:36 pm

Re: "Questions that don't deserve their own thread" thread

Post by smunnelsnakzruule »

Hello everyone, nice forum you have here.

My question is this, how do I go about creating a simple "letterbox" resizable window with scalable graphics in love2D?

one like this:

Code: Select all


[img]http://www.acamara.es/blog/wp-content/uploads/2012/02/screenresolution-smartphone2fixed.png[/img]


[img]https://love2d.org/imgmirrur/WpIvk.png[/img]

[img]https://love2d.org/imgmirrur/IKKVc.png[/img]

[img]https://love2d.org/imgmirrur/VFlfX.png[/img]

[img]https://love2d.org/imgmirrur/swfA6.png[/img]



thanks
User avatar
raidho36
Party member
Posts: 2063
Joined: Mon Jun 17, 2013 12:00 pm

Re: "Questions that don't deserve their own thread" thread

Post by raidho36 »

sherpal wrote: Could you explain this a tiny bit more? Specifically, what size of data shouldn't I exceed while sending messages?
In the Networking with UDP tutorial, one can read
Tutorial:Networking with UDP wrote:Additionally UDP datagrams have limited sizes; the luasocket Documentation specifically notes that it doesn't support anything over 8k, and frankly you should assume much less.
but the "assume much less" is a bit vague.

And, is there a "morally minimal" amount of data I should send at once?
The internet network is a complex, limited system and its hurdles are felt by everyone involved. It's not about sticking to specific figures, it's about minimizing bandwidth into oblivion. Just always compress your data, it takes minimum amount of time - especially if you use a compression library such as zlib. And then reduce the overall traffic by sending less data and sending it less often.
User avatar
sherpal
Prole
Posts: 17
Joined: Wed Sep 14, 2016 9:29 am
Location: Belgium

Re: "Questions that don't deserve their own thread" thread

Post by sherpal »

raidho36 wrote:The internet network is a complex, limited system and its hurdles are felt by everyone involved. It's not about sticking to specific figures, it's about minimizing bandwidth into oblivion. Just always compress your data, it takes minimum amount of time - especially if you use a compression library such as zlib. And then reduce the overall traffic by sending less data and sending it less often.
Thanks, I guess that means that the more I practice, the better I'll get :p
I'll have a look at zlib, and related stuff :)
User avatar
ZodaInk
Prole
Posts: 18
Joined: Thu Jan 08, 2015 5:18 am

Re: "Questions that don't deserve their own thread" thread

Post by ZodaInk »

sherpal wrote:Thanks, I guess that means that the more I practice, the better I'll get :p
I'll have a look at zlib, and related stuff :)
Zlib compression is possible with love.math.compress, just letting you know. https://love2d.org/wiki/love.math.compress
User avatar
pgimeno
Party member
Posts: 3637
Joined: Sun Oct 18, 2015 2:58 pm

Re: "Questions that don't deserve their own thread" thread

Post by pgimeno »

smunnelsnakzruule wrote:Hello everyone, nice forum you have here.

My question is this, how do I go about creating a simple "letterbox" resizable window with scalable graphics in love2D?

one like this:

Image


Image

Image

Image

Image




thanks
I've removed the

Code: Select all

 tags from your post for the pictures to show.

You can draw to a canvas and then stretch or shrink the canvas at will.
Locked

Who is online

Users browsing this forum: Ahrefs [Bot], Google [Bot] and 3 guests