# Weird glitch

**URL:** https://forum.makecode.com/t/weird-glitch/30270
**Category:** Help
**Created:** [August 23, 2024, 12:20am UTC](https://forum.makecode.com/t/weird-glitch/30270 "2024-08-23T00:20:03Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![NeoStreak](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/neostreak/32/27498_2.png) [@NeoStreak](https://forum.makecode.com/u/NeoStreak)
#### Post date: [August 23, 2024, 12:20am UTC](https://forum.makecode.com/t/weird-glitch/30270/1 "2024-08-23T00:20:03Z")

</div>

For some reason if you go onto the ladder (yes, the ladder is glitchy) and the enemy approaches you, you get deleted from existence. But you’re supposed to touch them first. And also when being defeated you can move around. I tried to make the player (mario) stop moving, but you can still move when defeated. It’s like the game ignores it. Finally, pressing “A” makes you glitch. Idk why. Anyways, here’s the link. [https://arcade.makecode.com/S24605-15852-98096-20882](https://arcade.makecode.com/S24605-15852-98096-20882)  
Thanks.

---

<div class="post-metadata">

### Author: ![RobbyZero](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robbyzero/32/17188_2.png) [@RobbyZero](https://forum.makecode.com/u/RobbyZero)
#### Post date: [August 23, 2024, 2:02am UTC](https://forum.makecode.com/t/weird-glitch/30270/2 "2024-08-23T02:02:33Z")

</div>

Okay so number one (on my list) You set the controller to not go back to moving normal so you can’t get off the ladder.  
You set it so after 2 seconds you destroy the sprite so you get deleted  
And I believe setting the ay acceleration to zero prevents you from moving.

---

<div class="post-metadata">

### Author: ![RobbyZero](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/robbyzero/32/17188_2.png) [@RobbyZero](https://forum.makecode.com/u/RobbyZero)
#### Post date: [August 23, 2024, 2:02am UTC](https://forum.makecode.com/t/weird-glitch/30270/3 "2024-08-23T02:02:47Z")

</div>

Also pressing a glitches out because you changed the height Mario so the camera has to adjust.  
Would you like me to make a fixed version?

---

<div class="post-metadata">

### Author: ![platformermaster](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/platformermaster/32/16102_2.png) [@platformermaster](https://forum.makecode.com/u/platformermaster)
#### Post date: [August 23, 2024, 2:02am UTC](https://forum.makecode.com/t/weird-glitch/30270/4 "2024-08-23T02:02:56Z")

</div>

FOUND THE PROBLEM!

 ![Screenshot 2024-08-22 7.39.21 PM](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/3X/f/e/fe0f3b5c9b98a86fef18a276b6a5e667d6483d87.png)  
This is auto destroying the sprite once it overlaps with the ladder. This happens after 2 seconds. You would have to remove the “After 2000MS Destroy mySprite.” So thats what you need to remove to stop the sprite from dying.

---

<div class="post-metadata">

### Author: ![NeoStreak](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/neostreak/32/27498_2.png) [@NeoStreak](https://forum.makecode.com/u/NeoStreak)
#### Post date: [August 24, 2024, 12:24am UTC](https://forum.makecode.com/t/weird-glitch/30270/5 "2024-08-24T00:24:02Z")

</div>

Oh thanks. And I forgot to change it from a ladder to the enemy. My mistake. 😬

---

<div class="post-metadata">

### Author: ![NeoStreak](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/neostreak/32/27498_2.png) [@NeoStreak](https://forum.makecode.com/u/NeoStreak)
#### Post date: [August 24, 2024, 12:24am UTC](https://forum.makecode.com/t/weird-glitch/30270/6 "2024-08-24T00:24:04Z")

</div>

Idk why, but the code messed up when I made the link.

---

<div class="post-metadata">

### Author: ![NeoStreak](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/neostreak/32/27498_2.png) [@NeoStreak](https://forum.makecode.com/u/NeoStreak)
#### Post date: [August 24, 2024, 12:24am UTC](https://forum.makecode.com/t/weird-glitch/30270/7 "2024-08-24T00:24:08Z")

</div>

Sure, thanks.
