Games-Axmud
view release on metacpan or search on metacpan
lib/Language/Axbasic.pm view on Meta::CPAN
'getroomnum' => '',
'getroomobjects' => ';S',
'ifacecount' => '',
'ifacedefined' => 'N',
'ifacepos' => '',
'ifacenum' => '',
'ifacestrings' => '',
'ifacetime' => '',
'isexit' => 'N',
'isfinished' => 'S',
'ishiddenexit' => 'N',
'isregion' => 'S',
'isroom' => 'N',
'isscript' => '',
'ismap' => '',
'istask' => '',
'istempregion' => 'S',
'iswin' => '',
'openmap' => '',
'sethiddenexit' => 'N',
'setlight' => 'S',
'setmapmode' => 'S',
'setornament' => 'N;S',
'setrandomexit' => 'N;S',
'setregion' => 'S',
'setregionnum' => 'N',
'setroomnum' => ';N',
'setroomtagged' => ';S',
'timestamp' => '',
# Axmud-dependent functions (returning a string value)
'abbrevdir$' => 'S',
'clientdate$' => '',
'clientname$' => '',
'clientversion$' => '',
'findtask$' => 'S',
'getexit$' => 'N',
'getexitdrawn$' => 'N',
'getexitstatus$' => 'N',
'getexittype$' => 'N',
'getlight$' => '',
'getmapmode$' => '',
'getobject$' => 'N',
'getobjectnoun$' => 'N',
'getobjecttype$' => 'N',
'getornament$' => 'N',
'getrandomexit$' => 'N',
'getregion$' => '',
'getroomdescrip$' => ';S',
'getroomguild$' => '',
'getroomsource$' => '',
'getroomtag$' => '',
'getroomtitle$' => '',
'iface$' => '',
'ifacedata$' => '',
'ifacename$' => '',
'ifacepop$' => '',
'ifaceselect$' => 'N',
'ifaceshift$' => '',
'ifacetext$' => '',
'ifacetype$' => '',
'popup$' => 'SSS',
'scriptname$' => '',
'showprofile$' => '',
'unabbrevdir$' => 'S',
},
# While parsing the script (in $self->parse), we need to keep track of whether the line
# being parsed is within a subroutine declaration, or whether it is outside one - so
# that we can detect subroutines declared inside another, and respond to correctly to
# an END SUB
# While parsing statements inside a subroutine declaration, this IV stores the
# LA::Subroutine. While parsing statements outside a subroutine declaration (but
# inside the implied *main subroutine), this IV is set to 'undef'
currentParseSub => undef,
# Needed by a few statements (most notably PRINT statements) to display stuff in the
# way that BASIC is accustomed to displaying stuff
column => 0,
# Variable declare mode
# When $self->parse processes a variable, it calls LA::Variable->lookup to find the
# LA::Variable in LA::Subroutine's ->localScalarHash / ->localArrayHash. If it's not
# there, it looks in this object's ->globalScalarHash / ->globalArrayHash
# If the variable isn't there, it hasn't been declared yet. In execution mode
# 'no_line_num', variables must be declared with GLOBAL or LOCAL statements before
# being used. (In execution mode 'line_num' (primitive line numbers), all variables
# are global and don't have to be declared, so this IV is ignored)
# This IV is normally set to 'default'. When $self->parse is processing a GLOBAL
# statement, it is briefly set to 'global_scalar' (for scalars) or 'global_array' (for
# arrays). When processing a LOCAL or SUB statement, it is briefly set to
# 'local_scalar' (for scalars) or 'local_array' (for arrays). When processing a PEEK
# or PEEK... statement, it is briefly set to 'peek_scalar' (for scalars) or
# 'peek_array' (for arrays)
# When processing a FOR EACH, POP, PUSH, SHIFT or UNSHIFT statement, or a SORT statement
# (or similar), it is set to 'simple'
# A non-'default' value tells ->lookup to declare the variable by adding it one of the
# declared variable hashes. Otherwise, when the script refers to an undeclared
# variable, an error is produced
declareMode => 'default',
# Global variable hashes
# A hash of global scalar variables, in the form
# $globalScalarHash{scalar_name} = blessed_reference_to_scalar_object
# (The object is a LA::Variable::Scalar::String or LA::Variable::Scalar::Numeric)
globalScalarHash => {},
# A hash of global array variables, in the form
# $globalArrayHash{array_name} = blessed_reference_to_array_object
# (The object is a LA::Variable::Array::String or LA::Variable::Array::Numeric)
globalArrayHash => {},
# Global data list - all the values in DATA statements, which are gathered by
# $self->parse and stored here until a READ statement accesses them
globalDataList => [],
# The same data list, with items removed by successive READ statements. The whole list
# is reset to match the contents of ->globalDataList by a RESTORE statement
readDataList => [],
# Hash of LA::FileChannel objects, each one representing a data file opened with an
# OPEN statement. Hash in the form
# $fileChannelHash{number} = blessed_reference_to_file_channel_object
fileChannelHash => {},
# Hash of things declared with the OPTION statement
( run in 1.040 second using v1.01-cache-2.11-cpan-364913b4093 )