ToM666 1 Posted September 14, 2013 Hi guys I tend to use this ahoy world script on my maps and was wondering what I would need to change to make it work ideally just for the jets. It seems to me I should just need to change someting here? if (_veh isKindOf "ParachuteBase" || !alive _veh) exitWith {}; if !(_veh isKindOf "Helicopter") exitWith { _veh vehicleChat "This pad is for chopper repairs only, soldier!"; }; The entire .sqf is shown below: | AHOY WORLD | ARMA 3 ALPHA | STRATIS DOMI VER 2.7 | Creating working missions of this complexity from scratch is difficult and time consuming, please credit http://www.ahoyworld.co.uk for creating and distibuting this mission when hosting! This version of Domination was lovingly crafted by Jack Williams (Rarek) for Ahoy World! */ private ["_damage","_percentage","_veh","_vehType","_fuelLevel"]; _veh = _this select 0; _vehType = getText(configFile>>"CfgVehicles">>typeOf _veh>>"DisplayName"); if (_veh isKindOf "ParachuteBase" || !alive _veh) exitWith {}; if !(_veh isKindOf "Helicopter") exitWith { _veh vehicleChat "This pad is for chopper repairs only, soldier!"; }; _fuelLevel = fuel _veh; _damage = getDammage _veh; _veh setFuel 0; _ghosthawkAmmo = 0; _ghosthawkFlares = 0; _veh setVehicleAmmo 1; _veh vehicleChat format ["Servicing %1... Please stand by...", _vehType]; _magazines = getArray(configFile >> "CfgVehicles" >> _vehType >> "magazines"); if (count _magazines > 0) then { _removed = []; { if (!(_x in _removed)) then { _veh removeMagazines _x; _removed = _removed + [_x]; }; } forEach _magazines; { _veh vehicleChat format ["Reloading %1", _x]; sleep 0.1; _veh addMagazine _x; } forEach _magazines; }; _count = count (configFile >> "CfgVehicles" >> _vehType >> "Turrets"); if (_count > 0) then { for "_i" from 0 to (_count - 1) do { scopeName "xx_reload2_xx"; _config = (configFile >> "CfgVehicles" >> _vehType >> "Turrets") select _i; _magazines = getArray(_config >> "magazines"); _removed = []; { if (!(_x in _removed)) then { _veh removeMagazines _x; _removed = _removed + [_x]; }; } forEach _magazines; { _veh vehicleChat format ["Reloading %1", _x]; sleep 0.1; _veh addMagazine _x; sleep 0.1; } forEach _magazines; _count_other = count (_config >> "Turrets"); if (_count_other > 0) then { for "_i" from 0 to (_count_other - 1) do { _config2 = (_config >> "Turrets") select _i; _magazines = getArray(_config2 >> "magazines"); _removed = []; { if (!(_x in _removed)) then { _veh removeMagazines _x; _removed = _removed + [_x]; }; } forEach _magazines; { _veh vehicleChat format ["Reloading %1", _x]; sleep 0.1; _veh addMagazine _x; sleep 0.1; } forEach _magazines; }; }; }; }; _veh setVehicleAmmo 1; // Reload turrets / drivers magazine _veh vehicleChat format ["Repairing and refuelling %1. Stand by...", _vehType]; while {_damage > 0} do { sleep 0.2; _percentage = 100 - (_damage * 100); _veh vehicleChat format ["Repairing (%1%)...", floor _percentage]; if ((_damage - 0.01) <= 0) then { _veh setDamage 0; _damage = 0; } else { _veh setDamage (_damage - 0.01); _damage = _damage - 0.01; }; }; _veh vehicleChat "Repaired (100%)."; while {_fuelLevel < 1} do { sleep 0.2; _percentage = (_fuelLevel * 100); _veh vehicleChat format["Refuelling (%1%)...", floor _percentage]; if ((_fuelLevel + 0.01) >= 1) then { _veh setFuel 1; _fuelLevel = 1; } else { _fuelLevel = _fuelLevel + 0.01; }; }; _veh vehicleChat "Refuelled (100%)."; sleep 2; _veh vehicleChat format ["%1 successfully repaired and refuelled.", _vehType]; Share this post Link to post Share on other sites
silens 0 Posted September 17, 2013 Yes you are correct, !(_veh isKindOf "Helicopter"), if the vehicle is not a type of helicopter then the script exits or ends with the message. Change the type like so: if !(_veh isKindOf "Plane") exitWith { _veh vehicleChat "This pad is for plane repairs only, soldier!"; }; Share this post Link to post Share on other sites
ToM666 1 Posted September 17, 2013 Yes you are correct, !(_veh isKindOf "Helicopter"), if the vehicle is not a type of helicopter then the script exits or ends with the message.Change the type like so: if !(_veh isKindOf "Plane") exitWith { _veh vehicleChat "This pad is for plane repairs only, soldier!"; }; Nice one mate, I've also found that using the word "air" instead of helicopter works too :) Share this post Link to post Share on other sites