-
Content Count
65 -
Joined
-
Last visited
-
Medals
Posts posted by semedar
-
-
Just tried it and didn't work.
_light = "#lightpoint" createVehicleLocal position C130;
while { true } do
{
_light setLightBrightness 25;
_light setLightAmbient[0.0, 0.0, 0.0];
_light setLightColor[0.2, 0.5, 0.3];
_light lightAttachObject [C130, [0,0,0]];
Sleep 3;
_light setLightBrightness 0;
};
[/Code]Edit: I fixed it, it just needed another Sleep after setting the brightness to 0.
[Code]
_light = "#lightpoint" createVehicleLocal position C130;
while { true } do
{
_light setLightBrightness 25;
_light setLightAmbient[0.0, 0.0, 0.0];
_light setLightColor[0.2, 0.5, 0.3];
_light lightAttachObject [C130, [0,0,0]];
Sleep 1;
_light setLightBrightness 0;
Sleep 1;
};
[/Code] -
Hah, that seems to have done it! Thanks. :)
Wonder why it needs to be so bright when it's bright enough at ground level. :confused:
---------- Post added at 02:52 PM ---------- Previous post was at 01:11 PM ----------
Ok, I'm trying to make the light blink and I tried creating a light, attaching it to the C130, detaching it, and attaching it to another object but I can't seem to get it to work.
_light = "#lightpoint" createVehicleLocal position C130; while { true } do { _light setLightBrightness 25; _light setLightAmbient[0.0, 0.0, 0.0]; _light setLightColor[0.2, 0.5, 0.3]; _light lightAttachObject [C130, [0,0,0]]; Sleep 3; _light lightDetachObject [C130, [0,0,0]]; _light lightAttachObject [C130_Off, [0,0,0]]; };
When I try to just create a light it works:
_light = "#lightpoint" createVehicleLocal position C130; _light setLightBrightness 25; _light setLightAmbient[0.0, 0.0, 0.0]; _light setLightColor[0.2, 0.5, 0.3]; _light lightAttachObject [C130, [0,0,0]];
I've also tried to delete the light and creating it but can't seem to get that to work.
C130Light = true; while { C130Light } do { _C130Light = "#lightpoint" createVehicle getPos C130; _C130Light setLightBrightness 25; _C130Light setLightAmbient[0.0, 0.0, 0.0]; _C130Light setLightColor[0.2, 0.5, 0.3]; _C130Light lightAttachObject [C130, [0,0,0]]; Sleep 3; _C130Light lightDetachObject [C130, [0,0,0]]; deleteVehicle _C130Light; }
-
I have a static C-130 with a height of 5000 where I para down to the town/target but I can't seem to place any lights up there. I've tried the gamelogic way as I always have but I can't get any lights up there. :confused:
Gamelogic Way:
Game logic init:
light = "#lightpoint" createVehicleLocal position this; light setLightBrightness 0.2; light setLightAmbient[0.0, 0.0, 0.0]; light setLightColor[0.2, 0.5, 0.3]; light lightAttachObject [this, [2,1,2]]; this setPos [getPos this select 0, getPos this select 1, [color="Red"]5000[/color]];
Anyone help me out? If possible, it would be awesome if it was either green or red and it blinks. But if it's impossible to blink, that's ok. :rolleyes:
-
Tried a different method but I haven't tried it out yet.
Init.sqf
http://pastebin.jonasscholz.de/1620
3DText.sqf
-
From my Init.sqf:
execVM "Intro.sqf";
-
So I made a mission where I have this:
["<t size='.5'>[ <t color='#4E7906'>Weapons</t> | <t color='#2265BC'>Ammo</t> | <t color='#8A896A'>Backpacks</t> ]",position Ammobox,15,0] spawn bis_fnc_3Dcredits; ["<t size='.5'>[ <t color='#D10000'>Field</t> <t color='#BDDFB5'>Hospital</t> ]",position MedTent,15,0] spawn bis_fnc_3Dcredits; ["<t size='.5'>[ <t color='#808080'>SATCOM</t> ]",position UAV,15,0] spawn bis_fnc_3Dcredits; ["<t size='.5'>[ <t color='#4A4A31'>Heavy Equipment</t> ]",position HeavyEquip,15,0] spawn bis_fnc_3Dcredits;
In a script ".sqf". When I try my mission out in the editor, I can see it, but once I host a game, it doesn't show any no one can see the text.
Anyone help me out? :confused:
-
How would I add a sideChat feature to it so every time I kill someone, it plays a random sound AND the person who killed the enemy would say something like: "Tango Down" along with a sound file I have that says exactly that. I thought it would be simple to just put something like this:
waitUntil {!(isNil "bis_fnc_init")}; _responses = [["GotHim","Got Him!"],["Contact","Contact!"],["TangoDown","Tango Down!"],["BingoBingo","Bingo Bingo!"],["ThreatNeutralized","Threat Neutralized!"]]; _indx = floor random 3; playsound ((_responses select _indx) select 0); player sidechat ((_responses select _indx) select 1);
But everyone says the response (assuming they're an actual player). And if an AI kills an enemy, it will make me say the response. I just want the killer to say the response.
tl:dr: How would I be able to make the killer say the response but everyone else be able to hear the sound file?
-
How I do it:
Place an object (Sign) in game
Init: this addAction ["About..", "About.sqf"];
About.sqf
"This is the title" hintC [ "Paragraph 1 / line 1", "second", "3rd", "4th", "5th", "These are all seperated by bullets, btw." ]
Something like this:
This is the title
- Paragraph 1 / line 1
- second
- 3rd
- 4th
- 5th
- These are all seperated by bullets, btw.
- Paragraph 1 / line 1
-
Try this instead mate.....{_x addEventHandler ["killed", "([color="Red"]_this[/color]) execVM ""KillSoundTest.sqf"""]} forEach thisList;
EDIT: Actually I"m not sure that will work...but it's 3:30 am.... I'll catch ya tomorrow!
That worked to execute an .sqf but still can't figure out how to do the sideChat feature. =\ I got it to play a random sound but not the sideChat bit. :386:
-
Download the demo mission above...it's all there. It's the exact same code I'm going to give you anyway! Just replace my sound and text with your sound and text.Also...pay attention to how the script is being called (look in the East group leaders init). You seem to be calling an .sqs script. My scripts and all newer scripts are .sqf and called with execVM.
Stick with .sqf as it is newer, more efficient and better.
Aye, in my post it shows I'm using .sqf now instead of my previous .sqs.
But I'm trying to call this script with one single trigger to add all the OPFOR an event handler to have them call the script one they're killed. I don't want to put an execVM in all my OPFOR units in the mission. And all my units in my existing mission aren't in any group whatsoever. So I don't want to create a unique group for each unit in the mission because that'll be inefficient.
IE: foxmist1, foxmist1_1, foxmist1_2, foxmist1_3, foxmist1_4, foxmist1_ect..
Also, I've changed
{_x addEventHandler ["killed", "(_this select 1) [b]exec[/b] ""KillSoundTest.sqf"""]} forEach thisList
to
{_x addEventHandler ["killed", "(_this select 1) [b]execVM[/b] ""KillSoundTest.sqf"""]} forEach thisList
In the trigger On Act and ArmA doesn't really like that and doesn't even call in the script when it did before. :confused: Lol
Basically, all I'm trying to do is have this script have the ability to also do a sideChat feature as to the one you posted:
-
You still have some errors....You forgot the underscore in _responses.... and you didn't assign anything to _response1, _response2, _response3!
_response1 = "sound10";
_response2 = "sound11";
_response3 = "sound12";
But then...hang on a second!. You don't need _response1, _response2 and _response3 at all if you just use the actual sound itself.
_target = _this select 0; _killer = _this select 1; [color="SeaGreen"]_responses[/color] = [[[color="Red"]"sound10"[/color],"He's down"],[[color="Red"]"sound11"[/color],"Eliminated"],[[color="Red"]"sound12"[/color],"Target down"]]; _indx = 0; if (group _killer == foxmist1) then { _indx = floor random 3; playsound (_responses select _indx) select 0; _killer sidechat (_responses select _indx) select 1; };
EDIT: OK... I made a demo for you. Works sweet! There's another error that I missed above and that is... The Eventhandler passes an array [victim,killer] to your script.... so to get the killer and the victim you have to extract them from the passed array like this:-
[color="Red"]_array = _this select 0[/color]; _target =[color="Red"] _array[/color] select 0; _killer = [color="Red"]_array[/color] select 1;
I knew that all along but without testing I just did not see it.
I'm wondering on how I could implement a part of that script into mine.
I have something very similar set up to that, but I just want it to sideChat the responses to it and I don't know how.
Also, there won't be any groups involved.
My version:
KillSound.sqs
waitUntil {!(isNil "bis_fnc_init")}; _sound = ["GotHim","Contact","TangoDown","BingoBingo","ThreatNeutralized"] call bis_fnc_selectRandom; playSound _sound;
Trigger:
Axis A/B: 999999 Act: OPFOR (ONCE) Present Cond: True On Act: {_x addEventHandler ["killed", "(_this select 1) exec ""KillSound.sqs"""]} forEach thisList
I came up with this, it works by playing the sounds but it just doesn't do the sideChat bit.
My Attempt:
Trigger:
Axis A/B: 999999 Act: OPFOR (ONCE) Present Cond: True On Act: {_x addEventHandler ["KILLED", "(_this select 1) exec ""KillSoundTest.sqf"""]} forEach thisList
KillSoundTest.sqf
waitUntil {!(isNil "bis_fnc_init")}; _killer = player select 1; _responses = [["GotHim","Got Him!"],["Contact","Contact!"],["TangoDown","Tango Down!"],["BingoBingo","Bingo Bingo!"],["ThreatNeutralized","Threat Neutralized!"]]; _indx = floor random 3; playsound ((_responses select _indx) select 0); _killer sidechat ((_responses select _indx) select 1); exit
-
Easy fix for that:
Right Click Shortcut>Run>Maximized
It always fixed it for me. :)
-
The way I'm using it to place objects like that on my mission is as follows:
Castle.sqf
if(isServer)then{ // Castle _castle = "Land_A_Castle_Bergfrit" createVehicle (position castle); // Stairs _stairs = "Land_A_Castle_Stairs_A" createVehicle (position stairs); // Walls _castlewall = "Land_A_Castle_Wall2_30" createVehicle (position castlewall); _castlewall2 = "Land_A_Castle_Wall2_End" createVehicle (position castlewall2); };
With a Game logic named castle, stairs, castlewall, castlewall2 in the map to tell it where I want them.
I just don't know how to rotate them. >_<
-
Mission Init:
strobeOn = player addAction ["MS-2000 On","strobeStart.sqf"];
strobeStart.sqf: (Working Now)
// strobeStart.sqf // By Semedar // Player Init: unit addAction ["MS-2000 On", "strobeStart.sqf"]; player removeAction strobeOn; Sleep 0.1; strobeOff = player addAction ["MS-2000 Off", "strobeStop.sqf"]; strobe = true; while { strobe } do { _irstrobe = "NVG_TargetC" createVehicle getpos player; _irstrobe attachTo [player,[0,0,0.2],"neck"]; Sleep 0.8; detach _irstrobe; deleteVehicle _irstrobe; Sleep 0.1; }; WaitUntil{not isNull player}; player addEventHandler ["killed", {strobe = false}];
strobeStop.sqf: (Working Now)
// strobeStop.sqf // By Semedar // Player Init: unit addAction ["MS-2000 Off", "strobeStop.sqf"]; player removeAction strobeOff; Sleep 0.1; strobeOn = player addaction ["MS-2000 On","strobeStart.sqf"]; strobe = false; detach _irstrobe; _irstrobe setPosATL [-10000,-10000,100000]; deleteVehicle _irstrobe;
Edit: Fixed :D Reason being the actions were local Edited the script I posted in case someone wants to use it. :D
-
you need to detach it first I guessHah, it was that simple, huh? :D
It worked, though! :D
while { true } do { _irstrobeplayer = "IRStrobe" createVehicle getPos player; _irstrobeplayer attachTo [player,[0,0,1],""]; Sleep 15; detach _irstrobeplayer; _irstrobeplayer setPosATL [-10000,-10000,100000]; Sleep 0.1; deleteVehicle _irstrobeplayer; Sleep 0.1; };
Question now, though:
- How would I be able to start/stop this script via Action Menu
- How to stop it when the player dies
---------- Post added at 03:01 AM ---------- Previous post was at 02:26 AM ----------
Would something like this work?
// Strobe2.sqf // By Semedar // Player Init: p1 addAction [("<t color=""#FFFFFF"">" + ("Strobe") +"</t>"), "Strobe2.sqf"]; strobe = true; while { strobe } do { _irstrobeplayer = "IRStrobe" createVehicle getPos player; _irstrobeplayer attachTo [player,[0,0,2],""]; Sleep 14.8; detach _irstrobeplayer; _irstrobeplayer setPosATL [-10000,-10000,100000]; Sleep 0.1; deleteVehicle _irstrobeplayer; Sleep 0.1; }; WaitUntil{not isNull player}; player addEventHandler ["killed", {strobe = false}];
- How would I be able to start/stop this script via Action Menu
-
setPos it to [-10000,-10000,100000] before you delete itWon't work either. :(
while { true } do { _irstrobeplayer = "IRStrobe" createVehicle getPos player; _irstrobeplayer attachTo [player,[0,0,2],""]; Sleep 10; [b]_irstrobeplayer setPosATL [-10000,-10000,100000];[/b] deleteVehicle _irstrobeplayer; };
My test mission:
-
Would it be an easy fix for #13742: IR Strobe flashing lights remain after deletion?
I was trying to make a script where you can have an IR Strobe follow you so allies can see your position at night.
-
I'd recommend the "Lite" version myself so other people don't have to download the editor update just to play your mission. I don't like making things inconvenient. Only thing is though that I don't think the "Lite" version has vegetation.
-
If you're using UPSMON, there's an option to enable the AI to place mines if there is an enemy vehicle nearby.
Init_UPSMON.sqf
//Enables or disables AI to put mines if armoured enemies near (use ambush2 if needed) KRON_UPS_useMines = false;
-
-
Hi,if attachTo doesn't work, you can use this alternative:
stroboDrop = false; _irstrobe = "IR_Strobe_Marker" createVehicle (getPos player); while {!stroboDrop} do { _irstrobe setpos [(getPos player select 0), (getPos player select 1), 1]; _irstrobe setDir (getDir player); sleep 0.01; }; _irstrobe setpos [(getPos player select 0), (getPos player select 1), 0];
This way, to drop the strobo, you just have to set stroboDrop to true.
stroboDrop = true;
Then you can call it again, and so on.
Tried yours but it just makes the strobe spawn and stay on the ground. :(
I think we're going to have to send a bug report because I don't think we can move/delete/mess around with an IR Strobe once it's been "deployed". As in the model disappears and all it leaves behind is the strobe light.
-
This is what I have so far. It works, but when you start to run, the strobe eventually detaches from the character and is stuck on the ground.
//Strobe.sqf //By Semedar //Player Init: p1 addAction [("<t color=""#FFFFFF"">" + ("Strobe") +"</t>"), "Scripts\Player\Strobe.sqf"]; while { true } do { _irstrobe = "IR_Strobe_Marker" createVehicle getPos player; _irstrobe attachTo [player,[0,0,1],""]; Sleep 5; deleteVehicle _irstrobe; };
Edit: I found out it detaches when the model disappears but the strobe is still on. Anyone know how to make the strobe light follow the character?
Edit 2: I also found out that the IR Strobe model disappears somewhere around 13-15 seconds. So maybe having it delete the IR Strobe and then creating a new one every 12-13 seconds?
Another Edit: I can't seem to delete the IR Strobe that I created via createVehicle with deleteVehicle. Anyone help me here?
-
Is there a way to addAction a player that will create an IR Stobe and attach it to said player?
My goal: Player is in thick woods at night while buddy is flying overhead with a littlebird but doesnt want to kill me. So I scroll my action menu and select "Turn IR On" and an IR Strobe follows me everywhere I go until I die.
This is the closest I found but it's for ACE, which I don't want to use:
http://ace.dev-heaven.net/wagn/IR_Strobes+notes
Something like this perhaps? Just an idea. :rolleyes:
Player Init
p1 addAction [("<t color=""#EEEE00"">" + ("Turn IR On") +"</t>"), "Scripts\IR_Strobe.sqf"];
IR_Strobe.sqf
_irstrobe = "ACE_IRStrobe_Object" createVehicle getPos p1; _irstrobe attachTo[p1,[0,0,0],""]; ["ace_sys_irstrobe_aradd", [_irstrobe]] call CBA_fnc_globalEvent;
-
I've seen Domination maps with this feature but I can't figure out how they did this. Can anyone tell me how to implement this into my mission? :D
UH60M_MEV_EP1 Missing in editor
in ARMA 2 & OA : ADDONS - Configs & Scripting
Posted
Can anyone tell me why "UH60M_MEV_EP1" isn't in the editor?
http://community.bistudio.com/wiki/UH60
I want to add it in my mission when I find out it's not there. :confused:
I'm running ArmA 2 in CO mode and also tried running just OA.