# New Debugger and Custom Classes

**URL:** <https://forum.makecode.com/t/new-debugger-and-custom-classes/105>\
**Category:** Arcade\
**Created:** [April 3, 2019, 4:19am UTC](https://forum.makecode.com/t/new-debugger-and-custom-classes/105 "2019-04-03T04:19:16Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![AlexK](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexk/32/33339_2.png) [@AlexK](https://forum.makecode.com/u/AlexK)\
**Post date:** [April 3, 2019, 4:19am UTC](https://forum.makecode.com/t/new-debugger-and-custom-classes/105/1 "2019-04-03T04:19:16Z")

</div>

I noticed today that my MakeCode Arcade upgraded to version 0.8.11! I also noticed that the debugger is no longer an experiment. It’s been officially integrated into the release!

I’ve used the experimental debugger quite a bit as I created my projects, and I enjoyed using it. The integrated version looks wonderful! I noticed you’re able to dig into an object’s state (e.g. sprites), which was something you could not do with the experimental debugger. Great feature!

I noticed, too, that I _could not_ dig into objects made from my custom classes (e.g. those created by custom extensions). Is there some syntactic sugar that we need to add to those custom classes so that the debugger can show state information for objects created from them? Or will that be taken care of in a later version?

P.S. I’ve been meaning to run the latest branch (currently version 0.9.x) locally. If this has already been addressed in a more recent release, my apologies in advance for my ignorance.

---

<div class="post-metadata">

**Author:** ![richard](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/richard/32/5417_2.png) [@richard](https://forum.makecode.com/u/richard)\
**Post date:** [April 9, 2019, 12:47am UTC](https://forum.makecode.com/t/new-debugger-and-custom-classes/105/2 "2019-04-09T00:47:25Z")

</div>

Could you post/link your classes? User code should also work but there are a few caveats

---

<div class="post-metadata">

**Author:** ![AlexK](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexk/32/33339_2.png) [@AlexK](https://forum.makecode.com/u/AlexK)\
**Post date:** [April 9, 2019, 5:21am UTC](https://forum.makecode.com/t/new-debugger-and-custom-classes/105/3 "2019-04-09T05:21:03Z")

</div>

Thanks, @richard! I was playing around with the debugger in Acey Deucey. I noticed that the objects created from classes in my custom extension were not showing state. (I created a breakpoint in the drawCard() function.)

> **[Acey Deucey](https://arcade.makecode.com/42686-68397-09264-21252)**
>
> Made with ❤️ in MakeCode Arcade.

---

<div class="post-metadata">

**Author:** ![richard](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/richard/32/5417_2.png) [@richard](https://forum.makecode.com/u/richard)\
**Post date:** [April 11, 2019, 9:25pm UTC](https://forum.makecode.com/t/new-debugger-and-custom-classes/105/4 "2019-04-11T21:25:02Z")

</div>

Sorry for the delay, looks like you’re using getters in your card extension so you’ll need to add `callInDebugger` to the comment annotation for each getter. We only invoke getters that have that annotation because getters can have side effects (even though it’s bad practice) and our runtime does not currently have the ability to prevent those side effects from happening.

---

<div class="post-metadata">

**Author:** ![AlexK](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/alexk/32/33339_2.png) [@AlexK](https://forum.makecode.com/u/AlexK)\
**Post date:** [April 13, 2019, 12:43am UTC](https://forum.makecode.com/t/new-debugger-and-custom-classes/105/5 "2019-04-13T00:43:47Z")

</div>

Brilliant! Thanks, @richard! I’ve updated my playing cards extension with the comment annotation where appropriate. Seems to be working quite well. I’ll remember that for future extensions.
