-
Notifications
You must be signed in to change notification settings - Fork 21
Customization
This model Custom Model gives you the possibility to inherits from the initial model and to populate it with any new species of your choice.
Here is the different step in order to run your custom species on top of the original model
This will give you access to all the feature of the original model
import "CityScope_main.gaml"
In this case a simple species with a moving skills that wanders all over the world and displayed as a red circle.
species CustomSpecies skills:[moving]{
reflex move{
do wander;
}
aspect base{
draw circle(10#m) color:#red;
}
}
In this case we create 10 instances of CustomSpecies. The initialization of the imported model will also be called.
global{
init{
create CustomSpecies number:10;
}
}
customizedExperiment
inherits from CityScopeMain
so that you can display the initial model and add the CustomSpecies using the extra layer species CustomSpecies aspect:base;
You can eventually display only your customized species if you want to focus on their specific behavior.
experiment customizedExperiment type:gui parent:CityScopeMain{
output{
display CityScopeAndCustomSpecies type:opengl parent:CityScopeVirtual{
species CustomSpecies aspect:base;
}
display CustomSpeciesOnly type:opengl{
species CustomSpecies aspect:base;
}
}
}