diff --git a/Environment/volcanoes.xml b/Environment/volcanoes.xml
index b2a0916db..11aa3486a 100644
--- a/Environment/volcanoes.xml
+++ b/Environment/volcanoes.xml
@@ -24,5 +24,13 @@
0
0
+
+ 0
+
+
+
+ 0
+
+
diff --git a/Models/Volcanoes/Eyjafjallajokull/ash.png b/Models/Volcanoes/Eyjafjallajokull/ash.png
new file mode 100755
index 000000000..acf8bcfdc
Binary files /dev/null and b/Models/Volcanoes/Eyjafjallajokull/ash.png differ
diff --git a/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull.nas b/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull.nas
new file mode 100755
index 000000000..1b1335631
--- /dev/null
+++ b/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull.nas
@@ -0,0 +1,71 @@
+ var eyjafjallajokull_ash_loop_flag = 0;
+
+ var eyjafjallajokull_main_factor = 1.0;
+ var eyjafjallajokull_main_probability = 0.985;
+
+ var eyjafjallajokull_pos = geo.Coord.new().set_latlon(63.628335, -19.62823);
+
+
+ var eyjafjallajokull_ash_loop = func (timer) {
+
+ if (eyjafjallajokull_ash_loop_flag == 0)
+ {
+ print("Ending Eyjafjallajökull ash eruption simulation.");
+ return;
+ }
+
+ if (timer < 0.0)
+ {
+
+ if (rand() > 0.6)
+ {
+ setprop("/environment/volcanoes/eyjafjallajokull/ash-main-alpha", (rand() - 0.5) * 60.0);
+ setprop("/environment/volcanoes/eyjafjallajokull/ash-main-beta", (rand() - 0.5) * 60.0);
+ }
+ else
+ {
+ setprop("/environment/volcanoes/eyjafjallajokull/ash-main-alpha", 0.0);
+ setprop("/environment/volcanoes/eyjafjallajokull/ash-main-beta", 0.0);
+ }
+ timer = 2.0 + 3.0 * rand();
+ }
+
+ var aircraft_pos = geo.aircraft_position();
+ var dist = aircraft_pos.distance_to(eyjafjallajokull_pos);
+ var turbulence = 1000000.0/(dist * dist);
+ if (turbulence > 1.0) {turbulence = 1.0;}
+
+ setprop("/environment/volcanoes/turbulence", turbulence);
+
+ timer = timer - 0.1;
+
+ settimer(func {eyjafjallajokull_ash_loop(timer);}, 0.1);
+ }
+
+
+ eyjafjallajokull_state_manager = func {
+
+ var state_main = getprop("/environment/volcanoes/eyjafjallajokull/main-activity");
+
+ if ( (state_main > 0) and (eyjafjallajokull_ash_loop_flag == 0))
+ {
+ print ("Starting Eyjafjallajökull ash eruption simulation.");
+ eyjafjallajokull_ash_loop_flag = 1;
+ eyjafjallajokull_ash_loop(0.0);
+ }
+ else if ((state_main < 1) and (eyjafjallajokull_ash_loop_flag == 1))
+ {
+ eyjafjallajokull_ash_loop_flag = 0;
+ setprop("/environment/volcanoes/turbulence", 0);
+
+ }
+
+
+
+
+ }
+
+ # call state manager once to get correct autosaved behavior, otherwise use listener
+
+ eyjafjallajokull_state_manager();
+ setlistener("/environment/volcanoes/eyjafjallajokull/main-activity", eyjafjallajokull_state_manager);
\ No newline at end of file
diff --git a/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull_main_ash_eruption.xml b/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull_main_ash_eruption.xml
new file mode 100755
index 000000000..e7d996907
--- /dev/null
+++ b/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull_main_ash_eruption.xml
@@ -0,0 +1,110 @@
+
+
+
+
+
+
+ eyjafjallajokull-main-ash-eruption
+ ash.png
+ false
+ false
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+
+
+ global
+
+
+ point
+
+
+
+ 0
+ 5
+ 0
+ 360
+
+ 320
+ 300
+
+
+ 0
+ 0
+ -20
+ 0
+ 0
+ 20
+
+
+
+
+
+ 4
+ 1
+
+
+
+ billboard
+
+
+
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ 0.5
+
+
+
+ 350.0
+
+
+
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ 0.3
+
+
+
+ 2550.0
+
+
+
+ 120
+
+ 6.15
+ 0.05
+
+
+
+ air
+ false
+ true
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull_main_ash_eruption_secondary.xml b/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull_main_ash_eruption_secondary.xml
new file mode 100755
index 000000000..bea4fa767
--- /dev/null
+++ b/Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull_main_ash_eruption_secondary.xml
@@ -0,0 +1,142 @@
+
+
+
+
+
+
+ eyjafjallajokull-main-ash-eruption-secondary
+ ash.png
+ false
+ false
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+
+
+ global
+
+
+ point
+
+
+
+ 0
+ 5
+ 0
+ 360
+
+ 240
+ 220
+
+
+ 0
+ 0
+ -20
+ 0
+ 0
+ 20
+
+
+
+
+
+ 6
+ 1
+
+
+
+ billboard
+
+
+
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ 0.5
+
+
+
+ 150.0
+
+
+
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ 0.3
+
+
+
+ 950.0
+
+
+
+ 80
+
+ 6.15
+ 0.05
+
+
+
+ air
+ false
+ true
+
+
+
+
+
+
+ eyjafjallajokull-main-ash-eruption-secondary
+ rotate
+ /environment/volcanoes/eyjafjallajokull/ash-main-alpha
+ 1
+
+ 0
+ 0
+ 0
+
+
+ 0
+ 1
+ 0
+
+
+
+
+ eyjafjallajokull-main-ash-eruption-secondary
+ rotate
+ /environment/volcanoes/eyjafjallajokull/ash-main-beta
+ 1
+
+ 0
+ 0
+ 0
+
+
+ 1
+ 0
+ 0
+
+
+
+
\ No newline at end of file
diff --git a/Models/Volcanoes/Eyjafjallajokull/main_crater.xml b/Models/Volcanoes/Eyjafjallajokull/main_crater.xml
new file mode 100755
index 000000000..0af02291d
--- /dev/null
+++ b/Models/Volcanoes/Eyjafjallajokull/main_crater.xml
@@ -0,0 +1,48 @@
+
+
+
+
+
+
+
+
+
+
+
+ eyjafjallajokull_main_ash_eruption.xml
+
+ 0.0
+ 0.0
+ 0.0
+ 0
+
+
+
+ /environment/volcanoes/eyjafjallajokull/main-activity
+ 1
+
+
+
+
+
+ eyjafjallajokull_main_ash_eruption_secondary.xml
+
+ 0.0
+ 0.0
+ 0.0
+ 0
+
+
+
+ /environment/volcanoes/eyjafjallajokull/main-activity
+ 1
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Models/Volcanoes/Katla/ash.png b/Models/Volcanoes/Katla/ash.png
new file mode 100755
index 000000000..acf8bcfdc
Binary files /dev/null and b/Models/Volcanoes/Katla/ash.png differ
diff --git a/Models/Volcanoes/Katla/katla.nas b/Models/Volcanoes/Katla/katla.nas
new file mode 100755
index 000000000..5f92ad503
--- /dev/null
+++ b/Models/Volcanoes/Katla/katla.nas
@@ -0,0 +1,71 @@
+ var katla_ash_loop_flag = 0;
+
+ var katla_main_factor = 1.0;
+ var katla_main_probability = 0.985;
+
+ var katla_pos = geo.Coord.new().set_latlon(63.65750, -19.182871);
+
+
+ var katla_ash_loop = func (timer) {
+
+ if (katla_ash_loop_flag == 0)
+ {
+ print("Ending Katla ash eruption simulation.");
+ return;
+ }
+
+ if (timer < 0.0)
+ {
+
+ if (rand() > 0.6)
+ {
+ setprop("/environment/volcanoes/katla/ash-main-alpha", (rand() - 0.5) * 60.0);
+ setprop("/environment/volcanoes/katla/ash-main-beta", (rand() - 0.5) * 60.0);
+ }
+ else
+ {
+ setprop("/environment/volcanoes/katla/ash-main-alpha", 0.0);
+ setprop("/environment/volcanoes/katla/ash-main-beta", 0.0);
+ }
+ timer = 2.0 + 3.0 * rand();
+ }
+
+ var aircraft_pos = geo.aircraft_position();
+ var dist = aircraft_pos.distance_to(katla_pos);
+ var turbulence = 25000000.0/(dist * dist);
+ if (turbulence > 1.0) {turbulence = 1.0;}
+
+ setprop("/environment/volcanoes/turbulence", turbulence);
+
+ timer = timer - 0.1;
+
+ settimer(func {katla_ash_loop(timer);}, 0.1);
+ }
+
+
+ katla_state_manager = func {
+
+ var state_main = getprop("/environment/volcanoes/katla/main-activity");
+
+ if ( (state_main > 0) and (katla_ash_loop_flag == 0))
+ {
+ print ("Starting Katla ash eruption simulation.");
+ katla_ash_loop_flag = 1;
+ katla_ash_loop(0.0);
+ }
+ else if ((state_main < 1) and (katla_ash_loop_flag == 1))
+ {
+ katla_ash_loop_flag = 0;
+ setprop("/environment/volcanoes/turbulence", 0);
+
+ }
+
+
+
+
+ }
+
+ # call state manager once to get correct autosaved behavior, otherwise use listener
+
+ katla_state_manager();
+ setlistener("/environment/volcanoes/katla/main-activity", katla_state_manager);
\ No newline at end of file
diff --git a/Models/Volcanoes/Katla/katla_plinian_eruption.xml b/Models/Volcanoes/Katla/katla_plinian_eruption.xml
new file mode 100755
index 000000000..095d45700
--- /dev/null
+++ b/Models/Volcanoes/Katla/katla_plinian_eruption.xml
@@ -0,0 +1,141 @@
+
+
+
+
+
+
+ katla-plinian-eruption
+ ash.png
+ false
+ false
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+ 0.0
+
+
+ global
+
+
+ point
+
+
+
+ 0
+ 5
+ 0
+ 360
+
+ 550
+ 500
+
+
+ 0
+ 0
+ -10
+ 0
+ 0
+ 10
+
+
+
+
+
+ 32
+ 1
+
+
+
+ billboard
+
+
+
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ 0.6
+
+
+
+ 800.0
+
+
+
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ /rendering/scene/diffuse/green
+
+
+ 0.3
+
+
+
+ 8850.0
+
+
+
+ 120
+
+ 6.15
+ 0.015
+
+
+
+ air
+ false
+ true
+
+
+
+
+
+ katla-plinian-eruption
+ rotate
+ /environment/volcanoes/katla/ash-main-alpha
+ 1
+
+ 0
+ 0
+ 0
+
+
+ 0
+ 1
+ 0
+
+
+
+
+ katla-plinian-eruption
+ rotate
+ /environment/volcanoes/katla/ash-main-beta
+ 1
+
+ 0
+ 0
+ 0
+
+
+ 1
+ 0
+ 0
+
+
+
+
\ No newline at end of file
diff --git a/Models/Volcanoes/Katla/main_crater.xml b/Models/Volcanoes/Katla/main_crater.xml
new file mode 100755
index 000000000..6e298de1c
--- /dev/null
+++ b/Models/Volcanoes/Katla/main_crater.xml
@@ -0,0 +1,34 @@
+
+
+
+
+
+
+
+
+
+
+
+ katla_plinian_eruption.xml
+
+ 0.0
+ 0.0
+ 0.0
+ 0
+
+
+
+ /environment/volcanoes/katla/main-activity
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Nasal/volcano.nas b/Nasal/volcano.nas
index f21f2f1b0..b447df1c3 100644
--- a/Nasal/volcano.nas
+++ b/Nasal/volcano.nas
@@ -129,6 +129,20 @@ geo.put_model("Models/Volcanoes/Beerenberg/main_crater.xml", 71.0805, -8.1496 );
}
+var set_eyjafjallajokull = func {
+
+io.include("Models/Volcanoes/Eyjafjallajokull/eyjafjallajokull.nas");
+geo.put_model("Models/Volcanoes/Eyjafjallajokull/main_crater.xml", 63.628335, -19.62823 );
+
+}
+
+var set_katla = func {
+
+io.include("Models/Volcanoes/Katla/katla.nas");
+geo.put_model("Models/Volcanoes/Katla/main_crater.xml", 63.65750, -19.182871 );
+
+}
+
# volcano definitions
var kilauea = volcano.new("Kilauea", 19.39, -155.20);
@@ -147,6 +161,13 @@ var beerenberg = volcano.new("Beerenberg", 71.08, -8.15);
beerenberg.set = set_beerenberg;
append(volcano_manager.volcano_array, beerenberg);
+var eyjafjallajokull = volcano.new("Eyjafjallajokull", 63.62, -19.62);
+eyjafjallajokull.set = set_eyjafjallajokull;
+append(volcano_manager.volcano_array, eyjafjallajokull);
+
+var katla = volcano.new("Katla", 63.65750, -19.182871);
+katla.set = set_katla;
+append(volcano_manager.volcano_array, katla);
# start the manager when autosaved (need some delay for terrain loading to finish)
diff --git a/gui/dialogs/volcano-eyjafjallajokull.xml b/gui/dialogs/volcano-eyjafjallajokull.xml
new file mode 100755
index 000000000..5c31fe1cb
--- /dev/null
+++ b/gui/dialogs/volcano-eyjafjallajokull.xml
@@ -0,0 +1,111 @@
+
+
+
+ Eyjafjallajokull
+ vbox
+ 1
+ false
+ 400
+
+
+ 6
+
+
+
+
+
+
+
+ 4
+
+
+
+
+
+ table
+
+
+
+ left
+ 0
+ 0
+
+
+
+
+ 0
+ 1
+
+
+
+ main
+ 0
+ 2
+ 0
+ 1
+ 1
+ true
+ /environment/volcanoes/eyjafjallajokull/main-activity
+
+ dialog-apply
+ main
+
+
+
+
+
+ 0
+ 3
+
+
+
+
+
+
+
+
+
+
+
+
+ 12
+
+
+
+
+
+ 20
+
+
+
+ table
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/gui/dialogs/volcano-katla.xml b/gui/dialogs/volcano-katla.xml
new file mode 100755
index 000000000..9cd1ee87d
--- /dev/null
+++ b/gui/dialogs/volcano-katla.xml
@@ -0,0 +1,111 @@
+
+
+
+ Katla
+ vbox
+ 1
+ false
+ 400
+
+
+ 6
+
+
+
+
+
+
+
+ 4
+
+
+
+
+
+ table
+
+
+
+ left
+ 0
+ 0
+
+
+
+
+ 0
+ 1
+
+
+
+ main
+ 0
+ 2
+ 0
+ 1
+ 1
+ true
+ /environment/volcanoes/katla/main-activity
+
+ dialog-apply
+ main
+
+
+
+
+
+ 0
+ 3
+
+
+
+
+
+
+
+
+
+
+
+
+ 12
+
+
+
+
+
+ 20
+
+
+
+ table
+
+
+
+
+
+
+
+
\ No newline at end of file