CompilerConfig defines what part of the Selfless Heroes language can be used by
the player to solve the level.
-
excludePrimary
[string array] list of primary statements keywords to be
forbidden in the level. See the
documentation on primary statements for more details
on the keywords that can get into this array. required
-
valueFunctions
[string array] list of value functions keywords available
in the level. See the documentation on value functions
for more details on the keywords that can get into this array. default:
[]
-
actionFunctions
[string array] list of action functions keywords available
in the level. See the documentation on action functions
for more details on the keywords that can get into this array. required
-
leftComparisonExpressions
[string array] defines which expression types
are available for the left part of if
comparisons. See the
documentation about expression types for more details
on the keywords that can get into this array. These types will be displayed
in the left dropdown menu of the if
block in the same order as you specify
them in this array. required
-
rightComparisonExpressions
[string array] defines which expression types
are available for the right part of if
comparisons. See the
documentation about expression types for more details
on the keywords that can get into this array. These types will be displayed
in the right dropdown menu of the if
block in the same order as you
specify them in this array. required
-
forbiddenExpressions
[string array] defines which expression types are
forbidden in the level. See the
documentation about expression types for more details
on the keywords that can get into this array. default: []
-
terrainTypes
[string array] defines which terrain types are available in
the level. See the documentation about terrain types for
more details on the keywords that can get into this array. These types will
be displayed in the dropdown menu of the if
block in the same order as you
specify them in this array. required
-
objectTypes
[string array] defines which terrain types are available in
the level. See the documentation about object types for
more details on the keywords that can get into this array. These types will
be displayed in the dropdown menu of the if
block in the same order as you
specify them in this array. required
-
variables
[integer] number of variables available in the level. Maximum
value: 26
. default: 0
-
messages
[integer] number of different messages available in the level.
Maximum value: 8
. default: 0
-
minInteger
[integer] minimum value of integer literals in the level.
default: 0
-
maxInteger
[integer] maximum value of integer literals in the level.
default: 99
-
cloneIsDeadly
[boolean] if true
, when a hero tries to create a clone on
a square already occupied (by a hero, a cauldron etc.) or on a forbidden
square (like a wall), the hero will die. default: false
Primary statements are the different types of statements of first level in
Selfless Heroes language.
keyword |
description |
if |
if statement |
jump |
jump statement |
clone |
clone statement |
assign |
assignment statement: anything like $a = function() . |
action |
action functions: all functions that are not used in an assignment. example: step() . |
Value functions are functions that return a value.
keyword |
usage |
set |
$a = set(1) |
calc |
$a = calc($b + 1) |
nearest |
$a = nearest(egg) |
Action functions are functions that don't return any value.
keyword |
usage |
step |
step(e) |
fireball |
fireball(e) |
take |
take(e) |
drop |
drop(e) |
write |
write(1) |
tell |
tell("hey" everyone) |
listen |
listen("hey") |
keyword |
ico |
floor |
|
wall |
|
hole |
|
infected |
|
keyword |
ico |
nothing |
|
hero |
|
npc |
|
switch |
|
bonfire |
|
cauldron |
|
spikes |
|
egg |
|
keyword |
name |
here |
here |
e |
east |
s |
south |
w |
west |
n |
north |
nw |
northwest |
ne |
northeast |
se |
southeast |
sw |
southwest |
keyword |
ico |
"hey" |
|
"lol" |
|
"ho" |
|
"kiss" |
|
"stop" |
|
"wait" |
|
"ok" |
|
"coffee" |
|