Log In  

Currently (v0.2.2c), manual states that:

pal c0 c1 [p]

    ...

    pal() resets to system defaults (including transparency values and fill pattern)

This appears to work for draw palette (p=0) and display palette (p=1) but not secondary palette (p=2).

We can still keep track of previous state from each change and restore them manually.
But there is no quick way reset to system defaults.

Test cart:

Cart #ruhezabawo-0 | 2021-03-17 | Code ▽ | Embed ▽ | No License


As a side note, the manual entry also states:

pal() swaps colour c0 for c1 for one of two palette re-mappings (p defaults to 0):

Shouldn't it be 'three palette re-mappings'?

P#71631 2021-03-17 06:36

Tacking on one more related feature request.

In v0.2.0 changelog:

Added: pal({1,2,3..}) means: use the value for each key 0..15 in a table
...
Changed: ..., pal(), ... return their previous state

The return value from pal(c0, c1, p) is useful for restoring palette to a previous state after some temporary color swaps.

Unfortunately, as at v0.2.2c the pal(tbl, p) form does not return any value, unlike its single-color cousin.

Test cart illustrating desired behavior:

Cart #fifakokeko-0 | 2021-03-17 | Code ▽ | Embed ▽ | No License

P#89393 2021-03-23 15:29

[Please log in to post a comment]