Discuss Scratch
- Discussion Forums
- » Questions about Scratch
- » What code do i do to know if someone loved or faved
- TRJDN
-
Scratcher
4 posts
What code do i do to know if someone loved or faved
What code do i do to know if someone loved or faved?
- TheDogLover796
-
Scratcher
1000+ posts
What code do i do to know if someone loved or faved
If someone loves or favorites your project that you make, it will show up in your messages, at the top right corner of your scratch screen.
Hope this helped! If you have any other questions related to this topic, feel free to ask on my profile.
Hope this helped! If you have any other questions related to this topic, feel free to ask on my profile.
Last edited by TheDogLover796 (Sept. 10, 2023 20:50:39)
- pasta_enjoyer7
-
Scratcher
1000+ posts
What code do i do to know if someone loved or faved
There are love and favorite detectors that you can find on Scratch. Just search ip “love and favorite detector” or something along those lines in the search bar. Then backpack the code from the project that you use, but make sure you credit the original source. If the person's project says, “Love and favorite detector from (other username here)”, then credit “other username” instead.
- TheDogLover796
-
Scratcher
1000+ posts
What code do i do to know if someone loved or faved
oh did i misunderstand the question? so sorry xD
- -Valtren-
-
Scratcher
1000+ posts
What code do i do to know if someone loved or faved
The code works based on the concept that a sprite's costume is residing over the heart and star buttons.
The sprite can still determine whether the mouse pointer is touching it, and thus figure out whether someone is at least having their mouse on the heart and star buttons.
TimMcCool shows this technique here.
-
A love and fave detector detects first whether the mouse is on the heart and star button then in what order they were detected. If the heart button is first detected then the fave button is detected, then it's likely that the user has loved and faved the project.
Here's an example of a heart and star detector.
And here's the code:

(Please keep in mind for this to work you need costumes that hover over the heart and star buttons)
The sprite can still determine whether the mouse pointer is touching it, and thus figure out whether someone is at least having their mouse on the heart and star buttons.
TimMcCool shows this technique here.
-
A love and fave detector detects first whether the mouse is on the heart and star button then in what order they were detected. If the heart button is first detected then the fave button is detected, then it's likely that the user has loved and faved the project.
Here's an example of a heart and star detector.
And here's the code:

(Please keep in mind for this to work you need costumes that hover over the heart and star buttons)
Last edited by -Valtren- (Sept. 11, 2023 01:13:02)
- Discussion Forums
- » Questions about Scratch
-
» What code do i do to know if someone loved or faved



