Skip to content
This repository was archived by the owner on Oct 24, 2020. It is now read-only.
This repository was archived by the owner on Oct 24, 2020. It is now read-only.

btn() and btnp() can't take emojis as arguments #28

@tobiasvl

Description

@tobiasvl

In PICO-8, the following code:

  if (btn(⬅️)) print("left")
  if (btn(➡️)) print("right")
  if (btn(⬆️)) print("up")
  if (btn(⬇️)) print("down")
  if (btn(🅾️)) print("o")
  if (btn(❎)) print("x")

is equivalent to:

  if (btn(0)) print("left")
  if (btn(1)) print("right")
  if (btn(2)) print("up")
  if (btn(3)) print("down")
  if (btn(4)) print("o")
  if (btn(5)) print("x")

However, in picolove, the if tests in the first example will always evaluate to true.

See also #27.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions