Palette does not work as expected
Consider this AS code:

```typescript
import * as w4 from "./wasm4";

store<u32>(w4.PALETTE, 0xe0f8cf, 0);    // light
store<u32>(w4.PALETTE, 0xe30000, 1);    // red
store<u32>(w4.PALETTE, 0x306850, 2);    // green
store<u32>(w4.PALETTE, 0x000000, 3);    // black

export function update (): void {
  // nothing here
}
```

I would expect the background colored in light green, but some kind of violet appears:

![image](https://user-images.githubusercontent.com/7925050/130268932-be27cf3f-123c-4878-8f48-afbbd4633eba.png)

Works fine when the other three colors are not set. 