Jump to content

D. Patterson

Member
  • Content Count

    77
  • Joined

  • Last visited

  • Medals

Posts posted by D. Patterson


  1. _Clouds = 300 setOvercast 1;

    Should produce a gradual overcast over the term of 5 minutes correct? it does nothing, the only way I can get it to do something is skipTimes and simulWeatherSync's. But then it's an instant change and has momentary freeze.

    Also how do I prevent rain, lightning and wind? I set them after I set the overcast, but after a few moments they change back. (Even if intel rate of change is 9999hr)


  2. Is there is a way to get the type of road a vehicle is on? Asphalt Paved roads show as #GDTSoil, the concrete paved side roads are #GDTConcrete, and dirt roads are #GDTSoil. I've tried different getPos (getPos, getPosASL, getPosATL, getPosATLVisual, etc) I can use isOnRoad to differentiate between road and non-road of same surface, but how do I differentiate between asphalt and dirt roads?

    Even weirder, that main orange road that travels through Altis (The dark paved one), isn't even considered a road. When using nearRoads it isn't even identified. However it is identified by isOnRoad.


  3. As soon as a player gets in a boat, I want to enable a hotkey to run a script. As soon as the player leaves the boat, it runs the script again (Without them having to hit the hotkey). displaySetEventHandler makes no sense to me and I cant even get it to work with simple hint scripts and no conditions. Google doesn't produce any helpful answers either. I'd like to avoid triggers or waitUntils if possible.


  4. So I have a post, that when you walk up to it, you get several action menu items. Teleport 1, Teleport 2, Teleport 3. How do I make it so I can have each one link to the same sqf, but the sqf can differentiate between what option was selected. Im fine with putting multiple addactions in the init, but I dont want Teleport1.sqf, teleport 2.sqf, etc. (Because I actually have 15 teleport positions).


  5. 1. Why do you add the actions to the player instead of simply adding the action directly to your treasurecrate?

    2. There is NO reason to use a trigger as addAction itself can have a condition that defines exactly when the action should be visible.

    So I changed it to

    for [{_i1=0}, {_i1<_LootSpawnEX}, {_i1=_i1+1}] do 
    		{
    		lootcrate = createVehicle ["Land_CratesWooden_F",getMarkerPos "wreckmarkerf1", [], 18, "NONE"];
    		PublicVariable "lootcrate";
    		Loot_DirEX = Ceil random 360;
    		PublicVariable "Loot_DirEX";
    		lootcrate setDir Loot_DirEX;
    		lootaddact = lootcrate addAction ["Pickup Treasure", "pickup.sqf", nil, 1.5, true, true,"","true"];
    		PublicVariable "lootaddact";
    		};

    But only the player who used the trigger that activated the script will get the option to "Pickup Treasure"


  6. null = mortarTarg1 setPos [(getPos mortarTarg1) select 0, (getPos mortarTarg1) select 1, 500];
    mortarTarg1 hideObject true;
    for "_i" from 0 to 100 step 1 do {
    delayEX = ceil(random 250);
    PublicVariable "delayEX";
    _delay = (_delayEX / 100) + 0.5;
    Sleep _delay;
    _shella1 = createVehicle ["Sh_155mm_AMOS", position mortarTarg1, [], 150, "FLY"];
    _shella1 setVelocity [0,0,-100];
    };

    There is an invisible helipad named mortarTarg1

    I used HideObject because it would drift away for some weird reason.

    setVelocity -100 seems to be the only velocity where the sound plays.

    ceil(random 250) will be the delay in seconds after (it is divided by 10) and +0.5 added (Delay between shots will be 0.5 to 3.0 seconds)

    Sh_155mm_AMOS is the ammo

    In the for command, change the 100 to how many shots you want. If you want it random make another random call

    shotsfired = ceil(random 18); // 18 is the max 
    PublicVariable "shotsfired"; // Declare it public so it'll be consistent on multiplayer


  7. So the loop part of my script is this

    for [{_i1=0}, {_i1<_LootSpawnEX}, {_i1=_i1+1}] do 
    		{
    		_lootcrate = createVehicle ["Land_CratesWooden_F",getMarkerPos "wreckmarkerf1", [], 18, "NONE"];
    		Loot_DirEX = Ceil random 360;
    		PublicVariable "Loot_DirEX";
    		_lootcrate setDir Loot_DirEX;
    		_loottrg=createTrigger["EmptyDetector",getPos _lootcrate];
    		_loottrg setTriggerArea[3,3,0,false];
    		_loottrg setTriggerActivation["ANY","PRESENT",true];
    		_loottrg setTriggerStatements ["player in thislist", "LootAddAct = player addAction ['Pickup Treasure', 'pickup.sqf', nil, 1.5, true, true]", "player removeAction LootAddAct;"]
    		};

    When I go near a spawned crate, I get the action for that crate, however it's hit and miss whether or not the action is removed, on some crates it's removed, on others it stays (Clutters the action menu)

    Any ideas what's going wrong?


  8. Im trying to have alot of objects created, but I dont want them to be created on the server (due to lag) unfortunately this doesn't work:

    NullSpawnWreck = player createVehicleLocal ["Land_UWreck_FishingBoat_F",getMarkerPos "wreckspawn_1", [], 4000, "NONE"];

    I need it to spawn within a 4000 unit radius of marker "wreckspawn_1" but it cannot be created on the server, it must be created locally. Error is type object expected string


  9. LUKI;2724903']Respawn is allowed only in MP missions' date='[/b'] no in SP missions.

    You must create description.ext file in your mission. Paste in this lines:

    respawn=3;
    respawnVehicle=3;
    respawndelay=10;
    respawnVehicleDelay = 20;
    respawnDialog = true;
    AIkills=1;

    In the editor create one marker with name "respawn_west" or "respawn_east" (if you will be play as WEST units, you will respawn on marker "respawn_west", EAST will be respawned on "respawn_east", guerilla/independent units will be respawned on marker "respawn_guerrila").

    Save mission before you want to use this respawn !

    EDIT: I find now this thread on ArmAholic forums, so see here: http://www.armaholic.com/forums.php?m=posts&q=20070

    SO will this work in singleplayer?


  10. Think of autotarget as target seek, when disabled a unit will not look for targets, if gunshots come from behind, ai wont turn and seek source of gunfire. If a target walks into it's field of view, it will still react. Also if it is in a group, it will react to group leaders target commands. If you disableAI "TARGET" it will react to threats, but will not engage. You can then use combination of doTarget, laserTarget, doFire commands

×