Jump to content

demonized

Member
  • Content Count

    2658
  • Joined

  • Last visited

  • Medals

Everything posted by demonized

  1. Thank you for that info CarlGustaffa. That explained alot, and after a look at that bis link i got a better understanding of the concept EH as well now. Tomorrow i will make the changes needed to add light from server script, if all goes well i should be able to make client side as well, just for the practice :) I know im kindof inventing the wheel allover again, but this is the way i learn it. Im abit exited, all those EH opens up a whole lot of uses that i wasnt familiar with :) Time to hit the sack, have a good night.
  2. for now in my missions i use the m4_CCO_EP1 or something, it has flashlight and effects is very nice, they only activate lights when in combat mode, vry cool, just wish BIS, gave us ak version with lights, or even a handheld torch or something. even a head torch, would be nice.. Tnx guys for your replys, if anyone else have any info regarding flashlights without use of addons, or maybe a very nice standalone addon, post here please.
  3. Ive looked through all the forum posts containing flashlights. Are there still no way to script a flashlight for a soldier using ak rifle? Is there any way to equip enemy AI with M4A3_CCO_EP1 wich have a flashlight and script it someway so that to the player it looks like an AK-74 and sounds like AK-74? doesnt neccesarily have to behave like AK-74 trajectory etc.. , i would be satisfied with looks and sounds, even only sounds would be better than nothing.. Any bright ideas?
  4. checking out your link now. What i meant in previous post was: From where or how do you call the "server" script that creates a light for the ai on the projectile"the flare"? This from above scripts confuses me... _projectile = _this select 6; //_this expanded removed, now uses internal projectile support. when its not being used or is it?? basically i wanted to know how to get the unit or name of: (flare shot aka the projectile) for then to create a light source on for the AI to spot enemy players due to more light, from the flare. I am far from a good scripter, i usually learn by copying and modifying or looking at others scripts. Your scripts posted above may be just to much for me to understand atm. Edit: i see you use a firedeventhandler to launch the create light on projectile script, is that correct? Never messed with evenhandlers before, time to research again. :)
  5. wow that was alot of info CarlGustaffa :) Any chance i dont have to pick your scripts apart to find the create light on flare shot part?? Maybe an example script of how to attach light to my AI launched flare? I understand the script, im just not seeing what you _this select 0; from to get projectile in the server script....?? I think that server script is only thing i need to compliment my own script with actual light for ai... right? In testing of my own script i didnt actually notice AI being blind even with flare, tho my test subject was this setDammage false; and once bluefor ai with NVG spotted him they shot, him and he launched flare, and started to kill them all, then launched next flare if anyone still left, and so on.. If i understand correctly: My players in COOP using NVG´s approaching enemy, enemy doesnt see them, and is on aware mode, players shoot at enemy, enemy switches to combat mode and launches flare, and starts shooting at any player that is shooting, wich probably is all of them by this point, enemy sees players because of their shooting and not flare itself?? flare is only eyecandy for players?? That seems like a silly thing for BIS to still have ingame.. Edit: i am trying to look at a while loop and integrate all flare AIs into an array in same script, but im getting nowhere with that, my problem is the while loop stops or never starts.. so its kindof on the shelf for now, still learning. Edit2: Man i feel stupid, my while loops didnt work because of while () do { instead of the correct while {} do { I have finished my script with while do, but with all the help lines in it its now 0.10kb bigger than my original script lol. Script has countermeasure to prevent multiple ais spamming nightsky with flares. Also have incorporated an ambush or attack on sight option. I have updated my first post at beginning of thread with script. ---------- Post added at 05:26 PM ---------- Previous post was at 03:29 PM ---------- Script fully working and updated with combat, ambush option as well as AI spam sky with flares prevention, and check if ai in vehicle then dont shoot.
  6. demonized

    Revive Script

    how about never let player have item on his body?? when player approaches item and uses action to collect it, simply start a script that will setPos it far away or delete it, and have a loop checking player pos and if player dead or if player reached destination, if dead setpos item to last know position, maybe loop at every 1 second or faster... Now when dead player looses item apparently on ground next to him, and anyone can pick it up and restart the script with their name on it, also maybe when you pickupscript, you activate a loop for if player dead activate action search body, etc.... and item will never be on ground but any hostile or friend need to search player body for it.. ofc need to set players dead body timers to be somethiing that would work with that.. otherwise, respawn and cheating is very easy.. Just spitballing, hope you get something usable from this.:)
  7. Edit: reason why lights dont work when in flight seems to be that they are created in horisontal plane of chinook, and remains that way, even when chinook is tilted forward backward to gain speed, look under spoiler for more info. No offence kylania, your light was way to strong, and your version still make people black as they were in the dark same as shk version, and furthermore the chinook have much more light on the outside. I can see the rear gunner lit up by inside redlight when im on the outside. as well as the chinook itself is a big red torch in the dark. And when using setLightAmbient all AI enemy that you pass over will see that big red ball of chinook. My graphic settings are not high, mostly normal and low, unsure if that can have anything to do with it, tho i doubt it. ALso have done alot of different tests/approaches within my knowledge and its under this spoiler
  8. 1:yes you can magically just create flares in the air, with a nearestenemy or list of detected side in trigger, however afaik you cannot make a flare being shot in the air without having someone to actually fire it. but for just creating a flare would make the script a just few lines, but not seem so realistic, as my aim was to have the AI himself shoot the flare, maybe you dont even need a script, everything may possibly be done from a trigger. 2:im not familiar with how to get direction to an enemy, thoug i suspect its something like getdir setdir x,y axis sumthing sumthing. 3: i thought that was what i did, unfortunately im not very familiar with while do..Edit: added second test of while do in first post bottom.
  9. demonized

    Revive Script

    Maybe the setCapture messes with the moveInCArgo command. try without it.. Edit: tested, i assigned copilot and radar guy and pilot and used moveinCArgo on myself in a radio trigger, i ended up in the back of the c130 as expected, test was done in editor with me bluefor, c130 crew bluefor, and no other scripts running, no revive active etc... Have you renamed the c130 and forgot to change in respawn markers trigger code?
  10. One small issue is that when i have lights on inside chinook, all characters are dark, not lit up by lights as if they were still in complete darkness. Its a cosmetic thing, no big deal. But flares fired outside chinook lights up soldiers, but inside lights is like they give off no light source.
  11. Will try with hideobject tonight, also came to think off i have used gamelogic to activate lights in trucks, maybe i can assign a gamelogic the m4 flashlight version, then hide or attach to or merge it somehow to a ak-74 soldier.... Is there a way to name a weapon given to a unit? weapon = unit selectweapon "weapon_classname"; ?? Ive in the past seen hackers have rifles with javelin missiles on full auto etc... surely there must be a way, to either acomplish ak-74 flashlight, or unit flashlight by script, or somewhat simulate it, either switchable on/off or always on.
  12. yeah i was thinking of using searchlight with attachto, but its to big and clunky, also the light beam is way to big and strong for a flashlight. Maybe there is a way to take out the light source of the searchlight or one of the cars beams, and resize it down to fit flashlight size. then just attachto weapon, head(or helmet) or arm of unit....? Ive seen lights created but i think they are only in shape of globe and not cone wich is needed for flashlight.
  13. demonized

    Revive Script

    C130 cargo seats is nr 2 to nr 24.
  14. Look at this one, basically you place all your squads as normal in your editor, then when game starts it will save all units down to only 1 member and when player within any range you specify it will spawn full group back on leader, i myself use them to spawn in at 2500 from player when playing infantery role, you can ofcourse set it to less or more. http://www.armaholic.com/page.php?id=10102&highlight=CACHE+UNITS
  15. demonized

    Revive Script

    quick and dirty way: Now when player dies it should get only 1 respawn dialog named C130, when clicked player will respawn to the marker and be blind for 10 seconds, while player is blind, trigger over marker will move player into c130 as passenger. you can ofcourse add base and other respawn points by setting amount of respawn points and several markers as in top of this post. Edit1: It doesnt matter Edit2:
  16. demonized

    SQF revive script

    Just search in revive_init.sqf for this NORRN_player_units = [s1,s2,s3,s4]; S1 is name of unit in editor, name is in name (to the right under special, not in description, description only shows up in MP lobby where you choose what unit to play, you can rename s1 to whatever, and add or remove as many as you want. You can also make it easy with making all units you wish to have revive playable and replace line with this. NORRN_player_units = playableUnits; In can revive use "soldierWB" then all west units can revive _can_revive = "soldierWB"; //array no.18 Edit: Reading the instructions, aka readme, is very helpful for many issues ;)
  17. demonized

    Revive Script

    great!!:) Tnx for reply Norrin. for various classes, and superclasses as Norrin described in above post i use this site: http://browser.dev-heaven.net/cfg_vehicles/classlist?version=23
  18. At this moment ive decided to stay with UPSMON instead of DAC. UPSMON have no or very little impact on my fps, even when lots of AI is active, this goes same to DAC, but i personally like better the functionality of UPSMON combined with spawning random groups like fatty86 descried in post above. The reinforcement parameter especially is great feature with UPSMON imo. Ive been a personal fan of ups since arma1 and now upsmon. As stated in UPSMON thread, upsmon will never use more cpu than allowed by the game, thus preventing lag because of big load, only thing i noticed is that when my computer cant keep up with 100 upsmon squads starting at same time, it simply takes longer to get all groups assigned to upsmon in realtime, you can see this by activating debug in upsmoninit. Got the idea of caching units from DMarkwick´s post about DAC, so i use this http://www.armaholic.com/page.php?id=10102&highlight=CACHE+UNITS and it works really well. Also combining UPSMON and Zeus AI gives great results in ways of firefight and more belivable enemys. http://www.armaholic.com/page.php?id=8250&highlight=ZEUS And finally here is the link to UPSMON incase anyone is interested. http://www.armaholic.com/page.php?id=9213&highlight=UPSMON A big thank you goes to fatty86 and DMarkwick for your help and tips. Regards
  19. I want to use a script to create a random sized group with random units from an array or predefined list. Goal is to have various quarters of city(preplaced markers) to get populated by enemy and players must move through these areas. Its intended for COOP multiplayer. I cannot for the life of me get my head around :banghead:how to make random sized groups, or even use random unit in createUnit command. 1: How can i make an array with classnames and then call a random number, lets say 1 - 10 for this purpose? 2: How can i create a random unit from said list or array in a marker pos? 3: I assume getting group to use upsmon script as described in my script exampleunit 3-6 below works, if not, how to use either leader init line or group id to call upsmon? 4: Idea was to have one script for multiple group creations at different times, since upsmon changes grpname when activated and after they go on their patrol grpname in script is empty again for use. Is local variabels even usable on deicated server for this purpose _grpname? Or do i need to use grpname without lead underscore? Any help will be much appreciated, im a mediocre or less scripter, but use other scripts, and parts of others and have a pretty ok understanding of how things works, especially with org authors helpful hints in scripts //this is how why and what because This is what i have in my script after alot of trying and failing through various forum searches and script stealing. // if (!isServer) exitWith {}; //is the [color="Red"],[/color] in correct place in array? is it ("classname[color="Red"]", "[/color]classname") or ("classname[color="Red"]","[/color]classname")? //define array of class name for militia _NNDL_unitTypesMilitia = ["TK_INS_Soldier_AA_EP1", "TK_INS_Soldier_AR_EP1", "TK_INS_Bonesetter_EP1", "TK_INS_Soldier_MG_EP1", "TK_INS_Soldier_2_EP1", "TK_INS_Soldier_EP1", "TK_INS_Soldier_4_EP1", "TK_INS_Soldier_3_EP1", "TK_INS_Soldier_AAT_EP1", "TK_INS_Soldier_AT_EP1", "TK_INS_Soldier_Sniper_EP1", "TK_INS_Soldier_TL_EP1", "TK_INS_Warlord_EP1"]; //count array taki Militia //_cnt = count _NNDL_unitTypesMilitia; _NNDL_randomman = _NNDL_unitTypesMilitia select (floor(random (count _NNDL_unitTypesMilitia))); hint "ok1" //assign spawn group _nnAogrp = createGroup east; //spawn group //option1? _unit1 = "_NNDL_randomman" createUnit [getMarkerPos "spawnhill", _nnAogrp, "_nnAogrp=This",0.5,"Sergeant"]; //option2? _unit1 = " _NNDL_randomman" createUnit [getMarkerPos "spawnhill", _nnAogrp, "_nnAogrp=This",0.5,"Sergeant"]; //option3? _unit1 = "_NNDL_unitTypesMilitia select (floor(random (count _NNDL_unitTypesMilitia)))" createUnit [getMarkerPos "spawnhill", _nnAogrp, "_nnAogrp=This",0.5,"Sergeant"]; _unit2 = "whatever option works" createUnit [getMarkerPos "spawnhill", _nnAogrp, "",0.4,"Corporal"]; [color="Lime"]//below method with unit3 - 6 works fine but no random unit.[/color] //_unit3 = "TK_INS_Soldier_AT_EP1" createUnit [getMarkerPos "spawnhill", _nnAogrp, "",0.4,"Private"]; //_unit4 = "TK_INS_Soldier_3_EP1" createUnit [getMarkerPos "spawnhill", _nnAogrp, "",0.4,"Private"]; //_unit5 = "TK_INS_Soldier_AR_EP1" createUnit [getMarkerPos "spawnhill", _nnAogrp, "",0.4,"Private"]; //_unit6 = "TK_INS_Soldier_EP1" createUnit [getMarkerPos "spawnhill", _nnAogrp, "",0.4,"Private"]; //set their skill sleep 0.5; {_x setSkill 0.6 + (random 0.4)} forEach Units Group _nnAogrp; //start random placement and patrol need "spawned" in call line for units by create unit command //sleep 3; nul=[_nnAogrp,"NNDL_ao","spawned","RANDOMDN","reinforcement"] execvm "scripts\UPSMON.sqf"; hint "end of scripts" //END
  20. demonized

    Revive Script

    in my coop mission i have checks within mission, if player named s1 and s2 is in lb1, then eject them. This works well when i test mission. question 1: what happens if s1 and s2 dies and gets revived prior to this check? Is s1 and s2 still named s1 and s2 after they have been revived? question 2: is it possible to define several units to can revive. like baf medic only + us medic only + all special forces units + teamleader us + sectionleader baf? will this work?: _can_revive = "BAF_Soldier_Medic_MTP","US_Delta_Force_Medic_EP1","US_Soldier_Spotter_EP1","US_Soldier_SniperH_EP1","BAF_Soldier_TL_MTP","US_Soldier_TL_EP1"; and rest will not be able to revive. ---------- Post added at 04:01 PM ---------- Previous post was at 03:31 PM ---------- [/color]
  21. still very nice, thank you very much for setting it up for me.. Edit: That was truly sweet!!! just what i was looking for, the outside view of it is very minimal, and as its for ambience on a coop mission, this was spot on.
  22. That sounds doable, how? Edit, found this forum post when searched for lightsource, will experiment.. http://www.armaholic.com/forums.php?m=posts&q=7490
  23. demonized

    Revive Script

    thank you Norrin for this great script, MP wouldnt be the same without it.
×