Search the Community
Showing results for tags 'hideObject'.
Found 8 results
-
[Solved] Problems with hideObjectGlobal for layers
Jamio posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hi there, I'm attempting to unhide a layer that I have previously hidden using the following code in the mission init.sqf, with "layer_checkpointwest" being my layer: { _x hideObjectGlobal true; } forEach (getMissionLayerEntities "layer_checkpointwest" select 0); I want to unhide everything in this layer at some point later on in the mission. Originally I had it set up in an addAction for a Zeus player to trigger: zeus1 addAction ["4. Unhide Checkpoint Ambush Scene", {{_x hideObjectGlobal false;} forEach (getMissionLayerEntities "layer_checkpointwest" select 0);}, nil, 1.5, false, true, "", "true", 3]; For SP and locally hosted MP this works fine, however on a dedicated server nothing seems to happen. I am thinking it's something to do with the way hideObjectGlobal needs to be called on the server - but even using a trigger to remoteExec a script > "[] remoteExec ["unhidecheckpoint.sqf", 2, false];" with essentially the opposite of the init.sqf code doesn't seem to work either. I've been reading so much on this and I don't feel like I'm fully understanding what I'm missing! Any help or advice with this is much appreciated. -
hideObjectGlobal preventing Ai targeting... (WORKAROUND FOUND!)
LSValmont posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Agent dogs with an attached invisible unit so that other Ai can attack them... The problem is... as soon as I hide their models using hideObjectGlobal the Ai no longer targets them... as the below pic shows when unhidden the Ai shoots at them just fine. This is how I create the hidden agent: vVirtualEnemy = { params ["_unit"]; _ai = createAgent ["I_Survivor_F", [0,0,0], [], 0, "CAN_COLLIDE"]; _ai setFace ""; //hideObjectGlobal _ai; _ai disableAI "ALL"; //{_ai enableAI _x} forEach ["ANIM","TEAMSWITCH","CHECKVISIBLE"]; [_ai, "Acts_AidlPsitMstpSsurWnonDnon01"] remoteExec ["switchMove", 0]; _ai enableStamina false; _ai setUnitPos "MIDDLE"; _ai disablecollisionwith _unit; _unit disablecollisionwith _ai; _ai attachTo [_unit, [0,0,0]]; _unit setVariable ["_attAi", _ai, true]; _unit addEventHandler ["Killed", {deleteVehicle ((_this # 0) getVariable "_attAi")}]; //_ai forceSpeed 2; //_ai setAnimSpeedCoef 3; [_ai] join (group _unit); _ai addRating -100000; // Make sure is renegade! _ai allowdamage false; _ai setSpeaker "NoVoice"; _ai setSkill 0; }; How can I hide the virtual unit's models yet still be targeteable by other enemy ai?- 13 replies
-
- hideobjectglobal
- hideobject
-
(and 2 more)
Tagged with:
-
[Solved] HideObject in MP executed locally
Guest posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hello, I'm trying to remove vegetation in an area for a composition loaded with the debug console. I can only execute the script from my client since I don't have access to the server files. { _x hideObject true } foreach (nearestTerrainObjects [_newObject,["BUSH"],50]); This code works for my client but the rest of the server can still see the vegetation. Also if I reconnect the vegetation would reappear. { waitUntil {!isNull _newObject}; { _x hideObject true } foreach (nearestTerrainObjects [_newObject,["BUSH"],50]); } remoteExec ["spawn", 0, True]; DarleneWhale on /r/armadev wrote me this which should've executed the code on all clients with JIP set to true. Unfortunately, I've hit a bump since the vegetation still doesn't disappear for the players nor me with this code. Does anybody know how I can execute the HideObject command locally so the vegetation disappears for all players on the server including the players that join/reconnect? Any help would be much appreciated.- 3 replies
-
- solved
- multiplayer
-
(and 1 more)
Tagged with:
-
Using Hold Actions on hidden units (i.e hide unit without hideObject)
Leopard20 posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hello everyone. Does anyone know a way to add hold actions to hidden units? Unfortunately, when a unit is hidden using hideObject the action doesn't appear anymore. However, if there was a way to hide the unit without using hideObject it would work. My first idea was to use setObjectTexture, but it doesn't hide the unit completely (the unit's face and arms are still visible) -
Need some help with hideObjectGlobal
Robin Withes posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hello, I've been trying for 6 hours now to get my script working on a life server that allows cops to raid a weed processor. This is what i got so far : https://pastebin.com/VDE5WkMq I have a huge problem with the hideobjectglobal though.. If i use the normal hideObject it only hides the object from the guy who triggers the script and if i put it on hideobjectglobal, nothing happens. How do i fix this? -
Spawning complex structures on demand
ARCHaim posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hi everyone! I've faced a problem, when spawning a structure, consisting of 500+ objects, on demand. When it happens, one or another random object from this structure doesn't show itself physically (for every player, so it seems to be not a client-side problem). I'm wondering if there's a way to prespawn an objects in any virtual way and when they needed - just to enable them or clone into a real ones. The hideObject way isn't appropriate for this, because the hidden objects are still participating in server-side calculations. That's why i've decided to use deleteVehicle after this massive structure done it's job in scenario (it really saves a server FPS). I've tried to set for every such object "_obj enableSimulation false; _obj allowDamage false;" but it seems not to be helpful when this kind of complex structure (consisting of 500+ objects) are on the map in amount of 3 or more. I really appreciate any help, guys. Thanks!- 4 replies
-
- performance
- spawn
-
(and 6 more)
Tagged with:
-
Hello everyone, i tried to hide Objects Global via a headless client without any success, also if i'm already connected. Here are some code snippet: _list = nearestObjects [(call compile SEL(_x, 4)), [_classname], 10]; { _x hideObjectGlobal true; _x hideObject true; } forEach _list; If i run the code by my self or via the Server, it works pretty well. I hope someone know my issue and can help me.
- 3 replies
-
- arma3
- hideObject
-
(and 3 more)
Tagged with:
-
addaction to ai in multiplayer runs an introlike camerasequence
junky82 posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hey boys, i've got a real big problem (the perfect start for a scripting noob ;) ). I started creating a multiplayermission in the eden editor, and i got an AI with an addaction on it. So when all mods are synced, all the player will go to the AI and all can choose the addaction. But if one of them was clicking on it, the script should run for all players at the same time. But in my case, it is not just a script like healing or teleporting. This will be a camerascript. I tried a lot of things, and they worked for me, while testing in the editor, but they are not working in multiplayer on the server. They were running just for each player, and the helis are not flying, just standing there in spawnposition. And one more importend thing, before i post my scripts: When i add a .sqf file, i will get this error: "Preprocess failed with error - Invalid file name(empty filename)" Just when i change to .sqs the script will run in editor. Init's of my AI called Opa_1: (all examples worked in Editor, but not in MP) example 1: if (isServer) then { intro = this addAction ["Legen wir los.", {Opa_1 exec "script\opaintro.sqf";}, nil, 6, True, True, "", "(_target distance _this) < 6"];} example 2: if (isserver) then {[[Opa_1, ["Legen wir los ...","script\opaintro.sqs"]],"addAction",true,true] call BIS_fnc_MP;} example 3: {Opa_1 addAction ["Legen wir los ...","script\opaintro.sqs"];} remoteExec ["bis_fnc_call", 0]; opaintro.sqs/.sqf (i just changed the filename for example 1): ? ((paramsArray select 0) == 0) : goto "del" _camera = "camera" camcreate [0,0,0] _camera cameraeffect ["internal", "back"] showcinemaborder true; opa_1 switchmove "Acts_B_out2_briefing"; opa_1 removeaction intro; ;comment "20:01:58"; _camera camPrepareTarget [-75303.13,29256.81,5625.25]; _camera camPreparePos [23691.55,16276.09,2.44]; _camera camPrepareFOV 0.324; _camera camCommitPrepared 0 ;comment "20:02:27"; _camera camPrepareTarget [84408.05,-62884.46,-6862.32]; _camera camPreparePos [23692.37,16276.17,2.65]; _camera camPrepareFOV 0.195; _camera camCommitPrepared 10 ~10 aheli1 hideobjectglobal false; aheli1 enablesimulationglobal true; aheli2 hideobjectglobal false; aheli2 enablesimulationglobal true; aheli3 hideobjectglobal false; aheli3 enablesimulationglobal true; playmusic "introbg_1"; ;comment "20:19:05"; _camera camPrepareTarget [122550.25,31165.10,2120.64]; _camera camPreparePos [23688.01,16272.10,3.95]; _camera camPrepareFOV 0.696; _camera camCommitPrepared 0 ;comment "20:19:56"; _camera camPrepareTarget aheli2; _camera camPreparePos [23686.90,16279.11,5.23]; _camera camPrepareFOV 0.033; _camera camCommitPrepared 10 ~10 titleCut ["", "BLACK OUT", 1] ~ 4 player cameraEffect ["terminate","back"] camDestroy _camera ? ((paramsArray select 0) == 0) : goto "end" titleCut ["", "BLACK IN", 5] #end exit So the srcipt will execute for the player who hits the addaction, but not for all at the other players (but thats what i want). And the helicopters just will show up for the player which hits addaction. This opaintro-script is the short one for testing. I've got a bigger one, just with more camera positions an more switchmoves an playmusic. If needed, i am able to create a link for the missionto download, but i am using mods on this. I hope they are not important for the solution. So please tell me, it's just a simple thing. And please explain your solution. This trial an error took about 8 hour's right now, and i am going crazy on that, because it is not working on the server.- 10 replies
-
- addaction
- multiplayer
-
(and 4 more)
Tagged with: