These quickstart instructions cover only the most important parameters you might want to customize. All the configuration parameters are stored in .xml files, such as
These configuration files are located in the directory conf, which is a subdirectory of the root directory of the fraction game. The root directory is FractionGame, if you followed the installation instructions precisely. Before making changes to a configuration file it is recommended that you make a backup copy of the file, so that you can consult the old parameter settings if you are not satisfied with the new ones.
Note that each of the configuration files mentioned above contains all the parameter settings needed to start the Fraction Game. To customize the parameter settings, you probably might want to edit either the file targets-make-1024x768easy.xml or the file targets-make-1024x768hard.xml. The other two .xml files are produced automatically:
The above .xml files are devised for a screen resolution of 1024x768. If your monitor is set to another resolution, the simplest solution is to set it to the 1024x768 resolution within the operating system, e.g. on Windows in "Control Panel" -> "Display" -> "Settings" -> "Screen Resolution". If this isn't possible, you'll have to set the application's screen parameters in the .bat file starting the application to the desired resolution (or if you are using the applet version you will have to set the applet's parameters in the applet's web page to the desired resolution.) In addition you have to adjust the width and height parameters in the board tag of the .xml file on line 116. (The settings here should be slightly less than your desired resolution.)
</cognitive-load> <game background="teal" frames-per-second="30"> <board width="1016" height="698" color="gray"/> <score font="score"/> <end-message font="message">
Note that the font parameter in the score tag also influences the visible part of the board, so that you'll have to find the right combination of the board's width and height and the font's size, which is set on line 6 at the beginning of the file:
<fonts>
<font id="target-label" family="SansSerif" size="18" style="bold"/> <font id="message" family="SansSerif" size="36"/>
<font id="score" family="SansSerif" size="44" style="bold"/>
</fonts>
The following sections describe how to customize the following parameters of the Moving Target Fractions game. To adjust the difficulty of the game, you may want to modify only the following
and possibly the parameter duration of the game. For instance, the settings in the files targets-make-1024x768easy.xml and targets-make-1024x768hard.xml differ only in the settings of these four parameters.
Let us illustrate how to modify these parameter settings, using the configuration file targets-make-1024x768hard.xml as an example. All of the parameters discussed here are defined towards the end of the file targets-make-1024x768hard.xml. Once you restart the Fraction Game, you will see the changes taking effect. Note that the configuration file contains many more parameters, which are not described here, to keep things simple. If you are interested in how these additional parameters influence the game, please contact us.
The duration of the game is specified on line 122 (out of 163 lines) in the
configuration file targets-make-1024x768hard.xml.
To change the time span during which targets are emitted from 0.7 minutes to
1.5 minutes, change
<line>Thank you for your participation.</line> </end-message> <duration minutes="0.70"/> <target-look font="target-label" anti-alias="yes" full-color="yes">
<line>Thank you for your participation.</line> </end-message> <duration minutes="1.50"/> <target-look font="target-label" anti-alias="yes" full-color="yes">
You only need to change the number highlighted in bold. The other lines are
only shown to help you locate the position within the configuration file. Note
that the number you specify determines the amount of time during which targets
are produced. The total duration of the game will be longer, because a freshly
produced target still has to travel across the screen - and the game ends only
after all targets have disappeared from the screen.
The maximum angle (measured to the x-axis) at which targets are emitted, is
specified on line 133 (out of 163 lines) in the configuration file targets-make-1024x768hard.xml.
Angle values in the interval [0,90) make sense. To change the max-angle
from 60 to 30 degrees, change
<target-motion>
<!-- Maximum targets' angle to x-axis in degrees -->
<max-angle degrees="60"/>
<!-- Targets' horizontal speed in pixels per second -->
<speed pixels-per-second="60"/>
<target-motion>
<!-- Maximum targets' angle to x-axis in degrees -->
<max-angle degrees="30"/>
<!-- Targets' horizontal speed in pixels per second -->
<speed pixels-per-second="60"/>
You only need to change the number highlighted in bold. The other lines are only shown to help you locate the position within the configuration file.
The horizontal speed (measured in pixels per second) at which targets are emitted,
is specified on line 135 (out of 163 lines) in the configuration file targets-make-1024x768hard.xml.
To change the horizontal speed from 60 to 25 pixels per second, change
<max-angle degrees="60"/>
<!-- Targets' horizontal speed in pixels per second -->
<speed pixels-per-second="60"/>
</target-motion>
<generator call="edu.hawaii.ics.ami.game.fraction.ShuffledFractions">
<max-angle degrees="60"/>
<!-- Targets' horizontal speed in pixels per second -->
<speed pixels-per-second="25"/>
</target-motion>
<generator call="edu.hawaii.ics.ami.game.fraction.ShuffledFractions">
You only need to change the number highlighted in bold. The other lines are only shown to help you locate the position within the configuration file.
The number of targets emitted per second is specified on line 139 (out of 163
lines) in the configuration file targets-make-1024x768hard.xml.
To change the number of targets emitted per second from 1.4 to 2.7, change
<generator call="edu.hawaii.ics.ami.game.fraction.ShuffledFractions">
<!-- Number of targets born per second -->
<rate targets-per-second="1.4"/>
<!-- Ratio of correct fractions; 1:1 -->
<ratio correct="1" incorrect="1"/>
<generator call="edu.hawaii.ics.ami.game.fraction.ShuffledFractions">
<!-- Number of targets born per second -->
<rate targets-per-second="2.7"/>
<!-- Ratio of correct fractions; 1:1 -->
<ratio correct="1" incorrect="1"/>
You only need to change the number highlighted in bold. The other lines are only shown to help you locate the position within the configuration file.
The ratio of enemy targets (i.e. fractions above the threshold)
to friendly targets (i.e. fractions below the threshold) is specified on line
141 (out of 163 lines) in the configuration file targets-make-1024x768hard.xml.
To change the ratio from 1:1
(i.e. 50% enemy, 50% friendly) to 2:3 (i.e. 40% enemy, 60% friendly), change
<rate targets-per-second="1.4"/>
<!-- Ratio of correct fractions; 1:1 -->
<ratio correct="1" incorrect="1"/>
<!-- Maximum value of an enumerator -->
<enumerator max="9"/>
<rate targets-per-second="1.4"/>
<!-- Ratio of correct fractions; 1:1 -->
<ratio correct="2" incorrect="3"/>
<!-- Maximum value of an enumerator -->
<enumerator max="9"/>
You only need to change the two numbers highlighted in bold. The other lines are only shown to help you locate the position within the configuration file.
The maximum value for the enumerator in a fraction target is specified on line
143 (out of 163 lines) in the configuration file targets-make-1024x768hard.xml.
To change the maximum enumerator
from 99 to 49, change
<ratio correct="1" incorrect="1"/>
<!-- Maximum value of an enumerator -->
<enumerator max="99"/>
<!-- Maximum value of an denominator -->
<denominator max="99"/>
<ratio correct="1" incorrect="1"/>
<!-- Maximum value of an enumerator -->
<enumerator max="49"/>
<!-- Maximum value of an denominator -->
<denominator max="99"/>
You only need to change the number highlighted in bold. The other lines are only shown to help you locate the position within the configuration file.
The maximum value for the denominator in a fraction target is specified on
line 145 (out of 163 lines) in the configuration file targets-make-1024x768hard.xml.
To change the maximum denominator
from 99 to 199, change
<enumerator max="99"/>
<!-- Maximum value of an denominator -->
<denominator max="99"/>
<ranges>
<include>
<enumerator max="99"/>
<!-- Maximum value of an denominator -->
<denominator max="199"/>
<ranges>
<include>
You only need to change the number highlighted in bold. The other lines are only shown to help you locate the position within the configuration file.
The range of numbers, from which the produced fractions are drawn, is specified
from line 148 through line 153 (out of 163 lines) in the configuration file
targets-make-1024x768hard.xml.
The set is a subset of the rational numbers. It is constructed by the union
of pairwise disjunct open intervals. The probability is roughly uniformly distributed
over this subset. To change the set from {x : x in (0,1/3) or x in (1/3,2/3)}
to {x : x in (1/9,1/5) or x in (3/8,5/8) or x in (3/4,1)}, change
<ranges>
<include>
<from enumerator="0" denominator="1"/>
<to enumerator="1" denominator="3"/>
</include>
<include>
<from enumerator="1" denominator="3"/>
<to enumerator="2" denominator="3"/>
</include>
</ranges>
<ranges>
<include>
<from enumerator="1" denominator="9"/>
<to enumerator="1" denominator="5"/>
</include>
<include>
<from enumerator="3" denominator="8"/>
<to enumerator="5" denominator="8"/>
</include> <include> <from enumerator="3" denominator="4"/> <to enumerator="1" denominator="1"/> </include>
</ranges>
Note how each open interval defining your set corresponds to an (<include>,</include>) pair containing the boundaries of the interval. Also note that if you change the number of intervals comprising your set then the total number of lines in the file targets-make-1024x768hard.xml changes as well. You also want to make sure that you define the range of numbers in a way that makes sense with respect to the max. value allowed for the enumerator and with respect to the max. value allowed for the denominator. (E.g. avoid intervals which are so narrow that only a very few - or even no - fractions fit in.)
The threshold fraction that separates friendly targets (i.e. those with a fraction
value below the threshold) from enemy targets (i.e. those with a fraction value
above the threshold) is specified on line 158 (out of 163 lines) in the configuration
file targets-make-1024x768hard.xml.
To change the threshold from 1/3 to 2/7, change
<scoring call="edu.hawaii.ics.ami.game.fraction.SimpleFractionScorer">
<!-- Value above which score is positive -->
<treshold enumerator="1" denominator="3"/>
</scoring>
<output file="conf/targets-1024x768hard.xml"/>
<scoring call="edu.hawaii.ics.ami.game.fraction.SimpleFractionScorer">
<!-- Value above which score is positive -->
<treshold enumerator="2" denominator="7"/>
</scoring>
<output file="conf/targets-1024x768hard.xml"/>
You only need to change the two numbers highlighted in bold. The other lines are only shown to help you locate the position within the configuration file.
If you want to display gauges that show heuristic approximations of cognitive load in real time then you might also be interested in customizing these gauges. This can be done within the various evaluation tags within the configuration file. However, the description of these evaluation tags exceeds the scope of this short guide. Please contact us for further information. If you do not want to display gauges, you need not worry about the settings in the evaluation tags.