Jump to content


  • Content Count

  • Joined

  • Last visited

  • Medals

Community Reputation

1 Neutral

About Luft08

  • Rank
    Lance Corporal

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Dedmen, You are a god! Thank you!
  2. I need to determine which side of the East/West German border a player is located on the Weferlingen summer map. I don't want the East Germans shooting across the border. At first I though I would use triggers but it takes a LOT of triggers to get the granularity I need. So I though I would bite the bullet and do some kind of ray trace and count the number of times the ray crosses the fence line. Odd number and they are valid targets, even and they are safe. However I don't know how to define the polygon from the fence/wall. Can code be written to do that automatically or must I painstakingly define each point by hand? Thanks
  3. Perfect! With this example I think I may be able to write functions. There is one thing. The editor I use gives a warning on the hint line: "Public variable 'LFT_fnc_getDistance' may be used before being assigned a value." The mission does not complain at all but am I forgetting to define the function or something (Just to shut my editor up)
  4. I've watched several videos and read many posts about functions but I can't seem to get mine to work. description.ext: class CfgFunctions { #include "functions\cfgFunctions.hpp" }; cfgFunctions.hpp (inside a folder called functions): class cfgFunctions { class LFT { tag = "LFT"; class functions { file = "functions\functions.sqf"; class GetDistance {}; }; }; }; functions.sqf (inside the folder called functions): GetDistance = { params ["_object1", "_object2"]; private _distance = _object1 distance _object2; _distance }; inside the calling script: private _distance = [officer_01, weaponsCache] call getDistance; hint str _distance; The officer_01 and weaponsCache are both objects. When called I get an "undefined variable getDistance" error. I've tried calling LFT_getDistance, LFT_fn_getDistance and LFT_fnc_getDistance but no joy. I need a slow thinker's tutorial I guess. 😞
  5. I found that putting: "this allowDamage false;" in the init fields fixed this. I don't understand why unchecking the Eden editor's "enable damage" property doesn't do the same thing but it's working now.
  6. I made a quick mission that has various helicopters as a training scenario. I unchecked the "enable damage" boxes in the Eden editor for the helicopters and all the players. It works as expected when run from the editor, however when run from my dedicated server crashing still causes damage, death and other mayhem.
  7. I installed a dedicated server on an older PC but when I run Arma from my regular PC it tells me that I am already running Arma from another PC. I'm sure there is a way to run a server without having to create another account and purchase Arma and all of the DLC's again isn't there?
  8. Now that makes sense. Thanks.
  9. Yes, but my point is that it is a string that I supplied so I could do that even if it didn't return anything. I already have the string. Maybe I'm not understanding something? Oh well, it is what it is...
  10. So it returns one of the parameters that I supply? I don't understand how that is helpful?
  11. The wiki gives an example of the use of createMarker: _marker1 = createMarker ["Marker1", position player]; It also explains the parameters as: name, position and says that it returns a string. However, I don't understand what the string is. How can I use it? Is it some kind of id?
  12. Thanks, it is a variable so I'll use the brackets. I have scripts in several directories. "missionPath" is actually a misleading variable name. Hmmm... I think I need to pay a little more attention to detail.
  13. gc8, I think you are correct. I believe I have an error elsewhere. For one thing the quote mark in the above code. 😞 Your code example does help however. That's the way I'll be doing a lot of remoteExec from now on. Thanks again.
  14. I'm no expert either so maybe I'm doing completely wrong. I read that the setTriggerStatements only runs locally. I recently installed a dedicated server on my PC so that I could test as a non-server. I noticed that what I was seeing wasn't always the same as when I was both the server and a player. For example I would see the characters move their lips when speaking but my friends would not. (randomLip is also local.) I also noticed when playing as a non-server that when I completed the final task the mission wouldn't end so I assumed it was a scope problem with the setTriggerStatements. Here's the tsk1Succeeded.sqf code that creates the final task (which is simply to fly back to base: if(isServer) then { ["tsk1","SUCCEEDED"] call BIS_fnc_taskSetState; deleteVehicle trg1; // delete the trigger. if(!isNil "player_1") then { [80]execVM missionPath + "goAfterPlayer_1.sqf"; }; if(!isNil "player_2") then { [80] execVM missionPath + "goAfterPlayer_2.sqf"; }; if (!isNil "player_3") then { [80] execVM missionPath + "goAfterPlayer_3.sqf"; }; if(alive heli_01) then { [true, ["tsk2"], ["Fly the littlebird back to base and land on the helipad", "Return to base", "returnMarker"], hPad_01, "ASSIGNED", 1, true, "land", true] call BIS_fnc_taskCreate; handle = execVM "missionPath + createReturnToBaseTrigger.sqf"; } else { // give option to call for extraction. }; }; I'm getting better (believe it or not) but I still have a long ways to go.
  15. Arrrrggghhhh! It's not. tsk1Succeeded.sqf is run on the server. So close and yet so far. Maybe I don't have to run the entire tsk1Succeeded.sqf code on the server. I'll work with it. Thanks yet again. 🙂