Welcome to the Creatures Wiki! Log in and join the community.

HIST GEND

From Creatures Wiki
Revision as of 07:08, 9 September 2022 by Allekha (talk | contribs) (Created page with "'''HIST GEND''' is a CAOS command that returns the sex of a creature with a given moniker. ==Usage== Syntax: ''HIST GEND moniker(str)'' Returns -1 for unborn creatur...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

HIST GEND is a CAOS command that returns the sex of a creature with a given moniker.

Usage[edit]

Syntax: HIST GEND moniker(str)

Returns -1 for unborn creatures, 1 for males, and 2 for females.

Example[edit]

The workshop screen, when displaying info about a creature, retrieves whether it is male or female:

sets va00 gtos 0
...
setv va02 hist gend va00
doif va02 eq 1
	sets va02 read "gender" 0
elif va02 eq 2
	sets va02 read "gender" 1
else
	sets va02 " "
endi