Jump to content

sarogahtyp

Member
  • Content Count

    2494
  • Joined

  • Last visited

  • Medals

Everything posted by sarogahtyp

  1. sarogahtyp

    adding map locations

    This question is ansered in this thread already. you just need to read it...
  2. yeah, this is what they published there but its also the same as they state since 2 weeks everywhere ...
  3. 100% this! I have already vented my anger here (Discord Channel) today. You are cordially invited to make a contribution there.
  4. sarogahtyp

    moveInDriver help

    okay, I didn't get that. I applied your init code to the player itself. But doing this on a NPC unit should work as well...
  5. sarogahtyp

    moveInDriver help

    params ["", "_examinedplayer", "", "_args_array"]; is doing the same as private _examinedplayer = _this select 1; private _args_array = _this select 3; it just puts the second and the forth element of the parameters array _this in variables and also makes that variables private. the following does the same but does not use the parameters array _this but the above created array _args_array for putting its elements into variables and making them private: _args_array params ["_examtype", "_examvehicle", "_examtimeout"]; puts first, second and third element of _args_array in their corresponding variables and makes those private. you could achieve the same by doing this: private _examtype = _args_array select 0; private _examvehicle = _args_array select 1; private _examtimeout = _args_array select 2; use of params is shorter and cleaner. also params has much more features to make the code failsafe. Just look at the biki for it: params
  6. sarogahtyp

    moveInDriver help

    this is tested and working: params ["", "_examinedplayer", "", "_args_array"]; _args_array params ["_examtype", "_examvehicle", "_examtimeout"]; private _exam_veh = _examvehicle createVehicle ( player modelToWorld [ 0, 10, 0 ] ); // getMarkerPos "drivingcheckpoint_0"; //Spawn desired vehicle at marker _examinedplayer moveInDriver _exam_veh; //This works locally but I recommend to not do this in players init: this enableSimulation false;
  7. sarogahtyp

    moveInDriver help

    I guess i was on the wrong track...But why do you disable simulation on the player entity?
  8. I did not find an easy solution but you could use the debug console (in "Tools" menu or shortcut Ctrl + D ) for it. First select the object what you need the rotation of. Then open debug console and paste this in it: copyToClipboard str ( get3DENSelected "object" select 0 get3DENAttribute "rotation" ); Press "Local Exec" or just hit Enter key and the rotation is in your clipboard.
  9. sarogahtyp

    moveInDriver help

    I guess your problem is that your script works on hosted server (only for the player who is server) and singleplayer but not on dedicated server. The problem is locality which is the most common issue with multiplayer scripting. In your case the problem is the command moveInDriver which needs its arguments to be local on the machine where it is executed to take effect. you can see that this is necessary on top of the biki page where the icon with LE is shown. There is also a note onthat page which helps us to identify the argument whcih the problem is: To solve your issue you have to send the command to the machine of the player which should get moved in using remoteExec: [_examinedplayer, _exam_veh] remoteExec ["moveInDriver", _examinedplayer]; [_examinedplayer, _exam_veh] - specifies the arguments which should get sent ["moveInDriver", _examinedplayer] - specifies the command which should get executed and the reference (the player object in this case) to the machine which should execute it.
  10. sarogahtyp

    Finding TOTALLY empty position

    You can easily check the found area against moving vehicles and men and discard the solution within the while loop. Your other cases ... yeah man work on it and u ll solve it. There is a way for nearly everything if u spend enough time on it.
  11. sarogahtyp

    Finding TOTALLY empty position

    This can be used in debug console. Its working and tested. just point to an object. Its position is the search start position. Player gets teleported to the position which fullfills the requirements: // diameter of the flat, empty area you are searching for private _posMaxWidth = 50; // position to start at private _center = getPos cursorObject; // [ 3727.84, 13759.1, 0.496591 ]; // radius of the area you are searching at private _abortDist = 1000; // gradient (bumpiness [0.0 ... 1.0] ) of the area you are searching for private _maxGrad = 0.1; private _dblPosMaxWidth = 2 * _posMaxWidth; private _objDist = _posMaxWidth * 0.5; private _maxDist = _objDist; private _minDist = 0; private _invalidPos = [ 0, 0, 0 ]; private _pos = _invalidPos; private _waterMode = 0; private _shoreMode = 0; private _blacklistPos = []; private _defaultPos = [ _invalidPos, _invalidPos ]; // Start of the search in the immediate vicinity of the starting point and expansion of the search area as long as no suitable area has been found. while { (_pos isEqualTo _invalidPos) and (_maxDist < _abortDist) } do { _pos = [ _center, _minDist, _maxDist, _objDist, _waterMode, _maxGrad, _shoreMode, _blacklistPos, _defaultPos ] call BIS_fnc_findSafePos; _maxDist = _maxDist + _posMaxWidth; //Exclude already searched areas from a new search. _minDist = if ( _maxDist > _dblPosMaxWidth ) then { _maxDist - _dblPosMaxWidth } else { 0 }; }; // check the result if ( _pos isEqualTo _invalidPos ) then { hint format [ "No suitable area found within a radius of %1m.", _abortDist ]; } else { hint format [ "Position %1 meets all requirements.", _pos ]; player setPos _pos; };
  12. sarogahtyp

    Finding TOTALLY empty position

    https://community.bistudio.com/wiki/BIS_fnc_findSafePos
  13. sarogahtyp

    Cancel Scripted Fire Mission Waypoint

    There should be a cleaner solution by spawning the corresponding function (BIS_fnc_wpArtillery) and later just stopping it with terminate. customartyscript.sqf: _private _index = _this spawn BIS_fnc_wpArtillery; private _group = _this select 0; _group setVariable ["artyScriptIndex", _index]; setting the script to waypoint: _wp setWaypointScript "customartyscript.sqf"; stopping arty from firing (you have to know the group) : _index = _group getVariable "artyScriptIndex"; terminate _index; all of this not tested but should work this way.
  14. if I understood your problem then you want to know the lowest height for opening the parachute. What you should have already is the deceleration value for your vehicle while falling with opened parachute. Also you should know the maximum touch down velocity to not get your vehicle destroyed. If you have all of this then this should do it: private _vec = your vehicle private _a = your Deceleration value (dependent on vehicles mass) private _maxSpeed = your touchdown maximum speed private _v_z = ( velocity _vec ) select 2; private _time = (_v_z - _max_speed) / _a; private _height = _a * _time^2 Decelaration value should be a positive value to work with this formula. I just put the formula together but I didnt calculate anything. Therefore this should be the solution but I'm not sure because I didnt verify it. Edit: velocity value of the vehicle when falling is negative I assume. The formula needs a positive value. But I guess you ll solve this^^
  15. instead of that it will explode instantly if parked or spawned near another vehicle in multiplayer^^ The serious answer is: Arma 3 physics is a mess. I assume it has to do with some strange optimizations around mass calculations through the game engine. But the community can't really answer this. An Arma 3 physics developper could...
  16. As a small side not for those who are interested: On 06/15/2017 I initially created the Scheduler page on BI wiki and many other biki authors pushed it to the current state. The reason was to have a summary of the scheduler which clears up misunderstandings. To this day (5 years later) this ACE wiki page still exists: Pure Nonsense To be fair there are other pages on their wiki which describe how to use cba stuff to avoid executing code in scheduled env. which may be okay. But if you read this page alone than thats absolute nonsense!
  17. event handlers are the most effecient way to execute code when something (in this case the reload) happens. Therefore you are good with it. If one needs to do something when a weapon is fired then he will use that fired event handler and he can do that because its just the best way. The thing what a scripter has to think about is can I use an EH (then he should do that), are there multiple EHs which would do the job and which of them is the one which gets least likely triggert (to save most performance.) If the right EH is found then the code executed if EH triggers comes in play. There we have to cases: 1. some simple code with a few lines which runtime is mostly much lower than 1 ms - nothing more is to be done, those code can just be executed as is in the EH. - that means it will get executed completely and instantly in the executing instance. This is called unscheduled environment 2. a heavy code which is doin multiple loop iterations and which runtime is more, much more or just near 1ms. - those code if it would be executed in above mentioned unscheduled environment would cause fps drops or even temporarly game freezes (depending on the work to do). - the reason is that all other stuff waits for the code to get finished ( yeah arma is a mostly single thread/core using program :) - but what is to do with such code? it has to get spawned to be executed in the scheduled environment. - what happens there? the script scheduler takes care about the code now. - the scheduler will execute parts of the code on defined time frames now. - this results in an undefined execution time of the code (mostly much longer than in unscheduled env.) - but the advantage is that the code will not cause fps drops anymore. - Only if too many such scripts overload the script scheduler then fps drops may happen or scripts are not working as intended anymore because ther runtime gets extensivly high. Further details on Scheduler: https://community.bistudio.com/wiki/Scheduler Getting code fast: https://community.bistudio.com/wiki/Code_Optimisation
  18. It will produce fps drops if heavy code is executed there which runtime is some milli seconds. such code should be spawned inside the event handler to avoid fps drops. But this is not the case here. no need to burden the script scheduler here. You can just do what you want to without any noticeable drops on fps. Edit: Also how often is one of all AIs reloading in a scenario on a typicall firefight? I guess no more than once a second. Thats nothing what you should worry about.
  19. I had some CTDs while using AR Tools - World Editor without any error message window appearing. I had some similar problems before (with AR Server) where a logfile told me that there is a memory size problem ( I ve 32 GB ). I tried the same solution I found there with AR Tools as well. Therefore I lowered the size of my RAM-Cache which the ASUS Software RamCache III creates. The CTDs didn't occur as frequently as they used to, but it did happen again from time to time. Now I disabled my Ram-Cache completly and the CTD is gone. Just wanted to share this anywhere... Cheers
  20. A and B drives were classically bound to floppy disk drives. Maybe windows has some old obsolete functions for these drives which are causing your problems. Maybe just using another character solves it.
  21. sarogahtyp

    Frigate hangar screen

    should be a texture surface. if so then you can feed on it.
  22. simply not possible. you ve to create some kind of configuration array for every single vehicle you want to support.
  23. _weaponHolder = "WeaponHolderSimulated" createVehicle [0,0,0]; _weaponHolder addBackpackCargoGlobal ["B_Bergen_dgtl_F", 1]; _weaponHolder attachTo [cursorObject, [0.32, -0.3, 0.65], "OtocVelitele"]; not tested
  24. sarogahtyp

    Arma Reforger - Mission Editor

    yes there were 2 little updates and those are provided through steam. Here you can view the changelogs: https://reforger.armaplatform.com/news No, this is a thing which should be build on the wiki within the next weeks. But you can view a bit here: https://community.bistudio.com/wiki/Category:Arma_Reforger/Modding/Tutorials/Scripting https://community.bistudio.com/wiki/Category:Arma_Reforger/Modding/Guidelines/Scripting Also you can use workbenchs script editors auto completion to find desired commands and classes. The last ressort is to enter armas enfusion scripting chat channel on discord and ask there. The guys knowledge on discord is worlds away from anywhere else...
  25. hard to answer cause I m also on the very beginning with enfusion and I ve no clue how exactly a game mode is designed. but what I know is the path in resource browser where the game mode entities are located (idk if that helps): ArmaReforger>Prefabs>MP>Modes Otherwise I would recommend you to learn the basics first as I try to do currently myself. Maybe first making a little mission and learning on it instead of creating a whole gamemode from scratch. This is the tutorial I started with:
×