Ah, that changes things a fair bit. I was merely going by the behaviour you had originally - $4 eq 'play' doesn't return 'true' and 'false' but '1' and undef. One alternative is to use a function that converts, such as:
Then you could use bool2str($control{play}) to get the strings you want.sub bool2str { shift ? 'true' : 'false' }
In reply to Re^3: setting up boolean parameters from keywords
by Tanktalus
in thread setting up boolean parameters from keywords
by rand0mmm
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |