# Palette Help

**URL:** <https://forum.makecode.com/t/palette-help/4144>\
**Category:** Help\
**Created:** [October 28, 2020, 9:36pm UTC](https://forum.makecode.com/t/palette-help/4144 "2020-10-28T21:36:50Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 28, 2020, 9:36pm UTC](https://forum.makecode.com/t/palette-help/4144/1 "2020-10-28T21:36:50Z")

</div>

> **[Pixx Artist Pro](https://arcade.makecode.com/01161-71052-25145-97911)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

When I change my palette then click play, it doesn’t work. Why? Can someone fix it?

---

<div class="post-metadata">

**Author:** ![UnsignedArduino](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/unsignedarduino/32/592_2.png) [@UnsignedArduino](https://forum.makecode.com/u/UnsignedArduino)\
**Post date:** [October 29, 2020, 1:43am UTC](https://forum.makecode.com/t/palette-help/4144/2 "2020-10-29T01:43:17Z")

</div>

It seems to work for me. What’s happening to you?

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 29, 2020, 1:53am UTC](https://forum.makecode.com/t/palette-help/4144/3 "2020-10-29T01:53:58Z")

</div>

Did you go to palette, chose one, click done, and then go to play and start drawing?

---

<div class="post-metadata">

**Author:** ![UnsignedArduino](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/unsignedarduino/32/592_2.png) [@UnsignedArduino](https://forum.makecode.com/u/UnsignedArduino)\
**Post date:** [October 29, 2020, 2:04am UTC](https://forum.makecode.com/t/palette-help/4144/4 "2020-10-29T02:04:56Z")

</div>

Yup. The palette was changed.

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 29, 2020, 1:27pm UTC](https://forum.makecode.com/t/palette-help/4144/5 "2020-10-29T13:27:15Z")

</div>

Can you show a gif?

---

<div class="post-metadata">

**Author:** ![UnsignedArduino](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/unsignedarduino/32/592_2.png) [@UnsignedArduino](https://forum.makecode.com/u/UnsignedArduino)\
**Post date:** [October 29, 2020, 2:26pm UTC](https://forum.makecode.com/t/palette-help/4144/6 "2020-10-29T14:26:45Z")

</div>

@jwunderl figured it out!  
@GameGod here is it:

 ![arcade pallete](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/5/5427ffae27df704c0b351e3cfed6e50dc6f9c65d.gif)

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 29, 2020, 5:27pm UTC](https://forum.makecode.com/t/palette-help/4144/7 "2020-10-29T17:27:05Z")

</div>

Can you share the code? I know it is the same, maybe a new project will fix it.

---

<div class="post-metadata">

**Author:** ![cosmoscowboy](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/cosmoscowboy/32/1718_2.png) [@cosmoscowboy](https://forum.makecode.com/u/cosmoscowboy)\
**Post date:** [October 29, 2020, 9:37pm UTC](https://forum.makecode.com/t/palette-help/4144/8 "2020-10-29T21:37:53Z")

</div>

You have an impressive use of extensions here. Did you make them yourself?

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 29, 2020, 9:42pm UTC](https://forum.makecode.com/t/palette-help/4144/9 "2020-10-29T21:42:27Z")

</div>

> [@cosmoscowboy](#):
>
> Did you make them yourself?

No. Does the game work for you?

---

<div class="post-metadata">

**Author:** ![UnsignedArduino](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/unsignedarduino/32/592_2.png) [@UnsignedArduino](https://forum.makecode.com/u/UnsignedArduino)\
**Post date:** [October 29, 2020, 10:46pm UTC](https://forum.makecode.com/t/palette-help/4144/10 "2020-10-29T22:46:38Z")

</div>

Here:

> **[Pixx Artist Pro](https://arcade.makecode.com/70580-69828-48050-04992)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

  
Sorry for replying late.

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 29, 2020, 11:15pm UTC](https://forum.makecode.com/t/palette-help/4144/11 "2020-10-29T23:15:34Z")

</div>

> [@UnsignedArduino](#):
>
> Sorry for replying late.

It’s okay!

For some reason, it still doesn’t work for me. Is it a glitch?

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 30, 2020, 4:13pm UTC](https://forum.makecode.com/t/palette-help/4144/12 "2020-10-30T16:13:59Z")

</div>

Does anyone know why this might be happening? I want to add to my game, but it is not working. How does it work for others?

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 30, 2020, 4:20pm UTC](https://forum.makecode.com/t/palette-help/4144/13 "2020-10-30T16:20:09Z")

</div>

Actually, the problem is that the courser doesn’t show. I tried fixing it, but it doesn’t work.

---

<div class="post-metadata">

**Author:** ![shakao](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/shakao/32/113_2.png) [@shakao](https://forum.makecode.com/u/shakao)\
**Post date:** [October 30, 2020, 4:25pm UTC](https://forum.makecode.com/t/palette-help/4144/14 "2020-10-30T16:25:11Z")

</div>

Oh, I think you have a “set invisible” flag turned on for the pen sprite!

![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/b/bc96b3f31957560e043c39bf3d72c85213a9de13.png)

If you set invisible to false inside the code where you handle the “Play” menu option selection, it should show up on your canvas.

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 30, 2020, 5:27pm UTC](https://forum.makecode.com/t/palette-help/4144/15 "2020-10-30T17:27:28Z")

</div>

Yes! Such a simple mistake! Thanks! 😁

Now all I have to do is make the custom palette, save settings, and line drawing!

> **[Pixx Artist Pro](https://arcade.makecode.com/60212-99971-19876-81526)**
>
> Made with ❤️ in Microsoft MakeCode Arcade.

Art made with new color palettes:  
 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/d/d98daf7cedba9009d0956ff894cfb07572584c43.png)  
Cooking

---

<div class="post-metadata">

**Author:** ![LcAtonal](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/lcatonal/32/16800_2.png) [@LcAtonal](https://forum.makecode.com/u/LcAtonal)\
**Post date:** [October 31, 2020, 7:48am UTC](https://forum.makecode.com/t/palette-help/4144/16 "2020-10-31T07:48:00Z")

</div>

Among us  
 ![Screen Shot 2020-10-31 at 3.40.10 PM](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/6/6d33c905a3d702c4a526bb9eaa8ed0cbd6b40a09.png)

---

<div class="post-metadata">

**Author:** ![LcAtonal](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/lcatonal/32/16800_2.png) [@LcAtonal](https://forum.makecode.com/u/LcAtonal)\
**Post date:** [October 31, 2020, 11:17am UTC](https://forum.makecode.com/t/palette-help/4144/17 "2020-10-31T11:17:59Z")

</div>

How are you supposed to make new colour palettes?

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 31, 2020, 4:10pm UTC](https://forum.makecode.com/t/palette-help/4144/18 "2020-10-31T16:10:37Z")

</div>

I haven’t coded that yet.

---

<div class="post-metadata">

**Author:** ![jwunderl](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/jwunderl/32/5308_2.png) [@jwunderl](https://forum.makecode.com/u/jwunderl)\
**Post date:** [October 31, 2020, 5:46pm UTC](https://forum.makecode.com/t/palette-help/4144/19 "2020-10-31T17:46:31Z")

</div>

If you want to add custom palettes, heres a few pointers! I still haven’t come up with a fantastic design for authoring palettes in blocks that doesn’t require adding a new editor ☹

[https://github.com/jwunderl/pxt-color/blob/master/palettes.ts#L12](https://github.com/jwunderl/pxt-color/blob/master/palettes.ts#L12) is where I defined the palettes included in the extension. They use a `hex` literal string, which is sort of like imgs in arcade, except it creates a buffer of numbers. This is the easiest way to add palettes, if you know which ones you want - you can even make an extension of your own that just contains a file like that one and has a dependency on my color fading extension, and when people load your extension the palettes you make will get added to the drop down (just gotta copy the comments that start with //% and make sure things are in a namespace / exported)

If you want to stay in blocks, you can use the `set color 1 to color` block. You can put these in an array to keep all 16 colors for the custom palette, and then call set color for each on to apply the palette.

---

<div class="post-metadata">

**Author:** ![GameGod](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/gamegod/32/2756_2.png) [@GameGod](https://forum.makecode.com/u/GameGod)\
**Post date:** [October 31, 2020, 5:54pm UTC](https://forum.makecode.com/t/palette-help/4144/20 "2020-10-31T17:54:23Z")

</div>

> [@jwunderl](#):
>
> If you want to stay in blocks, you can use the `set color 1 to color` block. You can put these in an array to keep all 16 colors for the custom palette, and then call set color for each on to apply the palette.

That was what I was planning on doing, It makes it easier to store the values in settings.
