become

From Wiki of ZZT
Revision as of 09:35, 8 February 2021 by Asie (talk | contribs) (Created page with "{{DISPLAYTITLE:become}} '''#become''' is a ZZT-OOP command that lets an object become a different kind of element. The syntax is <code>#become color element</code>. The c...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

#become is a ZZT-OOP command that lets an object become a different kind of element.

The syntax is #become color element. The color argument is optional. While the element argument is supposed to be mandatory, an empty string is treated as equivalent to a board edge. Providing an invalid element name will throw a Bad #BECOME error.

Bugs

  • Unlike other commands, #become color object will always destroy and create a new stat, clearing the object's character and source code.
    • The typical workaround for changing object colors is to use #change or #put instead.