Jump to content

Purzel

Member
  • Content Count

    262
  • Joined

  • Last visited

  • Medals

Everything posted by Purzel

  1. Hell yeah! It works fine... buuuuut: I´ve got another picture (Pictures\codemail.paa) called from a second object file, but if I open that second file the first picture (code.paa) from first file will be shown. So I decided to change the variables "document" and "_pic" to "document1" and "_pic1", but even after a reload of the mission, the first picture will be shown below... <<< code.ppa versus codemail.paa >>> Do I have to change another variable? Do I need to change the first lines "RscAttributeDiaryRecord_texture" to another name? Below is the code from the second file init: this setVariable ["RscAttributeDiaryRecord_texture","pictures\codemail.paa", true]; data = [this,"RscAttributeDiaryRecord",["eMail to comrade commandant","GeniearK1eimiMneieesKadwrdnBseLfl2izaefamSeenudtnscrinsomatwrdeidLuK4nrnreSenirnrhlSehetomneisApKgnlheaib<br /><execute expression='call TAG_fnc_documentViewer'>eMail öffnen</execute>","pictures\codemail.paa"]] call bis_fnc_setServerVariable; TAG_fnc_documentViewer = { disableSerialization; _display = [] call BIS_fnc_displayMission; if ( isNil { _display getVariable "document1" } ) then { _pic1 = _display ctrlCreate [ "RscPictureKeepAspect", 1000 ]; _pic1 ctrlSetText "pictures\codemail.paa"; _pic1 ctrlSetPosition[ 0.5 - ( 256 * pixelW ), 0.5 - ( 256 * pixelH ), 512 * pixelW, 512 * pixelH ]; _pic1 ctrlCommit 0; _display setVariable[ "document1", _pic1 ]; addMissionEventHandler [ "EachFrame", { if !( visibleMap ) then { ctrlDelete (( [] call BIS_fnc_displayMission ) getVariable "document1" ); ( [] call BIS_fnc_displayMission ) setVariable [ "document1", nil ]; removeMissionEventHandler[ "EachFrame", _thisEventHandler ]; }; }]; }; }; Thanks for your help!
  2. You can define each unit you want as a group, no matter if it's a single unit or a group.
  3. @Grumpy Old Man: Thanks a lot, it´s a good idea for dialogs... @KK: Is it somehow possible to use the "map" as carrier for the code-picture? @Larrow: Thanks for that hint with CTRL+P, but i´ll first try the other part...
  4. OK, I´ve tried around with that stuff, watched a tutorial about GUI-Editor. Learned how to build an background and a "close"-Button. I´ve build the "codedialog.hpp" and intergrated it (and the "defines.hpp") into the description.ext before the classes. But I need a defines.hpp, so I copied one from another mission, in hope that this could work. Of course it did not... After all I desperate on the "defines.hpp", because that part is not treated in the tutorial and I don´t have any clue, how to build a "defines.hpp" by myself. Maybe someone could help me with that. I have a picture 512 x 512 pixels called "code.paa" in the missions pictures-Folder. Maybe someone could build that above stuff (Picture in 512x512 size with a simple "Close"-Button) for me. I´v tried around, but there no light at the end of the tunnel. I´m no native english-speaker so sometimes its hard to understand some tutorials.
  5. I´ve tried around and here´s the solution, solved without initPlayer/Server-Stuff: (and it´s running finally on a dedicated server!) Yai! :D Thank you Larrow for your valuable hints! My problem is to understand the english scripting stuff correctly, it´s not the the scripting itself... but some stuff is still unknown for me and I don´t know what to search, if I have a special scripting problem... if (isServer) then { _heliCrew = [] + crew (vehicle pablo); _playerCrew = [] + crew (vehicle pablo) - [pablo]; _evacheli = (vehicle pablo); // nul = [] execVM "scripts\blackout.sqf"; [[_evacheli, "mastercaution"], "Say3d", _playerCrew, false] call BIS_fnc_MP; {_x allowDamage false} forEach _heliCrew; [_evacheli,0.03] remoteExec ['setfuel',_evacheli]; [_evacheli,false] remoteExec ['allowdamage',_evacheli]; sleep 4; [[_evacheli, "mastercaution"], "Say3d", _playerCrew, false] call BIS_fnc_MP; explo = "R_60mm_HE" createVehicle (getPos _evacheli); explo attachto [_evacheli, [0,-1.5,0]]; sleep 9; smoke1 = "SmokeShell" createVehicle (position _evacheli); smoke1 attachto [_evacheli, [0,-7.5,0.9]]; [_evacheli,true] remoteExec ['allowdamage',_evacheli]; [_evacheli,["HitVRotor", 0.6]] remoteExec ['setHitPointDamage',_evacheli]; [_evacheli,false] remoteExec ['allowdamage',_evacheli]; smoke2 = "test_EmptyObjectForSmoke" createVehicle position _evacheli; smoke2 attachTo [_evacheli,[0,-2,1]]; sleep 5; feuer = "HelicopterExploSmall" createVehicle position _evacheli; feuer attachTo [_evacheli,[0.5,-1.5,-1.5]]; [[_evacheli, "enginefire"], "Say3d", _playerCrew, false] call BIS_fnc_MP; sleep 3.5; sleep 0.2; [_evacheli,0] remoteExec ['setfuel',_evacheli]; [[_evacheli, "mastercaution"], "Say3d", _playerCrew, false] call BIS_fnc_MP; sleep 3.5; [[_evacheli, "mastercaution"], "Say3d", _playerCrew, false] call BIS_fnc_MP; waituntil {sleep 0.1; (getPosATL _evacheli select 2) <= 2}; [[[_evacheli],"scripts\blackout.sqf"],"BIS_fnc_execVM",west,false] call BIS_fnc_MP; sleep 2; _position = [getPos _evacHeli, 5 + random 15, random 360] call BIS_fnc_relPos; //get a random position in a radius from 5m to 20m around the crashed helicopter [pablo] call ACE_captives_fnc_vehicleCaptiveMoveOut; // kick pablo of the chopper pablo setPos _position; // teleport pablo to a save position (not in walls or rocks, etc.) _evacheli setdamage 0.8; _markerabsturz = createMarker ["crashsite", position (vehicle Pablo)]; _markerabsturz setMarkerShape "ICON"; _markerabsturz setMarkerColor "colorBLUFOR"; _markerabsturz setMarkerText " Crashsite"; _markerabsturz setMarkerType "hd_unknown"; _markerabsturz setMarkerPos (getpos (vehicle Pablo)); _markerabsturz setMarkerAlpha 1; _markerabsturz1 = createMarker ["crashsite1", position (vehicle Pablo)]; _markerabsturz1 setMarkerShape "ELLIPSE"; _markerabsturz1 setMarkerSize [800, 800]; _markerabsturz1 setMarkerColor "colorBLUFOR"; _markerabsturz1 setMarkerBrush "SOLID"; _markerabsturz1 setMarkerPos (getpos (vehicle Pablo)); _markerabsturz1 setMarkerAlpha 0.3; _evacheli allowdamage false; sleep 20; deleteVehicle feuer; {_x allowDamage true} forEach _heliCrew; sleep 10; [playSound ["evacdown", true]] call BIS_fnc_MP; ["task4", "created"] call FHQ_fnc_ttSetTaskState; [west,["task4", "Beschützen Sie Pablo Escobar und schlagen Sie sich mit ihm zum Polizei-Revier in Tanouka durch.", "Schlagen Sie sich zum Polizeirevier durch.", ""]] call FHQ_fnc_ttAddTasks; // Das mit dem explodierenden Heli regeln wir anders while {{_x distance _evacheli < 50} count playableUnits > 0} do {sleep 5}; _evacheli allowdamage true; _evacheli setdamage 1; [pablo,flaggenmast,RESISTANCE,90,600,800,800] execVM "scripts\feindspawn.sqf"; }; Here is the blackout.sqf: private ["_evacheli"]; _evacHeli = _this select 0; if (player in _evacHeli) then { cutText ["", "BLACK OUT", 1]; sleep 2; _position = [getPos _evacHeli, 5 + random 15, random 360] call BIS_fnc_relPos; //the following 5 lines kicks the players outside the chopper and lay them on the ground. player action ["Eject", _evacHeli]; sleep 0.5; player setPos _position; player switchMove "AidlPpneMstpSnonWnonDnon_AI"; _blur = ppEffectCreate ["DynamicBlur", 474]; _blur ppEffectEnable true; cutText ["", "BLACK IN", 15]; _blur ppEffectAdjust [0]; _blur ppEffectCommit 0; cutText ["", "BLACK OUT", 2]; waitUntil {ppEffectCommitted _blur}; cutText ["", "BLACK", 10]; cutText ["", "BLACK IN", 7]; _blur ppEffectAdjust [15]; _blur ppEffectCommit 0; _blur ppEffectAdjust [0]; _blur ppEffectCommit 15; if ([player] call ace_medical_fnc_isMedic) then { // put some injuries to all players that are no medics sleep 0.2 } else { private ["_bodyParts","_numberOfPartsHit","_severity","_verletzungsGrad"]; _bodyParts = ["head","body","hand_l","hand_r","leg_l","leg_r"]; _numberOfPartsHit = 1 + (floor random 2.9); _severity = [0.3,0.3,0.3,0.8]; _unit = [player]; for "_i" from 1 to _numberOfPartsHit do { _bodyPartHit = _bodyParts call BIS_fnc_selectRandom; _bodyParts = _bodyParts - [_bodyPartHit]; _verletzungsGrad = _severity call BIS_fnc_selectRandom; [player, _verletzungsGrad, _bodyPartHit, "bullet"] call ace_medical_fnc_addDamageToUnit; sleep 0.2; }; }; waitUntil {ppEffectCommitted _blur}; _blur ppEffectEnable false; ppEffectDestroy _blur; }; the "feindspawn.sqf" spawns enemies in the line between object "flaggenmast" and "pablo", so no matter where the heli crashed, there will be always enemies walking towards the team with escorts pablo on the escape-route from crashsite to the teams destination: [pablo,flaggenmast,RESISTANCE,90,600,800,800] execVM "scripts\feindspawn.sqf"; It´s written "open", so I just have to change some variables in the line above and not the script itself.
  6. Hi Folks! how do I get this working on a dedicated server... Locality is not my friend... and I´m not really good in scripting... What I want to do: There's a chopper which is stalling, everybody inside is set to "allowdamage false". Some warning sounds should be heard and only the players inside should get a short "blackout"... When the chopper is "down" (and while the blackout!) an area-marker is set on position of the crashsite and an eos-Script is spawning depending on the marker size (300m). then another script deletes a radius about 200m around the helicopter, so that no enemies are to close to the crashsite and a ring of 100m withe enemies remains. That all should happen, while the players of the chopper are unconscience ("blackout"), SOLUTION: HERE my problem is, that there are commands which have to played on my dedicated server (like markers, etc.) and some played only on clients machines (sounds, blackout, etc.) Here are my commandlines with no sequence/order: explo = "R_60mm_HE" createVehicle (getPos _evacheli); //explosion explo attachto [_evacheli, [0,-1.5,0]]; [{_evacheli say3D "mastercaution";},"BIS_fnc_spawn",west,true] call BIS_fnc_MP; //sound to be played waituntil {(getPosATL _evacheli select 2) <= 0.5}; sleep 2; _markerabsturz = createMarker ["crashsite", position (vehicle pablo)]; _markerabsturz setMarkerShape "ICON"; _markerabsturz setMarkerColor "colorBLUFOR"; _markerabsturz setMarkerText " Crashsite"; _markerabsturz setMarkerType "hd_unknown"; _markerabsturz setMarkerPos (getpos (vehicle pablo)); _markerabsturz setMarkerAlpha 1; _markerabsturz1 = createMarker ["_markerabsturz1", position (vehicle pablo)]; _markerabsturz1 setMarkerBrush "SOLID"; _markerabsturz1 setMarkerShape "ELLIPSE"; _markerabsturz1 setMarkerSize [800, 800]; _markerabsturz1 setMarkerColor "colorBLUFOR"; _markerabsturz1 setMarkerPos (getpos (vehicle pablo)); _markerabsturz1 setMarkerAlpha 0; nul = [] execVM "eos\OpenMe.sqf"; //spawns the enemies {deleteVehicle _x} forEach (nearestObjects [(getMarkerPos "crashsite"),["Men"], 200]); //deletes enemies to close to the crashsite [{ // blackout in which all the above should happen [] spawn { cutText ["", "BLACK OUT", 2]; private ["_blur"]; _blur = ppEffectCreate ["DynamicBlur", 474]; _blur ppEffectEnable true; cutText ["", "BLACK OUT", 12]; _blur ppEffectAdjust [0]; _blur ppEffectCommit 0; titleText ["Autschn!", "BLACK FADED", 10]; waitUntil {ppEffectCommitted _blur}; cutText ["", "BLACK IN", 7]; _blur ppEffectAdjust [15]; _blur ppEffectCommit 0; _blur ppEffectAdjust [0]; _blur ppEffectCommit 10; waitUntil {ppEffectCommitted _blur}; _blur ppEffectEnable false; ppEffectDestroy _blur; }; } forEach units (vehicle Pablo)] call BIS_fnc_execVM; Maybe someone could give me some hints! Thanks! Purzel
  7. Swifty does not load one of our repositories correctly: On every start it re-loads a part of our mods, but everytime with different filesizes. Some of our clan have the problem, some not. We´ve got two servers with an identic modset, even the copying of files from the correct loaded server#1 to server#2 repository data-folder (on harddisc) will not fix this problem. I repeat: The modsets are identical, but the second one creates the reloading situation everytime we start swifty. Suggestions anybody?
  8. I´m not shure what to do: (The sound "mastercaution" should only be played on clients.) this is the Wiki entry: "123" remoteExec ["hint", [0, -2] select isMultiplayer]; How do I get this into the above? _evacheli say3d "mastercaution"; "mastercaution" remoteExec ["evacheli say3D", [0, -2] select isMultiplayer]; ??? I really don´t get this locality... Thanks for help! Purzel
  9. [EDIT: ] The above does not work: Where do I save the initServer.sqf and the initPlayerLocal.sqf? I have to put it in the missionfolder together with description.ext and init.sqf, right? I called it from a trigger with: if ( isServer ) then { _helo call TAG_fnc_heloExplosion;}; but what is this "TAG_fnc_heloEffects"-thing...? I didn´t found any clues to that, is it just a name for a condition? And when executed, nothing happens, but there´s no errormessage too, so I don´t have any clue, whats going on (and if it´s going on at all...) Here´s the initPlayerLocal.sqf, I wrote it for my needs: TAG_fnc_heloEffects = { params[ "_start" ]; if ( _start ) then { pablo allowdamage false; _evacheli say3D "mastercaution"; sleep 5; _evacheli say3D "enginefire"; }else{ //stop effects pablo allowdamage true; }; }; Where do I have to insert the blurry-part? (after enginefire?) Do I just need to copy the below code after the line below enginfire? [] spawn { cutText ["", "BLACK OUT", 2]; private ["_blur"]; _blur = ppEffectCreate ["DynamicBlur", 474]; _blur ppEffectEnable true; cutText ["", "BLACK OUT", 12]; _blur ppEffectAdjust [0]; _blur ppEffectCommit 0; titleText ["Autschn!", "BLACK FADED", 10]; waitUntil {ppEffectCommitted _blur}; cutText ["", "BLACK IN", 7]; _blur ppEffectAdjust [15]; _blur ppEffectCommit 0; _blur ppEffectAdjust [0]; _blur ppEffectCommit 10; waitUntil {ppEffectCommitted _blur}; _blur ppEffectEnable false; ppEffectDestroy _blur; }; But maybe here´s another problem hidden in the initServer.sqf because of my poor scripting skills...: (If someone please could have a short look-over) TAG_fnc_heloExplosion = { params[ "_evacheli" ]; _crew = ( crew _evacheli ) select { isPlayer _x }; explo = "R_60mm_HE" createVehicle (getPos _evacheli); explo attachto [_evacheli, [0,-1.5,0]]; sleep 9; smoke1 = "SmokeShell" createVehicle (position _evacheli); smoke1 attachto [_evacheli, [0,-7.5,0.9]]; _evacheli setHitPointDamage ["HitVRotor", 0.7]; smoke2 = "test_EmptyObjectForSmoke" createVehicle position _evacheli; smoke2 attachTo [_evacheli,[0,-2,-0.8]]; sleep 5; feuer = "HelicopterExploSmall" createVehicle position _evacheli; feuer attachTo [_evacheli,[0.5,-1.5,-1.5]]; [ true ] remoteExec [ "TAG_fnc_heloEffects", _crew ]; waituntil {(getPosATL _evacheli select 2) <= 0.5}; _markerabsturz = createMarker ["crashsite", position (vehicle pablo)]; _markerabsturz setMarkerShape "ICON"; _markerabsturz setMarkerColor "colorBLUFOR"; _markerabsturz setMarkerText " Crashsite"; _markerabsturz setMarkerType "hd_unknown"; _markerabsturz setMarkerPos (getpos (vehicle pablo)); _markerabsturz setMarkerAlpha 1; _markerabsturz1 = createMarker ["_markerabsturz1", position (vehicle pablo)]; _markerabsturz1 setMarkerBrush "SOLID"; _markerabsturz1 setMarkerShape "ELLIPSE"; _markerabsturz1 setMarkerSize [800, 800]; _markerabsturz1 setMarkerColor "colorBLUFOR"; _markerabsturz1 setMarkerPos (getpos (vehicle pablo)); _markerabsturz1 setMarkerAlpha 0.5; sleep 2; nul = [] execVM "eos\OpenMe.sqf"; sleep 2; {deleteVehicle _x} forEach (nearestObjects [(getMarkerPos "crashsite"),["Men"], 50]); [ false ] remoteExec [ "TAG_fnc_heloEffects", _crew ]; };
  10. Hard to understand... :( If I want the soundfiles to be played on clientside... this (from your example) null = [_pos, _player] remoteExec ["fnc_somefunction", 2,false]; will become this: null = [_evacheli say3D "mastercaution";] remoteExec ["call BIS_fnc_MP", -2, false]; is that correct? Especially with all the ; and ( [ { } ] ) It´s really complicated for me... But how do I get the "blackout" from the first post running, because its a sequence of some more commands...: [{ // blackout in which all the above should happen [] spawn { cutText ["", "BLACK OUT", 2]; private ["_blur"]; _blur = ppEffectCreate ["DynamicBlur", 474]; _blur ppEffectEnable true; cutText ["", "BLACK OUT", 12]; _blur ppEffectAdjust [0]; _blur ppEffectCommit 0; titleText ["Autschn!", "BLACK FADED", 10]; waitUntil {ppEffectCommitted _blur}; cutText ["", "BLACK IN", 7]; _blur ppEffectAdjust [15]; _blur ppEffectCommit 0; _blur ppEffectAdjust [0]; _blur ppEffectCommit 10; waitUntil {ppEffectCommitted _blur}; _blur ppEffectEnable false; ppEffectDestroy _blur; }; } forEach units (vehicle pablo)] call BIS_fnc_execVM; How do I integrate some stuff without breaking up the (local / clientside) sequence? While its black to the clients (only in the chopper!) the enemies should be created... Is it possible to break the single commandlines and insert the other stuff? Like this: _blur ppEffectAdjust [15]; // blurry effect _blur ppEffectCommit 0; _blur ppEffectAdjust [0]; -----> PUT IN SOME OTHER STUFF HERE create enemies,etc. // is this interrupting the clientside effect? because spawning the enemies happens on dedicated server... _blur ppEffectCommit 10; waitUntil {ppEffectCommitted _blur}; // wait until blurryness-effect gone. Greetz Purzel
  11. Hints anyone? My problem is, to mix dedicated server stuff with clients stuff... Everybody inside the helicopter should hear the warning-sounds and have a blackout and while this happens, the server should create markers in which enemies spawns around the chopper... Please help me Thanks Purzel
  12. The 60 mm HE is attached to the turbine of the chopper, it looks like a jetflame coming out, followed by an explosion. looks pretty nice... but its just eye-candy... And yes its in the middle of the mission. I just need the crashsite-marker on every machine, because the stalled team has to be rescued by the other team. All other marker are only for spawning enemies in them and have not to be seen.
  13. Hi there, Is it possible to change the name of a unit into another name? I need this for a mission, where this "special" unit joins my team and i need to protect it. (I don´t mean the group-id like "Alpha" or the units description...!) See picture below: Thx Purzel
  14. I need a short (about 5 sec.) blackscreen followed by a blurriness (10 sec.) for all players in a helicopter after a crash. Players not in chopper shouldnt have this effect. So now I need the code for getting a blackscreen for 5 seconds, in which I can execute another code. I only get it faded in and out, but not black for 5 seconds. I tried around with titlecut, but I cant get it. [] spawn { addCamShake [2, 5, 20]; titleCut ["", "BLACK IN", 2]; // HERE I NEED the 5 seconds blackscreen and after it, // I will insert some code for spawning enemies arround the crashsite, smoke, etc. before the blackscreen is faded out again. titleCut ["", "BLACK OUT", 5]; private ["_blur"]; _blur = ppEffectCreate ["DynamicBlur", 474]; _blur ppEffectEnable true; _blur ppEffectAdjust [0]; _blur ppEffectCommit 0; waitUntil {ppEffectCommitted _blur}; _blur ppEffectAdjust [10]; _blur ppEffectCommit 0; _blur ppEffectAdjust [0]; _blur ppEffectCommit 5; waitUntil {ppEffectCommitted _blur}; _blur ppEffectEnable false; ppEffectDestroy _blur; }; I hope anyone can help me with that stuff... Thanks a lot Purzel
  15. Ok... next problem: I have a crashsite and a destination (where to go with hostage). I want to use a spawn script which needs a marker in the middle of both spots How do I get the half distance between both start (crashsite) and destination (safehouse) and how do I get a marker on that spot...? Goal is to spawn a bunch of enemies at half the walking track, from where ever the crashsite is to the destination...
  16. Ok folks, this is a bigger one: I have a Team of human players which have the option to choose from various helicopters in our base. Human players: up to 60, divided into groups of each ten players (alpha1 - 10, bravo1 - 10, charlie1 - 10, etc.) One AI-Unit: Pablo (which is the bad guy, we have to arrest) Helicopters: huey1, huey2, huey3, huey4. Mission goal is to fly with helicopters to arrest Pablo in a town. If Pablo is arrested, our task is, to bring him back to base by helicopter. But now it becomes tricky. No one knows, who is the leader of the human MP-team and which of the four helicopters he will choose. Maybe one chopper is shot down, so we need another one from our base. This mission is very randomized by human decisions, so here´s the thing: I need a working MP-script, which checks all choppers, if pablo is in cargo and at least one human player is the driver/pilot. If that condition is met and the helicopter is in a certain range to a marker I will add some code for some nice "Blackhawn down"-action. But I have no clue, how to check the condition (player(s) and pablo) in one of four helicopters and distance from the pablo-transport-heli to marker. and now the important part: Only the helicopter with Pablo has to be detected as the crash-helicopter. I thought about something like this: if player(s) in thisList && (huey with pablo distance crashzone) < 1000 then {huey with pablo setdamage 0.8;}; //pablo and humanplayers allowdamage false until crash, then smoke attachto wreck and small injuries to some human units. Maybe someone could help me with that. Thanks a lot :) Purzel SOLUTION HERE: https://forums.bistudio.com/topic/193905-if-certain-units-are-in-a-helicopter-then-code-solution-inside/#entry3086927
  17. Since I forgot to tell that we´re using ACE, here is the solution: MP-Players and Helicopters are only BLUFOR. Carlos is INDEPENDENT. (Carlos and Helicopters are on the Mission from the beginning (not spawned later) My problem was, to check, if Pablo (our target) is handcuffed AND in any helicopter AND in a certain distance to the target-area... First part: Getting Pablo handcuffed. (via ACE, when player units are closer than 3m, he will stop and surrender. If player units are inattentive and getting away more than 3m from Pablo, he will take his chance and flee...) Trigger1: (server only!) Condition: ({(pablo distance _x) < 3} count playableUnits) > 0 On Activation: if (isServer) then {[pablo, true] call ACE_captives_fnc_setSurrendered}; On Deactivation: if (isServer) then {[pablo, false] call ACE_captives_fnc_setSurrendered}; Second part: Check if Pablo is in any Helicopter Trigger 2: (server only!) Condition: pablo getVariable ["ACE_captives_isHandcuffed", false] && ((vehicle pablo) isKindOf "Air") On Activation: nul = [] execVM "scripts\YourScript.sqf"; Conclusion: I was thinking to complicated and I dont want to use too much triggers, because of the traffic, so I tried to script it. Since only BLUFOR units are able to fly the helicopter to the destination area it does not matter in which helicopter Pablo is. I don´t need to put all helicopters into an array or know all them names or whatever. The point is: - Is Pablo handcuffed? (that can only be done by human BLUFOR-units.) - Is Pablo in a helicopter? (only BLUFOR-units know, where to fly, AI-units have never a task to get there and I just can check if Pablos is in generally in an air-vehicle! (isKindOf "Air") AI-units have no reason to handcuff Pablo (condition 1) and no reason to put him whyever into a helicopter (reason 2) So it these both conditions are met, the trigger fires - and whupp-di-doo... the script will be executed. This is the solution for an area-trigger, but: An area-trigger will check every 0.5 seconds if both conditions are met, which -depending on triggersize- will cost less or more server-power. So the better way would be just to check to distance from Pablo to destination. If I use a non-area trigger I have to put another condition after the both above: pablo getVariable ["ACE_captives_isHandcuffed", false] && {(vehicle pablo) isKindOf "Air"} && {(Pablo distance destination) < 2000} This will just check the destination and not an whole 2000m radius area-trigger (keep your server traffic low!) and because of the lazy-evalution-syntax, the trigger will only check the last arguments, if the arguments before are met. I hope this will help someone else...
  18. The trick is, that the arrest of Pablo will be very easy... the hard part will follow after the heli-crash... ;-) So thats why I need this.... :) I´m over another solution for this, I´ll post a working MP-code, when it´s done... In fact all of you gave me valuable hints! Thanks for that! Grretz Purzel
  19. Since all helis and all players are BLUFOR, I can drop lots of your code... my fault to think so complicated.. I'll give this a try: _heli = (vehicle Pablo); while {_heli distance (getMarkerPos "crashmarker") < 1000} do {sleep 5}; _heli setDamage 0.9; smoke, etc...
  20. Hi folks, is it possible to remove the textures (marked blue in the pic below) and have my own texture instead? I want to get the house a police station instead of a barbers shop... So I´d like to replace the commercials with some own "Police"-textures... Is it possible to replace that without changing something in the .pbo-files ? Thanks a lot! Greetz Purzel
  21. Hello there: What´s wrong with this script: (an AI-unit called "pablo" (and his AI-bodyguard) should spawn as cargo in a flying plane, which should land at Bala-airstrip on Tanoa, where "pablo" should get out and walk to a Jeep (jeep1) and get in it. I get the message "crew not defined"...script stops.) Whats wrong here??? Thanks for your help! if (isServer) then { // -------------- Spawn Helicopter and Crews ---------------------------------------------- _heli1crew = [[getMarkerPos "pablospawn" select 0, getMarkerPos "pablospawn" select 1], MarkerDir "pablospawn", "C_Heli_Light_01-civil_F", West] call Bis_fnc_spawnvehicle; // BIS_fnc_spawnCrew ??? _heli1 = _heli1crew select 0 ; _heli1 setPos [getpos _heli1 select 0, getpos _heli1 select 1, 400]; _heli1 allowdamage false; // (vehicle leader _heli1crew) flyInHeight 200; //_heli1crew setbehavior "CARELESS"; sleep 2; pablo assignAsCargo _heli1; bodyguard assignAsCargo _heli1; pablo MoveInCargo _heli1; bodyguard MoveInCargo _heli1; // -------------- Create waypoints for heli1crew ---------------------------------------------- _wp1a = _heli1crew addWaypoint [getMarkerPos "pablospawn", 0]; _wp1a setWaypointType "MOVE"; _wp1a setWaypointStatements ["true", ""]; _wp1a setWaypointBehaviour "SAFE"; //_wp1a setWaypointSpeed "LIMITED"; _wp1a setWaypointCombatMode "WHITE"; sleep 2; _wp2a = _heli1crew addWaypoint [getMarkerPos "pablokommt3", 0]; _wp2a setWaypointType "MOVE"; _wp2a setWaypointStatements ["true", ""]; _wp2a setWaypointBehaviour "SAFE"; //_wp2a setWaypointSpeed "LIMITED"; _wp2a setWaypointCombatMode "WHITE"; sleep 3; _wp3a = _heli1crew addWaypoint [getMarkerPos "pablokommt4", 0]; _wp3a setWaypointType "TR UNLOAD"; _wp3a setWaypointStatements ["true", ""]; _wp3a setWaypointBehaviour "SAFE"; //_wp3a setWaypointSpeed "LIMITED"; _wp3a setWaypointCombatMode "WHITE"; //_heli1crew setbehavior "AWARE"; while {pablo in _heli1} do {sleep 5}; pablo assignAsCargo jeep1; bodyguard assignAsCargo jeep1; [pablo] orderGetIn true; [bodyguard] orderGetIn true; };
  22. So... here we go: I hope you can find the problem. I´ve tried _plane1 = _aircraftcrew select 1 (0 and 2 too!) -> nothing works... RPT-Error-message: Error in expression <aircraftcrew select 1 ;_plane1 setPos [getpos _plane1 select 0, getpos _plane1 > Error position: <getpos _plane1 select 0, getpos _plane1 > Error getpos: Typ Array, erwartet Objekt,Location << ---- Translated: Type Array, awaiting object,location File H:\Documents\Arma 3 - Other Profiles\Purzel\mpmissions\TMP-Schneefall.Tanoa\scripts\pabloscript2.sqf, line 10 Here´s the pabloscript2.sqf: // Pablo kommt per Cessna hint "Pablo Escobar kommt per Flugzeug!"; if (isServer) then { // -------------- Fahrzeuge und Crews spawnen ---------------------------------------------- _aircraftcrew = createGroup resistance; _aircraftcrew = [[getMarkerPos "pablospawn" select 0, getMarkerPos "pablospawn" select 1], MarkerDir "pablospawn", "C_Plane_Civil_01_F", West] call Bis_fnc_spawnvehicle; // BIS_fnc_spawnCrew ??? _plane1 = _aircraftcrew select 1 ; _plane1 setPos [getpos _plane1 select 0, getpos _plane1 select 1, 400]; _plane1 allowdamage false; // (vehicle leader _aircraftcrew) flyInHeight 200; //_aircraftcrew setbehavior "CARELESS"; sleep 1; pablo assignAsCargo _plane1; bodyguard assignAsCargo _plane1; pablo MoveInCargo _plane1; bodyguard MoveInCargo _plane1; // sleep 10; // -------------- OPZ-Funkspruch kommt rein. ------------------------------------------------------ // [] execVM "scripts\funkspruch2.sqf"; // -------------- Wegpunkte für Flugzeug erstellen ------------------------------------------------------ _wp1a = _aircraftcrew addWaypoint [getMarkerPos "pablospawn", 0]; _wp1a setWaypointType "MOVE"; _wp1a setWaypointStatements ["true", ""]; _wp1a setWaypointBehaviour "SAFE"; //_wp1a setWaypointSpeed "LIMITED"; _wp1a setWaypointCombatMode "WHITE"; sleep 2; _wp2a = _aircraftcrew addWaypoint [getMarkerPos "pablokommt3", 0]; _wp2a setWaypointType "MOVE"; _wp2a setWaypointStatements ["true", ""]; _wp2a setWaypointBehaviour "SAFE"; //_wp2a setWaypointSpeed "LIMITED"; _wp2a setWaypointCombatMode "WHITE"; sleep 3; _wp3a = _aircraftcrew addWaypoint [getMarkerPos "pablokommt4", 0]; _wp3a setWaypointType "TR UNLOAD"; _wp3a setWaypointStatements ["true", ""]; _wp3a setWaypointBehaviour "SAFE"; //_wp3a setWaypointSpeed "LIMITED"; _wp3a setWaypointCombatMode "WHITE"; //_aircraftcrew setbehavior "AWARE"; while {pablo in _plane1} do {sleep 5}; pablo assignAsCargo jeep1; bodyguard assignAsCargo jeep1; [pablo] orderGetIn true; [bodyguard] orderGetIn true; };
×