Module Expr Str Assign NameStore ListLoad Str ImportFrom alias Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num ClassDef bases AttributeLoad NameLoad attr body Expr Str Assign NameStore Num FunctionDef arguments args NameParam NameParam defaults Num body Expr Str Return Call NameLoad keyword Call NameLoad BinOpMult Str Num keyword NameLoad decorator_list NameLoad FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assert CompareLtELtE Num NameLoad Num Return BinOpBitAnd SubscriptLoad AttributeLoad NameLoad attr Index NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assert CompareLtELtE Num NameLoad Num AugAssignBitOr SubscriptStore AttributeLoad NameLoad attr Index NameLoad BinOpBitAnd NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assert CompareLtELtE Num NameLoad Num AugAssignBitAnd SubscriptStore AttributeLoad NameLoad attr Index NameLoad BinOpBitAnd UnaryOpInvert NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assert CompareLtELtE Num NameLoad Num Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad BinOpBitAnd NameLoad NameLoad decorator_list decorator_list
N/A N/A The graphics flags section of a Pico-8 cart.

The graphics properties region consists of 256 bytes. The .p8
representation is 2 lines of 256 hexadecimal digits (128 bytes).

This represents eight flags for each of the 256 tiles in the main gfx
area. In the graphics editor, the flags are arranged left to right
from LSB to MSB: red=1, orange=2, yellow=4, green=8, blue=16, purple=32,
pink=64, peach=128.

 N/A __all__ N/A Gff N/A util N/A RED 1 N/A ORANGE 2 N/A YELLOW 4 N/A GREEN 8 N/A BLUE 16 N/A PURPLE 32 N/A PINK 64 N/A PEACH 128 N/A ALL 255 Gff N/A N/A util BaseSection N/A N/A The graphics properties section of a Pico-8 cart. N/A HEX_LINE_LENGTH_BYTES 128 empty N/A N/A cls version N/A 4 N/A N/A Create an empty instance.

        Returns:
          A Gff instance.
         N/A N/A cls data N/A bytearray N/A 256 version version N/A classmethod get_flags N/A N/A self id flags N/A N/A N/A Gets the value of a specific flag or flags.

        Given a tile ID and a flag, returns the value of the flag if
        it is set, or zero otherwise:
          if gff_obj.get_flags(0, BLUE):
              # The blue flag is set.

        You can bitwise-or (|) flag constants together to get more
        than one with a single call. The result is all of the set
        flags bitwise-or'd together:
          is_set = gff_obj.get_flags(0, RED | BLUE | PEACH)
          if is_set | BLUE:
              # The blue flag is set.

        Call with the ALL constant to get all flags in a single value.
          flags = gff_obj.get_flags(0, ALL)
         N/A N/A 0 id 255 N/A N/A N/A N/A self _data N/A id flags N/A set_flags N/A N/A self id flags N/A N/A N/A Sets one or more flags for a tile.

        This sets the specified flags, and leaves the other flags unchanged.

        You can bitwise-or (|) flag constants together to set more than one with
        a single call:
          gff_obj.set_flags(0, RED | BLUE | PEACH)

        Args:
          id: The Pico-8 ID of the tile (0-255).
          flags: The flags to set, bitwise-or'd together.
         N/A N/A 0 id 255 N/A N/A N/A self _data N/A id N/A flags ALL N/A clear_flags N/A N/A self id flags N/A N/A N/A Clears one or more flags for a tile.

        This clears the specified flags, and leaves the other flags unchanged.

        You can bitwise-or (|) flag constants together to clear more than one
        with a single call:
          gff_obj.clear_flags(0, RED | BLUE | PEACH)

        Args:
          id: The Pico-8 ID of the tile (0-255).
          flags: The flags to clear, bitwise-or'd together.
         N/A N/A 0 id 255 N/A N/A N/A self _data N/A id N/A N/A flags ALL N/A reset_flags N/A N/A self id flags N/A N/A N/A Resets all flags for a tile, then sets the given flags.

        This changes all flags for the tile so that only the specified flags are
        set.

        Args:
          id: The Pico-8 ID of the tile (0-255).
          flags: All flags to be set in the final state, bitwise-or'd together.
         N/A N/A 0 id 255 N/A N/A N/A self _data N/A id N/A flags ALL N/A N/A