# Browser Events Help

**URL:** https://forum.makecode.com/t/browser-events-help/35001
**Category:** Help
**Tags:** extension, game
**Created:** [March 29, 2025, 6:00pm UTC](https://forum.makecode.com/t/browser-events-help/35001 "2025-03-29T18:00:52Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![DAJurewicz](https://avatars.discourse-cdn.com/v4/letter/d/e95f7d/32.png) [@DAJurewicz](https://forum.makecode.com/u/DAJurewicz)
#### Post date: [March 29, 2025, 6:00pm UTC](https://forum.makecode.com/t/browser-events-help/35001/1 "2025-03-29T18:00:52Z")

</div>

So, I am trying to make it so that when I click on a sprite (text sprite), a pop-up menu will show up. (This is for making an update notes message)… I have tried many methods, but I am curious if anyone knows how to accomplish this.

---

<div class="post-metadata">

### Author: ![WoofWoof](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/woofwoof/32/32523_2.png) [@WoofWoof](https://forum.makecode.com/u/WoofWoof)
#### Post date: [March 30, 2025, 1:32am UTC](https://forum.makecode.com/t/browser-events-help/35001/2 "2025-03-30T01:32:22Z")

</div>

Welcome to the Makecode forum @DAJurewicz!  
Here is some code for detecting if the mouse is clicking a text sprite! It will work for any sprite, but for the demo I used a text sprite:

> **[cursor clicking sprite detection](https://arcade.makecode.com/S73652-34274-98216-31473)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

The “right click” code works only if you aren’t moving the camera around, or if the sprite is “relative to camera”.

The “left click” code works no matter where you move the camera, but it’s slightly more complicated, and it _doesn’t_ work if your sprite is “relative to camera” (if it’s ‘relative’, it would still work if the camera was where it starts, but not if the camera has been moved)

If you make your own copy of this demo, you should be able to copy/paste code from the copy straight into your game, which is a very new Makecode feature!

---

<div class="post-metadata">

### Author: ![DAJurewicz](https://avatars.discourse-cdn.com/v4/letter/d/e95f7d/32.png) [@DAJurewicz](https://forum.makecode.com/u/DAJurewicz)
#### Post date: [March 31, 2025, 12:35am UTC](https://forum.makecode.com/t/browser-events-help/35001/3 "2025-03-31T00:35:54Z")

</div>

Hey, thanks! I really appreciate the help and the welcome! Random question for you. In the same project, I have a button function and I also have the button combos extension. Down below in the section labeled “button functions” in [this project](https://arcade.makecode.com/S11001-53992-05795-12678), do you know why my basic A and B functions are not working when I press them after using the A+B combo? I’ve been trying to fix this problem that arised for like a week haha. Sorry I keep giving you more problems and issues lol.

---

<div class="post-metadata">

### Author: ![WoofWoof](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/woofwoof/32/32523_2.png) [@WoofWoof](https://forum.makecode.com/u/WoofWoof)
#### Post date: [March 31, 2025, 4:54pm UTC](https://forum.makecode.com/t/browser-events-help/35001/4 "2025-03-31T16:54:04Z")

</div>

I’m mostly on this forum to help, so ask away!

I… can’t seem to find the issue you are describing? After pressing A and B to activate that map thingy, I can still use both A and B functions, until of course I run out of “uses” that is. Could it be something where your keys are bugging and pressing the buttons multiple times rapidly when you use a+b, making you run out of uses really fast without you noticing? That is the only thing I can think of. Maybe try making the monkey “say” the “a uses” variable, so that you know what number it’s at while you play. Also make sure to keep in mind the number of uses required to activate the effect, for example level 1 requires the “a uses” number to be 2 or lower to activate the effect!  
Also keep in mind that using the a+b combo uses up a normal A and B function, so maybe you have to code something to prevent that or give the player those wasted uses back?
