# How and is it possible to make custom hitboxes for sprites

**URL:** https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781
**Category:** Help
**Created:** [May 1, 2026, 7:41pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781 "2026-05-01T19:41:10Z")
**Posts on this page:** 11
**Page:** 1

<div class="post-metadata">

### Author: ![AlexTheGoober63](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexthegoober63/32/35080_2.png) [@AlexTheGoober63](https://forum.makecode.com/u/AlexTheGoober63)
#### Post date: [May 1, 2026, 7:41pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/1 "2026-05-01T19:41:10Z")

</div>

something i want for my sprites it to draw a custom hitbox, I don’t like that the pixels determine the hitbox because that will set restrictions for animating sprites, like if I draw my sprite in one frame a little too big, then it will sort of clip into the walls, please implement this feature makecode or maybe it already exists, it’s just that I don’t know how to get to it, and if thats the case pls help me i beg

---

<div class="post-metadata">

### Author: ![VoxelMaster64](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/voxelmaster64/32/32075_2.png) [@VoxelMaster64](https://forum.makecode.com/u/VoxelMaster64)
#### Post date: [May 1, 2026, 7:45pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/2 "2026-05-01T19:45:48Z")

</div>

make another sprite that does the hitbox checking and set the player to it’s location. the sprite should always be a rectangle

---

<div class="post-metadata">

### Author: ![Luke](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/luke/32/32519_2.png) [@Luke](https://forum.makecode.com/u/Luke)
#### Post date: [May 4, 2026, 7:10pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/3 "2026-05-04T19:10:44Z")

</div>

make 2 sprites, one for the image and one for the hitbox (fill the hitbox in with a colour).

Then ghost the image sprite so it doesn’t collide with anything and make the hitbox invisible (make sure you use the block that toggles it invisible)

Then use a game update loop set the image sprite position to the hitbox (make sure you control the movement of the hitbox, not the player sprite)  
Also keep in mind you can code in offsets if you want more precise control of where you want the hitbox to be relative to the sprite image

---

<div class="post-metadata">

### Author: ![AlexTheGoober63](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexthegoober63/32/35080_2.png) [@AlexTheGoober63](https://forum.makecode.com/u/AlexTheGoober63)
#### Post date: [May 4, 2026, 11:44pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/4 "2026-05-04T23:44:16Z")

</div>

how do I make invisible, and if you say change something in javascript, then imma just stick with what I have (i only code in block code cuz im bad at python as well even tho im in a computer science class)

---

<div class="post-metadata">

### Author: ![TheEarth](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/theearth/32/34579_2.png) [@TheEarth](https://forum.makecode.com/u/TheEarth)
#### Post date: [May 5, 2026, 3:07am UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/5 "2026-05-05T03:07:15Z")

</div>

still wish for not rectangular hitboxes

---

<div class="post-metadata">

### Author: ![VoxelMaster64](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/voxelmaster64/32/32075_2.png) [@VoxelMaster64](https://forum.makecode.com/u/VoxelMaster64)
#### Post date: [May 16, 2026, 9:18pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/6 "2026-05-16T21:18:44Z")

</div>

they already arent?

---

<div class="post-metadata">

### Author: ![TheEarth](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/theearth/32/34579_2.png) [@TheEarth](https://forum.makecode.com/u/TheEarth)
#### Post date: [May 17, 2026, 4:16am UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/7 "2026-05-17T04:16:15Z")

</div>

no they are

---

<div class="post-metadata">

### Author: ![VoxelMaster64](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/voxelmaster64/32/32075_2.png) [@VoxelMaster64](https://forum.makecode.com/u/VoxelMaster64)
#### Post date: [May 17, 2026, 4:18pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/8 "2026-05-17T16:18:13Z")

</div>

wait I worded that weird. Aren’t they already non-rectangle? Or are you talking about tileMap collisions?

---

<div class="post-metadata">

### Author: ![Tasty\_turnip2](https://avatars.discourse-cdn.com/v4/letter/t/e9c0ed/32.png) [@Tasty\_turnip2](https://forum.makecode.com/u/Tasty_turnip2)
#### Post date: [May 17, 2026, 4:19pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/9 "2026-05-17T16:19:49Z")

</div>

there is a block to set sprite invisible

---

<div class="post-metadata">

### Author: ![TheEarth](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/theearth/32/34579_2.png) [@TheEarth](https://forum.makecode.com/u/TheEarth)
#### Post date: [May 18, 2026, 5:38am UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/10 "2026-05-18T05:38:26Z")

</div>

no they are I’m pretty sure of that correct me if I’m wrong tho

---

<div class="post-metadata">

### Author: ![AlexTheGoober63](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexthegoober63/32/35080_2.png) [@AlexTheGoober63](https://forum.makecode.com/u/AlexTheGoober63)
#### Post date: [May 18, 2026, 9:12pm UTC](https://forum.makecode.com/t/how-and-is-it-possible-to-make-custom-hitboxes-for-sprites/43781/11 "2026-05-18T21:12:52Z")

</div>

thanks yall, maybe ill use it, but orobably no for my next game cuz too lazy
