Jump to content

neokika

Former Developer
  • Content Count

    1160
  • Joined

  • Last visited

  • Medals

  • Medals

Everything posted by neokika

  1. Hi, That is because you are sending an object to the SaveLoop.sqf script and inside of it, you are trying to access the first element of an array, that does not exist. Inside SaveLoop.sqf change: _Playerunit = _this select 0; To: _Playerunit = _this; Or, whereever you execute: this execVM "SaveLoop.sqf" Change it to: [this] execVM "SaveLoop.sqf"
  2. Hi, Both setVehicleInit and it's related processInitCommands have been removed completely from Arma 3 and there are no new ones. These have been removed because they were created (a long time ago) for never released functionality and were always discouraged to be used, at all. That is why it is never used internally (official content). For a long time (since before Arma 2 I think) there are more secure and robust ways to deal with multiplayer locality. The new compileFinal probably is not what you are looking for in this particular case, basically, it allows you to define functions/code to a final variable, that does not allow further modifications to it. Within the first piece of code you posted you simply store a created object to a variable, that can be accessed from any computer within the network and could be changed to: TAG_myGlobalVariable = _spawnUnit; publicVariable "TAG_myGlobalVariable"; So, both the server and clients now can access _spawnUnit object that is stored within TAG_myGlobalVariable. Something to keep in mind about multiplayer scripting is knowing what needs to be executed where. Most of the commands documented on the wiki have their locality defined. When inside a scripting function page, you can check what's it's locality. - Arguments need to be local - Arguments do not need to be local - Effects happen locally, where the command is issued only - Effects are global and happen on every computer connected
  3. Sorry to disappoint you, but it does not mean that. It means only that we are aware of the issue. :)
  4. You need curved brackets / code. this addEventHandler ["Fired", { hint "Fired"; }];
  5. Not possible to include files from parent folders. Only from same folder or it's children.
  6. neokika

    Triggered Respawn

    You need to set your respawn to Base in your description.ext. respawn = 3; And then create proper markers called: respawn_west respawn_east respawn_guerrila respawn_civilian Note that this way, players will only respawn when appropriate (When they die). If you want to manually respawn them, you can either teleport them or kill them :) By killing them: { if (isPlayer _x) then { _x setDamage 1; }; } forEach allUnits; By teleporting them: { if (isPlayer _x) then { switch (side _x) do { case WEST : { _x setPos getMarkerPos "respawn_west"; }; case EAST : { _x setPos getMarkerPos "respawn_east"; }; case RESISTANCE : { _x setPos getMarkerPos "respawn_guerrila"; }; case CIVILIAN : { _x setPos getMarkerPos "respawn_civilian"; }; }; }; } forEach allUnits;
  7. Can you please report the issue on the Feedback Tracker? Login is the same as the forum.
  8. In the meantime you can you setDir.
  9. neokika

    knowing Unit Items ?

    Arma 3 also introduced the following scripting commands that return the current items: - assignedItems - backpackItems - vestItems - uniformItems - handgunItems - primaryWeaponItems - secondaryWeaponItems Prior to removing an item you should make sure to unassign it first using unassignItem.
  10. There is currently on going work to lock the ability to override engine scripting commands, no longer possible to do it on dev branch, such as spawn, so that is why you are receiving that message. getMarkerPos expects a string with a marker name. You currently give a (probably?) undefined variable. Your createVehicle is also wrong, currently there are two different implementations of it, the most simple one is: _chopper = "B_AH9_F" createVehicle getMarkerPos "helispawn"; But that one should be avoided and you should definitely use the createVehicle Array: _chopper = createVehicle ["B_AH9_F", getMarkerPos "helispawn", [], 0, "NONE"];
  11. Yes, setVehicleInit, processInitCommands and clearVehicleInit have been removed from Arma 3 and will happen on stable build also, for security reasons. Although, using these was always a bad choice. See BIS fnc MP, that make full use of publicVariable commands, including the new publicVariableServer/publicVariableClient. To avoid such abuse, compileFinal has been added, giving the ability to make compiled functions final. Ofc, these are only the first steps to make MP more secure and next week Arma 3 Project Lead will explain these in more detail.
  12. neokika

    DamageHandler

    If you create the vehicle on the server then you need to add the event handler in there also. Just keep in mind that the event handler fires/executes where the object is local. Also, vehicles may change their locality within a game session, for example, if you create a vehicle on the server at mission start but a Player enters it, the vehicle will then become local to that player's machine and so on. So, to make this work in every situation you would have to add the event handler in every machine and make your setVariables global.
  13. If you use the new Task functions you do not need to define notifications. Functions Viewer > Tasks. [ player, "MyTask", [ "Description", "Title", "WAYPOINT" ], getMarkerPos "SomeMarker", true ] call BIS_fnc_taskCreate;
  14. neokika

    Lifespan chem light

    The following should work: _chemLight = createVehicle ["Chemlight_green", _somePosition, [], 0, "CAN_COLLIDE"]; waitUntil { isNull _chemLight }; hint "ChemLight has been deleted!";
  15. So you execute from a editor trigger? Editor triggers are local to each machine connected, so everyone that joins the mission, will have it's own trigger that works independently from everyone else. Instead, just execute the sinit.sqf from the init.sqf file, if you do not have it, just create one at mission folder. if (isServer) then { //This will only run once [] execVM "scripts\sinit.sqf"; }; Then, you can simply delete any other isServer/isDedicated check from inside the scrips, because they become useless. IsServer returns true if the current machine (where this command was issued) is the Server. IsDedicated will return true if the current machine (where this command was issued) is the Server and is a Dedicated server.
  16. ARMA 2: Community Configuration Project (A2CCP)
  17. No problems here with such commands, can you post how you are executing those scripts and the related code of them?
  18. It's better to use nearestObjects instead, it will return the objects from the nearest to distant, while nearObjects won't. //Search for nearest objects _objects = nearestObjects [heli, ["LandVehicle"], 200]; //Have we found any? if (count _objects > 0) then { //The nearest object _object = _objects select 0; };
  19. iskindof "LandVehicle" The above throws an error because it is missing the object. player iskindof "Man" The above would return TRUE. Although, the nearestObject function needs only a String, in his case it would be "LandVehicle". _object = nearestObject [heli, "LandVehicle"]; _object is now the nearest "LandVehicle" object, if any is actually near, otherwise will be ObjNull (NULL).
  20. Problem seems to be that player unit's init is getting executed before the group's team leader unit init. - The mission starts reading mission.sqm file - Player init (null = [this, ReinGrp] execVM "reinforcement.sqf"; ) gets executed, but at this point, ReinGrp is NULL. - Group team leader's init gets executed and assigns it's group to ReinGrp. This could be fixed by either deleting the player unit (and save mission) and place it again (and save mission) so it's entry in mission.sqm is after the group leader unit or having some kind of delay like DarkDruid said.
  21. neokika

    Make heli land under fire

    You can also disable the AI abilities completely. _chopper enableAttack false; _chopper setBehaviour "CARELESS"; _chopper setCombatMode "BLUE"; _chopper disableAi "TARGET"; _chopper disableAi "AUTOTARGET"; _chopper disableAi "FSM"; If the above doesn't do it, please report the issue here.
  22. neokika

    Arma 3 Coding

    Dear AK_Roughneck, While I understand your frustration please let me remind you that not long ago, there was a confirmation from a Developer that the Editor in Arma 3 will have a UI option to change a unit/crate loadout, be patient since we are still in Alpha. _neo_
  23. neokika

    Mirrors on vehicles

    No, it depends on your video settings, the PIP option.
  24. Not easily done, no. The way to make sure you have it acting fully consistent is to do the variable updates on the same machine (ex. Server).
  25. neokika

    Arma 3 PhysX Playground

    Video should be working now.
×