Search found 1680 matches

by raidho36
Fri Aug 10, 2018 5:35 pm
Forum: Support and Development
Topic: How to make a gradient across multiple
Replies: 2
Views: 194

Re: How to make a gradient across multiple

An on-screen pixel coordinate is passed into the shader function. You can leverage it to make such effects.
by raidho36
Wed Aug 08, 2018 1:48 pm
Forum: Support and Development
Topic: [SOLVED] Isometric Depth Perception
Replies: 4
Views: 211

Re: Isometric Depth Perception

In isometric view it should be very obvious if you're climbing upstairs, as they'd be "diagonal" and you'd clearly see them. Can you post a picture? To do the "relative z" you just subtract one from another! local z = player.z - cell.z Since this will now start at 0 and go positive and negative depe...
by raidho36
Mon Aug 06, 2018 11:43 pm
Forum: Support and Development
Topic: Can I save an image loaded with love.graphics.newImage() as png?
Replies: 6
Views: 316

Re: Can I save an image loaded with love.graphics.newImage() as png?

There is Object:release function which immediately frees up system-allocated memory. Setting the reference to nil would only work if there are no other references to it anywhere, and collectgarbage may not actually collect it on the first pass.
by raidho36
Sun Aug 05, 2018 7:46 pm
Forum: Support and Development
Topic: Can I save an image loaded with love.graphics.newImage() as png?
Replies: 6
Views: 316

Re: Can I save an image loaded with love.graphics.newImage() as png?

I don't think you should be overwriting any files (other than config.ini and such). If you want to do this, make a unique folder for them. It's normally impossible to overwrite game files as all the file write operations occur in appdata folder instead. But if you have your game files in that folder...
by raidho36
Sat Aug 04, 2018 1:02 am
Forum: General
Topic: I'm already pretty sold but I'd like reassurance that LÖVE is the right choice.
Replies: 3
Views: 513

Re: I'm already pretty sold but I'd like reassurance that LÖVE is the right choice.

You could approach the "runtime hacking" by making an API for the game which can be accessed from the files. The files would register callback functions in the game engine, and the game engine would call these functions as appropriate. This is fairly simple way of doing this, it's the same way LOVE ...
by raidho36
Sun Jul 22, 2018 11:49 am
Forum: Support and Development
Topic: Optimizing text drawing
Replies: 7
Views: 684

Re: Optimizing text drawing

40 fps is not half bad for a device like this. Industry "standard" framerate is in single digits. Try modifying the love.run function not to call the love.draw unless somewhere in love.update an appropriate flag is set. Don't update the screen either. Cut down on smooth animations to make use of thi...
by raidho36
Sun Jul 22, 2018 4:45 am
Forum: General
Topic: Beginner looking for advice
Replies: 7
Views: 772

Re: Beginner looking for advice

You can keep the snake segments as a list of coordinates. Every time it moves, a head cell is added at the head and tail cell is removed. When snake eats something, a head cell is added but tail cell is not removed.
by raidho36
Fri Jul 20, 2018 4:36 am
Forum: Support and Development
Topic: 512 FPS?
Replies: 7
Views: 557

Re: 512 FPS?

Default love.run function sleeps for 1 millisecond every frame. There is no need to sleep for 1 millisecond, you can sleep for 0 milliseconds and that will allow the OS scheduler to resume immediately, if no other threads need running, without wasting that 1 or more milliseconds. You can even forego...
by raidho36
Thu Jul 19, 2018 7:58 am
Forum: Support and Development
Topic: 512 FPS?
Replies: 7
Views: 557

Re: 512 FPS?

It doesn't cap at any specific number, but it yields CPU time to the OS for 1 millisecond. It is not guaranteed to resume operation in exactly that much time, but, excluding extreme cases, it will not resume operation in less than that time. Your OS probably returns control to the process in 1.9 mil...
by raidho36
Tue Jul 10, 2018 9:53 pm
Forum: Support and Development
Topic: Help, I upgraded to 11.1 and now everything's fucked
Replies: 3
Views: 365

Re: Help, I upgraded to 11.1 and now everything's fucked

You should probably use a PPA, the version in the official repo is outdated.