I modified heli_dust by Vektorboson, now you can choose maximum 2 different colours on one map. In the example I change NAM dust into GRASS dust.
I added the bolean othercolor = true/false to end the script when you enter a new area (other texture)
How to change the color dust.
You need a trigger that covers the area with the different groundtexture. . If you want to cover other pieces of ground that's on the shore, don't worry your trigger may cover the sea, the script will still change the dust in waterspashes when you fly oversea.
Example : place a helicopter and name it helo1
Put this in your trigger
ACTIVATION : WEST, Repeatedly
Condition : Heli1 in thislist
On activation : othercolor = true; [heli1,"NAM"] exec "heli_dust+.sqs"
On deactivation : othercolor = true; [heli1,"GRASS"] exec "heli_dust+.sqs"
Here's the modified heli_dust script
heli_dust+.sqs
; Heli Dust+ script by Vektorboson; modified by Blanco
; see _sensor and _calcH for above sea level calculation!
; execute just
; [name of the chopper, colour of dust] exec "heli_dust+.sqs"
;Valid colours are : "GRASS","SAND","DUST","DESERT","NAM" and "SNOW"
_chopper = _this select 0
_dust = _this select 1
~1
othercolor = false
?_dust == "GRASS": goto "1"
?_dust == "SAND" :goto "2"
?_dust == "DUST" :goto "3"
?_dust == "DESERT" :goto "4"
?_dust == "NAM" : goto "5"
?_dust == "SNOW" : goto "6"
#1
HDCOLOR = [[0.35,0.35,0.3,0], [0.2, 0.2, 0.1, 0.5],[0.2, 0.27, 0.15, 0]]
goto "next"
#2
HDCOLOR = [[0.35,0.35,0.3,0],[0.35,0.35,0.3,0],[0.6, 0.57, 0.5, 0.5],[0.5, 0.47, 0.4, 0]]
goto "next"
#3
HDCOLOR = [[0.4,0.4,0.4,0],[0.6,0.6,0.6,0],[0.4,0.4,0.4,0.7], [0.65, 0.6, 0.5, 0]]
goto "next"
#4
HDCOLOR = [[0.4,0.4,0.4,0],[0.6,0.6,0.6,0],[0.7,0.7,0.65,1], [0.65, 0.6, 0.5, 0]]
goto "next"
#5
HDCOLOR = [[ 0.4,0.3, 0.2,0.2], [ 0.4,0.3, 0.2,0.25], [0.4,0.3, 0.2, 0.3], [ 0.4, 0.3, 0.2, 0.1]]
goto "next"
#6
HDCOLOR = [[0.95,0.95,0.95,0.2], [0.95,0.95, 0.95,0.4], [0.95 ,0.95,0.95,0.4], [1,1,1,0.1]]
goto "next"
#next
HDCOLORWATER = [[0.8,0.8,0.9,0],[0.9,0.9,1,0.7],[0.8,0.8,0.9,0],[0.8,0.8,0.9,0]]
_null = "scalar bool array string 0xfcffffef"
private ["_sensor"];
_sensor = "EmptyDetector" createVehicle [0,0,0]
_calcH = {private["_result"]; _sensor setpos [getpos _chopper select 0, getpos _chopper select 1, 0]; _result = getpos _sensor select 2; _result};
?format["%1",HDSIN ] == _null: HDSIN = call {private["_i","_result"]; _result = []; _i = 0; while "_i < 50" do {_result = _result + [sin (7.2*_i)*15]; _i = _i+1;}; _result}
?format["%1",HDCOS ] == _null: HDCOS = call {private["_i","_result"]; _result = []; _i = 0; while "_i < 50" do {_result = _result + [cos (7.2*_i)*15]; _i = _i + 1}; _result}
; these are color prefabs! You may adjust or add some new if you like!
; color for this helictoper
_icolor = HDCOLOR
_repeat = true
_lifetime = 2
_shape = "cl_basic"
_color = _icolor
; here comes all the visual part!
#repeat
?(getpos _chopper select 2) < 30 && speed _chopper < 120 && isEngineOn _chopper : goto "loop"
?othercolor : goto "exit"
~0.1
goto "repeat"
#loop
_pos = getpos _chopper
_x = _pos select 0
_y = _pos select 1
_i = 0
#l1
?othercolor : goto "exit"
_vel = [HDSIN select _i, HDCOS select _i, 0]
_size1 = random 2
_size2 = random 3 + 3
_size = [_size1, _size2]
drop [_shape, "", "Billboard", _lifetime, _lifetime, [_x, _y, 0], _vel, 0, 0.2, 0.157, 0.001, _size, _color, [0], 0.1, 0.2, "", "", ""]
_i = _i + 1
?_i < 50: goto "l1"
~0.01
_color = _icolor
_shape = "cl_basic"
?othercolor : goto "exit"
?abs(_this call _calcH) < 3: _color = HDCOLORWATER; _shape = "cl_water"
?(getpos _chopper select 2) < 30 && speed _chopper < 120 && isEngineOn _chopper: goto "loop"
?_repeat && alive _chopper : goto "repeat"
#exit
deletevehicle _sensor
exit