kovvalsky
Member-
Content Count
67 -
Joined
-
Last visited
-
Medals
Everything posted by kovvalsky
-
[Array search function] Array(strings) in Array(strings)
kovvalsky posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Hi, i try to compare two arrays like this: _ArraySt = ["a","b","c"]; _ArraySrch = ["c","d"]; _Result =_ArraySt in _ArraySrch; //_Result is false... then i try this but don't work.. _ArraySt = ["a","b","c"]; _ArraySrch = ["c","d"]; { _Result = _x in _ArraySrch; if (_Result) exitWith {}; //KK thanks }forEach _ArraySt; //still return false How I can search on an array (containing strings) another array with strings inside too?. thanks! (SOLVED) /* ------------------------------------------------------------------------------ DESC: Returns true if search string inside array exist ------------------------------------------------------------------------------ PARAMS: 0: [ARRAY] Content array 1: [ARRAY] Search array or 1: [sTRING] Search string ------------------------------------------------------------------------------ RETURN: [bOOLEAN] true or false ------------------------------------------------------------------------------- EXAMPLE: _Result = [["a","b","c"],["c","d"]] call your_FunctionName; // _Result is true _Result = [["a","b","c"],["C","D"]] call your_FunctionName; // _Result is false _Result = [["a","b","c"],"a"] call your_FunctionName; // _Result is true ------------------------------------------------------------------------------ */ private["_Contenido","_Busqueda","_Resultado"]; _Contenido = [_this,0,[],[[]]] call BIS_fnc_param; _Busqueda = [_this,1,"",["",[]]] call BIS_fnc_param; _Resultado = false; if ((typeName _Busqueda) == "STRING") then {_Busqueda = [_Busqueda];}; if ((typeName _Contenido) == "ARRAY")then { { _Resultado = _x in _Busqueda; if (_Resultado) exitWith {}; }forEach _Contenido; } else { _Resultado = _Contenido in _Busqueda; }; _Resultado; -
[Array search function] Array(strings) in Array(strings)
kovvalsky replied to kovvalsky's topic in ARMA 3 - MISSION EDITING & SCRIPTING
jejej sorry!! not my intention, i love old school I really like your function, I appreciate the contribution -
[Array search function] Array(strings) in Array(strings)
kovvalsky replied to kovvalsky's topic in ARMA 3 - MISSION EDITING & SCRIPTING
THANKs All! Final function: private["_Contenido","_Busqueda","_Resultado"]; _Contenido = [_this,0,[],[[]]] call BIS_fnc_param; _Busqueda = [_this,1,"",["",[]]] call BIS_fnc_param; _Resultado = false; if ((typeName _Busqueda) == "STRING") then {_Busqueda = [_Busqueda];}; if ((typeName _Contenido) == "ARRAY")then { { _Resultado = _x in _Busqueda; if (_Resultado) exitWith {}; }forEach _Contenido; } else { _Resultado = _Contenido in _Busqueda; }; _Resultado; -
[Array search function] Array(strings) in Array(strings)
kovvalsky replied to kovvalsky's topic in ARMA 3 - MISSION EDITING & SCRIPTING
yes :) fixed :) DreadedEntity thanks, old school solution. :p Final function: private["_Contenido","_Busqueda","_Resultado"]; _Contenido = [_this,0,[],[[]]] call BIS_fnc_param; _Busqueda = [_this,1,"",["",[]]] call BIS_fnc_param; _Resultado = false; if ((typeName _Busqueda) == "STRING") then {_Busqueda = [_Busqueda];}; if ((typeName _Contenido) == "ARRAY")then { { _Resultado = _x in _Busqueda; if (_Resultado) exitWith {}; }forEach _Contenido; } else { _Resultado = _Contenido in _Busqueda; }; _Resultado; -
A3 dialog / user interface editor. How to save/export/import?
kovvalsky replied to Tankbuster's topic in ARMA 3 - MISSION EDITING & SCRIPTING
to load custom Dialog use: Ctrl + I missionConfigFile >> "yourDialogName" :rolleyes: -
RscTree: Has anyone be successful using this dialog control?
kovvalsky replied to HeliJunkie's topic in ARMA 3 - MISSION EDITING & SCRIPTING
https://resources.bisimulations.com/w/index.php?title=Dialogs_Tree -
Hi all! Any ideas on how to block the tent or the sleeping bag to the player who has unpacked? there aren't any info at wiki and google :( I'm doing a DM and I wish the other players could not pack what is not theirs thanks!!
-
What about the Action(using AddAction) when the object that contains it is destroyed?
kovvalsky replied to kovvalsky's topic in ARMA 3 - MISSION EDITING & SCRIPTING
thanks for reply KK! with deleteVehicle command, my question is about performance. I don't know how many objects will make later. maybe a lot :) for now i have this on init.sqf fnc_AddAction = { private ["_ActObj","_ActTitulo","_ActScript"]; _ActObj = [_this,0] call BIS_fnc_param; _ActTitulo = [_this,1] call BIS_fnc_param; _ActScript = [_this,2] call BIS_fnc_param; if(isNull _ActObj) exitWith {}; _ActObj addAction [_ActTitulo, _ActScript, [], 1, True, True, "", "(_target distance _this) < 2"]; }; fnc_deleteVehicle = {deleteVehicle _this}; <--- more code ---> [[_Obj,"<t color='#FFFF00'>Take</t>","Scripts\Take.sqf"],"fnc_AddAction",nil,false] call BIS_fnc_MP; Take.sqf _target =(_this select 0); //: Object - the object which the action is assigned to _caller =(_this select 1); //: Object - the unit that activated the action _ID = (_this select 2); //: Number - ID of the activated action (same as ID returned by addAction) player playActionNow "PutDown"; sleep 0.8; [_target,"fnc_deleteVehicle",false,false] call BIS_fnc_MP; -
Hi, I'm trying to do a multiplayer mission where you must grab an object. I used BIS_fnc_MP and AddAction workflow to grab it. In the script for the action the server destroys the object. :confused: You must run removeAction for all clients? :confused: Or when you destroy the object the action is removed for all clients? thanks!
-
[ARMA3] Scripted Database? How to work with BIS_fnc
kovvalsky posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Exploring BIS functions i found this BIS Database Functions... i think that is a part of TAKE ON HELICOPTERS but maybe can use it in ARMA? This is only what i found on forums: http://forums.bistudio.com/showthread.php?140413-Locations-%28of-heli-and-airports-on-the-map%29&p=2232539&viewfull=1#post2232539 if is possible, any idea that How to work with them? thanks! -
Can't call #Mission no more
kovvalsky replied to Moon_chilD's topic in ARMA 3 - SERVERS & ADMINISTRATION
im logged in as admin. Server freezes when i do #missions command... can't move players to slots, mission params or anything. only work #userlist command. if you look at RPT file there are few suspicious lines.. dta\bin.pbo - unknown ... dta\core.pbo - 0 ... ErrorMessage: Include file a3\functions_f\Params\paramDebugConsole.hpp not found. the problem seems to be in paramDebugConsole.hpp (Allow debug console for logged in admin) https://community.bistudio.com/wiki/Mission_Editor:_Debug_Console https://community.bistudio.com/wiki/Arma_3_Mission_Parameters if you want to vote on bis my ISSUE on feedback.arma3.com -
Can't call #Mission no more
kovvalsky replied to Moon_chilD's topic in ARMA 3 - SERVERS & ADMINISTRATION
here is my RPT file of arma3server -
Can't call #Mission no more
kovvalsky replied to Moon_chilD's topic in ARMA 3 - SERVERS & ADMINISTRATION
in my server occurs too.. there is a problem... Kremator and maquez thx but read all before post pls.. we know the command is #missions -
Hello everyone!, I'm doing a little Zombie FSM and would like to know your opinion. Is still in a very early stage, I hope that with your help I can improve it. I am a beginner, so do not ye be too hard on me!. :p Approach: Civilian and zombies in the same FSM. Civilians are infected when a zombie kill them. Infected civilian will become a zombie and then he will become part of the group that killed him. Civilian behavior: If there aren't zombies near: - They shall enter into the houses. - Stroll around. - They talk among themselves. With zombies near: - They will flee to a soldier if possible, if not, will get into the houses. - Civilians become zombies when they die by a zombie. Zombie Behavior: -Pursue and kill targets like crazy. -If there is dead (food) nearby, will go eat it. TO DO: 1. Improving zombie chase. if you run in circles they go to the last position, maybe with other condition with low priority? 2. improving zombie attack. for now, i use setDamage on zombie Attack State. And HandleDamage EH on civil, but EH don't trigger with this system. i need to do this in other way. 3. Increase zombie speed. 4. Decrease civilian speed. 5. Fix a lot of bugs.. 5. Better animation transitions.. That's all, for now only tested on SP. (forgive me for my poor english) FILE: Zombies
-
how to make renegades (ENEMY side) use parachute or UAV?
kovvalsky replied to kovvalsky's topic in ARMA 3 - MISSION EDITING & SCRIPTING
I'm frustrated, why DM mode has activated Friendly Fire? I've tried with: if (isServer) then {WEST setFriend [WEST, 0];}; and addRating too: While {True} Do { _i = 0; While {_i < Count AllUnits} Do { If (Rating (AllUnits Select _i) > -6000) Then { (AllUnits Select _i) Addrating ((- Rating (AllUnits Select _i)) - 3000); }; _i = _i + 1; Sleep 0.1; }; }; both ways works, all units become enemys. but still happening. I can not use the parachute or UAV. I no longer know what can i do.. -
Mission Countdown Timer w/ on screen time left?
kovvalsky replied to CrazyAirborne's topic in ARMA 3 - MISSION EDITING & SCRIPTING
NOOB Question: why you make publicVariable every time? publicVariable "ELAPSED_TIME"; should go out of the loop? like this? [] spawn { if (isServer) then { START_TIME = diag_tickTime; publicVariable "ELAPSED_TIME"; while {true} do { ELAPSED_TIME = diag_tickTime - START_TIME; sleep 1; }; }; }; -
would be very nice to see the 3Dflag icon only when the carrier dies. I don't know but maybe putting in CTFIcons.sqf on if state this?: "and (!alive BluforFlgCarrier)" thx for this template, very nice work