Jump to content

za0

Member
  • Content Count

    37
  • Joined

  • Last visited

  • Medals

Everything posted by za0

  1. Friends, I come to you again, great sages of Arma 3 codes to perhaps solve my current problem... This problem is as follows, I want a static object in my scenario to be destroyed if it takes any instance of damage. The object in question is "Land_PortableServer_01_olive_F". In the init field I tried to put a code that works perfectly on the units: this addEventHandler ["HandleDamage",{ _this spawn { if (_this select 2 > 0) then { _this select 0 setDamage 1; }; }}]; As I said, in units this code works. If I shoot the unit in the foot that has this code in its init, it will be immediate death. But as in the current case the code is in a static object, it doesn't work. I've already tried shooting all the bullets from my gun on this portable server, hand grenades, RPG, tank artillery... nothing happens xD I did a test to see if it is possible for this object to be destroyed by activating a trigger with the code: hard setDamage 1; Oh, the name of the object is "hard" by the way, because of hardware. And another trigger with the condition: !alive hard; Upon activation: hint "It worked"; And it worked... my test. But I wanted this object to be destroyed if it was hit by something, like the code there that works with the units as I explained. If that were possible, I could create a bad ending for the sci-fi mission I'm creating. Thank you in advance for your time!
  2. I read about HitPart EH, and tried to implement it in my game but I was unsuccessful. I even tried asking GPT chat to help me but it still didn't work. Here is an example of code that didn't work: this addEventHandler ["HitPart", { _target = _this select 0; if (typeName _target isEqualTo "Land_PortableServer_01_olive_F" && {alive _target}) then { _target setDamage 1; }; }]; It was worth a try, thanks for the idea anyway.
  3. i'm creating a mission in eden editor and i put a 500m trigger that when the blufor player gets to him, some mortar shots fall around. in this trigger I also added the "battlefield explosions" sound effect. the problem is that this sound effect is in a loop, but in the selection of it in the attributes of the trigger it lasts only about 5 seconds. how do I make the sound effect last just this long and not stay in a loop?
  4. So I put this code in the initialization field of a trigger: private _posATL = player modelToWorld [0,10,0]; private _ps1 = "#particlesource" createVehicleLocal _posATL; _ps1 setParticleParams [ "\A3\Data_F\ParticleEffects\Pstone\Pstone", "", "SpaceObject", 1, 10, [0, 0, 30], [0, 0, -2], 1, 10, 1, 0.2, [2, 2], [[1, 1, 1 ,1]], [0, 1], 1, 0, "", "", _ps1]; _ps1 setParticleRandom [0, [10, 10, 0], [0.25, 0.25, 0], 0, 1.5, [0, 0, 0, 0], 0, 0]; _ps1 setDropInterval 0.04; And the particle effect works. I got this code from the BI website at this link https://community.bistudio.com/wiki/Particles_Tutorial that talks about particles: More specifically, it's rock shower code. But here's the problem: I can't delete the effect, either the rock shower or any other effect. When the trigger activates, the effect starts, but I don't know how to stop it. I already tried deleting the trigger, and using the example that says on the site mentioned above deleteVehicle _ps1; But nothing.. Any ideas? Thanks in advance!
  5. Hey! It worked! Thank you Harzach! I don't understand much about programming but I'm learning little by little. So that initial code that I had tested was in local scope and what you did was pass it to global using 0 = [] spawn { }; ?
  6. za0

    DLC's Lightning

    Well... when Im testing my missions in multiplayer mode, some times some things strange happens: A lightning strikes the ground with a bang and several dlcs icons scatter around it. I've also seen an event where a cloud of flyers falls from the sky. What is this???? I didn't do anything for this to happen! :l This is very annoying because in addition to the lag that this causes, immersion is also greatly impaired. Note: I have the dlcs.
  7. za0

    Timer on Items

    You know that round timer that appears when you revive an ally, repair a vehicle or defuse a bomb? How do I add it to any item I want, and trigger a trigger when the timer circle completes? And if possible, how can I change the time to my liking, like 30 seconds or 60 seconds?
  8. za0

    Timer on Items

    After some time I figured out! I was looking for BIS_fnc_holdActionAdd https://community.bistudio.com/wiki/BIS_fnc_holdActionAdd 🙂
  9. I'm using Ace mod and there is that plasma sack with the id as follow: ACE_plasmaIV_250 Well, I'm trying to remove it from my inventory when I reach the trigger area with the command : this removeItem ACE_plasmaIV_250; ...but nothing happens I've also tried use: this removeItemFromBackpack ACE_plasmaIV_250; with the item in my backpack but still nothing happens... :l Any idea? tks in advance!
  10. za0

    DLC's Lightning

    Hi guys, I'm back! So, I tested the game yesterday. I opened a server and tested my mission by playing alone (on a server, but alone). The server was LAN. I'm also not using any Zeus modules in my scenario. After about 15 minutes, these events started: lightning strikes very brightly, followed by lots of DLC icon particles. These lightning strikes continue to happen every 4 or 5 minutes. I took a screenshot, but the lightning itself didn't show up because of the delay in printing, but you can see the DLC particles that are followed by the lightning. https://justpaste.it/99fwi
  11. I know that script "setFriend" : https://community.bistudio.com/wiki/setFriend I didn't test but in this link says: "west setFriend [west, 0]; // free for all deathmatch! works with west/blufor, east/opfor, independent/resistance and civilian" Try to group two units. So maybe you could use this and see if the units attack each other even they are in the same group.
  12. za0

    DLC's Lightning

    Its a LAN server that I create through zerotier for just friends... I wanted to test some things, maybe take a print to show you guys but I can't in the next days because I got pneumonia. Anyway, when I get better I will return to the game and test the server alone and also not use the Zeus Dlc, keeping you informed. Thank you in advance guys, for the willing to help me!
  13. za0

    DLC's Lightning

    Yes I am with zeus dlc activated... I didnt think about it, I gonna test without this dlc because I don't even use it... The server is lan btw.
  14. Hey! First of all I'd like to say this mod is awesome! I have an idea to create a medieval rpg scenario but I would need to know 3 things about this mod: 1- is it possible to change (increase) the hp of a unit (player)? How? 2- is it possible to change (increase) the stamina of a unit (player)? How? 3- Is it possible to make the hp and stamina bar visible even with the weapon stored? How?
  15. za0

    Moving objects with trigger

    Tks bro! Helped a lot!
  16. Is there a way to move an object with trigger? For example, I want an object to change its coordinates when a trigger is activated. And in this trigger will be the coordinates where this object will be moved.
  17. za0

    Variable

    I have 10 units. Their variable names are: s1, s2, s3, s4, s5, s6, s7, s8, s9, s10. I want to make all of them be in just one name. How do I set this variable?
  18. za0

    Variable

    tks bro
  19. Well, how can I make a trigger be activated when a whole group is dead? I found this in another topic with the same question but it didn't work for me : {alive _x} count units (groupname) == 0 tks in advance!
  20. well, i'm trying to create a ww2 scenery with parachute jump. And for that I'm using the IFA3_LIB mod. The C-47s from there have the normal sitting position and also the standing up position which is when you are about to jump. I wanted to make the player not have to worry about clicking anything when jumping, so I got this script so that the jump could be done alone: Now an important detail, this script works perfectly when the plane's crew is seated (in game they appear as: crew) But before the jump takes place/the above script runs, I put in another script that makes the entire crew that was seated to stand up, and therefore be in the standing up position. In this case, when the plane reaches the trigger with the jump script, everyone standing inside the plane is still inside the plane... :l I believe maybe that's why: since when they are standing they are apparently no longer considered "crew". But I don't know, I don't know much about scripts, I was wondering if there is another variety to use in forEach other than "crew" that works for this case... An example of all units jumping out of the plane except the pilot would work but I don't know how to do it. Challenge launched! xD Thanks in advance guys!
  21. za0

    Remove Item from Inventory

    tks guys, for everything
  22. za0

    Remove Item from Inventory

    It worked! The problem was the quotes. I'm creating for a multiplayer 🙂 Each character will have a different variable name so these scripts will also have their names to work correctly. But I'm with another problem here... this script works but it only removes 1 item from the inventory... Is there a way to remove multiple items, like 5 plasma sacks at once?
  23. Well... I'm creating a mission using ACRE2 but I didn't let the characters have any radio at the beginning. So I edited their equipment and none of them have any radio. But when I test, everybody has an AN/PRC-343 in inventory. They automatically start with it. Is there a way to disable this automatic appearance of radio in the inventory? Tks in advance guys!
  24. Well... I'm creating a mission using ACRE2 but I didn't let the characters have any radio at the beginning. So I edited their equipment and none of them have any radio. But when I test, everybody has an AN/PRC-343 in inventory. They automatically start with it. Is there a way to disable this automatic appearance of radio in the inventory? Tks in advance guys!
  25. Hi. I wanted to add by script through a trigger with area the parade uniform of dlc art of war whose id is U_O_ParadeUniform_01_CSAT_F I wrote the following in the trigger activation field: (unitname) addUniform "U_O_ParadeUniform_01_CSAT_F"; But when I go to the trigger area, nothing happens. I managed to add the cap by writing in the trigger's add field: (unitname) addheadgear "H_ParadeDressCap_01_CSAT_F"; I don't have the dlc art of war. If that's the problem, then why am I able to add the cap but not the uniform? tks in advance!
×