## Search found 70 matches

Wed Aug 09, 2017 5:03 pm
Forum: General
Topic: Need example code for grab and drop object with mouse?
Replies: 4
Views: 1635

### Re: Need example code for grab and drop object with mouse?

You can look at the code of my video puzzle:
https://love2d.org/forums/viewtopic.php ... 9&p=207465
Sun Aug 06, 2017 6:19 pm
Forum: Support and Development
Topic: Exchanging one color for a different one
Replies: 5
Views: 1429

### Re: Exchanging one color for a different one

You can also use Blendmodes to change the colors. I attached a small example code with the replacement function. It takes an image and two colors and gives you a canvas back with the new image. But it is costly to use every frame, because it create three canvas every time.
Wed Jul 26, 2017 8:00 pm
Forum: Support and Development
Topic: Simulating graphics.rotate by using other functions?
Replies: 6
Views: 1970

### Re: Simulating graphics.rotate by using other functions?

It is pretty simple since rotate, scale and shear are all linear transformations described by matrices (see source: /src/common/Matrix.cpp). You just have to multiply them and compare coefficients.

I attached a simple example.
Fri Mar 31, 2017 1:13 pm
Forum: Games and Creations
Topic: Minimal Tower Defense
Replies: 1
Views: 1718

### Re: Minimal Tower Defense

Nice game!

It took me a while to find a good strategy but then it was really easy. And I found a little bug: You can build towers below the last row. Take a look at the screenshot for both.
Fri Mar 31, 2017 1:10 pm
Forum: Support and Development
Topic: Make background image scrolling, an reapeating endless with only update part
Replies: 2
Views: 1897

### Re: Make background image scrolling, an reapeating endless with only update part

Since both positions of the background images advances at the same speed you do not need to calculate both. The only difference between the two is the height of the image (plus or minus). So you only have to draw them with an offset of the height of the image. I attached an example of this. But you ...
Sat Jan 14, 2017 1:06 am
Forum: Support and Development
Topic: Creating a menu background which "moves" based on the position of the mouse taking into consideration the screen edges
Replies: 2
Views: 898

### Re: Creating a menu background which "moves" based on the position of the mouse taking into consideration the screen edg

Here is a quick demo on how to do this.

Image by Francisco Osorio under CC BY 2.0
Tue Dec 27, 2016 1:29 pm
Forum: Games and Creations
Topic: Video puzzle
Replies: 9
Views: 3542

### Re: (buggy) video puzzle

bob_fossil wrote:Perhaps you can change the title of this thread now?
Done!

And I updated the first post to contain the newest version.
Mon Dec 26, 2016 9:07 am
Forum: Games and Creations
Topic: Video puzzle
Replies: 9
Views: 3542

### Re: (buggy) video puzzle

The following function does some basic sanity tests to the file object you get from love.filedropped to see if it is in the supported format: Thank you very much! :) I hoped that there was an easier way to check this, but your solution should work pretty good. You still need to make some changes or...
Sun Dec 25, 2016 7:57 pm
Forum: Games and Creations
Topic: Video puzzle
Replies: 9
Views: 3542

### Re: (buggy) video puzzle

Here is a new and faster version of the code. Take a look at the source if you like. The code should be easy to read. One more thing: a check for a stream format should be added. I.e. the app crashes when a wrong file format is dropped into it. That is still a thing I do not know how to do. Take a l...
Fri Sep 23, 2016 10:45 pm
Forum: Games and Creations
Topic: [WIP] ~ LANWolf - Mafia/Werewolf over LAN
Replies: 3
Views: 1616

### Re: [WIP] ~ LANWolf - Mafia/Werewolf over LAN

Nice Idea!

I think it would be easier if you only make the server in Löve and the client in HTML+JS. Then people could just use their smartphones without installing extra software. They just have to enter the IP-adress or scan a QR-code from the server.