cfrag Posted May 8, 2023 Author Posted May 8, 2023 (edited) 16 minutes ago, shinobi61 said: The simple ones in the example missions not so bad but easily confused with more complex flag 'linking' DML by default uses flags to connect modules (for example a radioMenu tells a cloner to clone). In those cases, you usually only need the flag name, because DML triggers actions when the value of a flag changes. You can configure this to trigger only on certain values, but those are only required for advanced uses. Normally, all you need to do is use the same flag name to connect an output (the "!" bang attribute) to an input attribute (the "?" listen attribute) Edited May 8, 2023 by cfrag
mimamema Posted May 8, 2023 Posted May 8, 2023 (edited) 13 hours ago, cfrag said: That's a very helpful function that currently can't be assembled easily in DML. Let me see if I can come up with a module that does this. Well, you were quite fast creating it as far as I can see, awesome time response! Thank you so much 13 hours ago, cfrag said: Tasking in DCS is IMHO such a mess that I'm trying to avoid sinking effort into this. A (passable) work-around exists: use a clone zone with template groups that have task orders (CAP, Strike, SEAD etc.). That way tasking is pushed outside of DML's context, and you still have the ability to spawn tasked groups on demand. Yes, I thought so, it would be a very important module for DML so there must be a reason not to develop it. 13 hours ago, cfrag said: That's a good suggestion, and I would like some more specifics about what may be of interest. Can you give me a hint which flag subject to focus on, assuming that people have watched the flag tutorials T020 We did start the fire and T030 Spawning on demand. As Shinobi61 said before there are some complex ways to use flags that you are aware of that probably I cannot even imagine at the moment. Right now I´m stuck with the CAP thing as I want it to fire a "next" in the sequencer of my enemy CAP whenever the number of players in a zone is 6 or more at least for 5 minutes. After reading "changer", "xFlags", "countdown", "pulse"?.... I´m getting mad at the moment and not getting to a solution for this xD. I noticed that playerZone can give the value of players in the zone or fire flags every time a player comes in and come out. So my first question is, can I use the whole value ( maybe 5 players in the area given by "pNum") to be the input of any other module that can help with this? Sorry I´ve been reading your whole documentation in just 2 days and I still have to understand some concepts . Edited May 8, 2023 by mimamema
cfrag Posted May 8, 2023 Author Posted May 8, 2023 (edited) 1 hour ago, mimamema said: So my first question is, can I use the whole value ( maybe 5 players in the area given by "pNum") to be the input of any other module that can help with this? Indeed, and that would be one of the advanced uses for flags. You can set up the 'trigger methods' for inputs. By default, they are 'change', meaning the input triggers whenever the value of the flag that is mentioned as input changes. When 'change' is the method, it doesn't matter what the new flag value is, as long as it's different from that last time the module checked (modules check usually once every second). Now, DML supports other trigger methods. And one such method is ">4" -- greater than (number 4). If you use the output pNum (which is always set to the number of players) and feed that into an input with a method of ">4", that triggers that input when there are 5 or more planes in the zone. With that in mind, if you have the time, perhaps revisit chapter 4.2.3 Flags in the "shock block". Edited May 8, 2023 by cfrag
mimamema Posted May 9, 2023 Posted May 9, 2023 (edited) 14 hours ago, cfrag said: Indeed, and that would be one of the advanced uses for flags. You can set up the 'trigger methods' for inputs. By default, they are 'change', meaning the input triggers whenever the value of the flag that is mentioned as input changes. When 'change' is the method, it doesn't matter what the new flag value is, as long as it's different from that last time the module checked (modules check usually once every second). Now, DML supports other trigger methods. And one such method is ">4" -- greater than (number 4). If you use the output pNum (which is always set to the number of players) and feed that into an input with a method of ">4", that triggers that input when there are 5 or more planes in the zone. With that in mind, if you have the time, perhaps revisit chapter 4.2.3 Flags in the "shock block". hehe, yes, I was exactly there when you write it but I couldn´t test it more till later. I managed to make this trigger method work but only creating a group tracker, as if I use the debugger to set the pNum to 5 it changes momentarily and then came back to 0. Then using unitsNum I managed to make it work as they were actually tracking a group of units, but the trigger was continuous so I ended up stopping the mission before the mission crashed . I´m rethinking the mechanics of this process at the moment but getting to know better how everything works. This all has a lot of potential and it´s like playing another game . Edited: would "pNum -2" work as a variable to make a flag bang? That way I could make a tracker that stops the cloning every time that variable is reached, I don´t if it is useful really for the mechanics that I´m thinking of but I´m curious now. Edited May 9, 2023 by mimamema
cfrag Posted May 9, 2023 Author Posted May 9, 2023 (edited) 6 hours ago, mimamema said: would "pNum -2" work as a variable to make a flag bang? In general, I would not use blanks nor hypens ("-") in a flag name, but as long as you don't include a comma (",") it should work. Unless, of course, that "-2" has a special meaning for you (i.e. that you assume that "pNum -2" would always deduct the integer two from the value of what is stored in flag "pNum". So, if your question is literally "would the name 'pNum -2' be a legal flag name", the answer is yes. By itself, that name does not imply any algorithmic process happening, nor any connection to an attribute that may happen to be named 'pNum' on a DML module's instance. Phrased differently: I'm not entirely sure what you think a flag name like "pNum -2" would implicitly do for you. Maybe it helps if you put into words what you want to accomplish, and how you expect such a flag name would help. I'm sure that we can then quickly resolve this. Remember: although using flags will become natural after a few uses, they are alien to the way we normally think, and we tend to assume that flags are way smarter and do a lot more than they actually are or do. Flags are dumb. DML tries to hide this as best it can, but can only go so far Maybe take a screenshot of the two trigger zone attributes that you are connecting with a flag, and explain what you want to accomplish. Edited May 9, 2023 by cfrag
mimamema Posted May 9, 2023 Posted May 9, 2023 (edited) 4 hours ago, cfrag said: In general, I would not use blanks nor hypens ("-") in a flag name, but as long as you don't include a comma (",") it should work. Unless, of course, that "-2" has a special meaning for you (i.e. that you assume that "pNum -2" would always deduct the integer two from the value of what is stored in flag "pNum". So, if your question is literally "would the name 'pNum -2' be a legal flag name", the answer is yes. By itself, that name does not imply any algorithmic process happening, nor any connection to an attribute that may happen to be named 'pNum' on a DML module's instance. Phrased differently: I'm not entirely sure what you think a flag name like "pNum -2" would implicitly do for you. Maybe it helps if you put into words what you want to accomplish, and how you expect such a flag name would help. I'm sure that we can then quickly resolve this. Remember: although using flags will become natural after a few uses, they are alien to the way we normally think, and we tend to assume that flags are way smarter and do a lot more than they actually are or do. Flags are dumb. DML tries to hide this as best it can, but can only go so far Maybe take a screenshot of the two trigger zone attributes that you are connecting with a flag, and explain what you want to accomplish. Yes, I was looking for the arithmetic result of it "If there are 8 players stop spawning CAP flights when there are 6" --> pNum -2. And sorry, yes, I didn´t express myself correctly, I should have said that if it was possible to use as a trigger method a rule like "-2", or "+4" in regards to the watchflag´s value or any similar to that, not only "+1" or "-1" that is actually more like if it has increased or decreased only if I´m understanding it correctly. Sorry, if I´m bothering you with these questions, they are probably kind of simple ones that could seem obvious and honestly, I think you have made a great job with all the documentation, demo missions and explanation. When I ask is usually because I have gone up and down looking for the solution/logic of something and I´m not finding it, even when it´s just in front of your face . Thank you for your patience Edited May 9, 2023 by mimamema
cfrag Posted May 10, 2023 Author Posted May 10, 2023 To be honest, I appreciate these questions a lot - they show where the manual has weak spots 10 hours ago, mimamema said: If there are 8 players stop spawning CAP flights when there are 6" --> pNum -2. I think what threw me a bit was the presence of an output attribute (pNum) as the name for a flag. In my mind, I liken modules to integrated circuit "chips" of old, with their pins having names like "in?" and "out!". The flags are wires that connect these pins. Using this metaphor, here's a small 'circuit' I assembled with a cloner, counter and smoke modules: Here, the flag "next" connects the Count Down module's 'tMinus!' output to the Cloner's "clone?" input. Likewise, the cloner's "empty!" output connects the Count Down's "count?" input with the "advance" flag. Also, Count Down's "done" flag connects to the smoke zone's "f?" input. The whole apparatus uses a counter to count down respawns, and when it reaches zero, no more spawn are initiated, and the smoke zone receives a signal to start smoking. I hope that this image better illustrates the difference between a module's input/output attributes, and flags that connect attributes between modules.
shinobi61 Posted May 10, 2023 Posted May 10, 2023 (edited) On 5/8/2023 at 7:57 PM, mimamema said: ive the value of players in the zone or fire flags every time a player c I feel so stupid that alot of this goes over my head, this weekend gonna dedicate a day to flags Edited May 10, 2023 by shinobi61
mimamema Posted May 10, 2023 Posted May 10, 2023 3 hours ago, cfrag said: To be honest, I appreciate these questions a lot - they show where the manual has weak spots I think what threw me a bit was the presence of an output attribute (pNum) as the name for a flag. In my mind, I liken modules to integrated circuit "chips" of old, with their pins having names like "in?" and "out!". The flags are wires that connect these pins. Using this metaphor, here's a small 'circuit' I assembled with a cloner, counter and smoke modules: Yes, sorry It was my mistake wording things that way. Thank you for the clarification. I just put the CAP mechanics on hold while I do set up the basic things of the mission I´m editing, better this way I think, as I tend to overcomplicate things from the beginning sometimes I guess . Apart from that, I was wondering if the F10 map markers from the recon module could be added to the persistence module as that would be very helpful to not lose the intel gathered by a recon flight just before a server restart, I think that would be quite helpful.
cfrag Posted May 10, 2023 Author Posted May 10, 2023 8 minutes ago, mimamema said: I was wondering if the F10 map markers from the recon module could be added to the persistence module That's a great idea! Thank you! It won't make it into the next release (scheduled for tomorrow), but I'll try to integrate it in one of the near future ones. 1
mimamema Posted May 10, 2023 Posted May 10, 2023 3 hours ago, shinobi61 said: I feel so stupid that alot of this goes over my head, this weekend gonna dedicate a day to flags yesterday I was playing with RND flags and literally waste an hour trying to figure out what was not working, opening the demo mission, re-reading the documentation, and quick reference as well... till I realized that I wrote RDN instead.... what a facepalm when I discovered it
cfrag Posted May 11, 2023 Author Posted May 11, 2023 (edited) Version 1.3.0 - Feature Update: FlareZone, PlayerZone, Shallows -- 20230511 Spring is in the air, and new ideas are blossoming seemingly everywhere - at least that is my impression from the feedback I receive from you. Consequently, DML's idea backlog is filling up, and managing it would have become a chore hadn't I had the (lucky) foresight to use a tool. This update contains three new modules: one to mitigate an annoying bug with DCS's naval units in shallow waters, one utility for you mission designers to count your sheep (players), and one to provide spectacular effects at night (it's a side effect of the utilitarian aspect of the module): flare zone. So let's start with the extroverted one: flareZone is a module to answer a request to simply launch a flare on demand. I could not resist and add some DML sparkle to it: now you can not just launch one flare, but many, over a time span. With randomized colors and directions to boot. Not required, but really nice for night missions to let your players know that they have completed the mission. High-Caliber Eye Candy. The new 'shallows' module is a drop-in, no configuration required, no dependencies fire-and-forget module that does one thing: when a ship sinks after being destroyed, but remains visible because the water is too shallow, the module removes it after 5 minutes. Until then, in marks the spot with flames and smoke. PlayerCount is a module that was requested to provide some often used (and seemingly overlooked by me) functionality: provide the number of players in a zone, so this can be used to trigger modules or game stages. It also has outputs for when players are added or removed from the zone, so all requirements (hopefully) are covered. Between creating new modules I also found the time to further strengthen DML cohesion: dcsCommon and cfxZones have received code review and new abilities, and PlayerScore has received integrations with other modules like ASW. The one thing that did elude me this cycle was closing down the OwnedZones functional split. Something in the architecture is bugging me, feels off. This prevents me from finalizing the new design, and so I recommend you continue using the legacy version. All Changes Documentation Main - Various modules - updates - Flare Zone documentation (new) - Player Zone documentation (new) - Shallows documentation (new) - Effects with a Flare demo: documentation (new) - Players in the Zone demo: documentation (new) - Not too shallow demo: documentation (new) Quick Reference - Flare Zone (new) - Player Zone (new) - Shallows (new) Demos - Effects with a Flare (new) - feats and autoCSAR (update) - Not too shallow at all (new) - Players in the Zone (new) Modules - ASW 1.0.1 Integration with PlayerScore - aswGUI 1.0.2 Late-start capability added - PlayerScore 2.0.1 Fixes for time stamp and config reading - PlayerScoreUI 2.0.1 Late-start capability added - Smoke Zone 1.1.3 Fixed method designation - SpawnZones 1.7.5 Fix for height bug in requestable spawners - cfxZones 3.0.9 getFlareColorStringFromZoneProperty() (new) - CSARmanager 2.2.6 Now also supports flares (for night operation) in addition to smoke - dcsCommon 2.8.7 new methods for flar color and to iterate players - flareZone 1.0.0 Initial version - playerZone 1.0.0 Initial version - shallows 1.0.0 (standalone) Initial version - williePete 1.0.2 Added support for Gazelle's WP munitions Enjoy, -ch Edited May 11, 2023 by cfrag 3
mimamema Posted May 16, 2023 Posted May 16, 2023 Hi @cfrag! here I come again! . I´m having a bit of a problem with ownedzones and attackers. They spawn as configured but a message appears top right like this "goundT: unscheduled group ZC1 (A) 76622 cnt=1null", and the counter keeps rising. I´m attaching screenshots as I think they would be more self-explanatory. DCS log throws an error in "getNearestEnemyOwnedZone". In the screenshots you can see the config of the zone. all the modules necessary for this are loaded into the mission. I set the owner of the zone above in blue as Allied to make the attackers work but it didn´work Any idea why this could be happening? Just in case this is the new Normandy map, I don´t know if it could have any relation with the issue.
cfrag Posted May 16, 2023 Author Posted May 16, 2023 2 hours ago, mimamema said: DCS log throws an error in "getNearestEnemyOwnedZone" Thanks for the headsup! I'm looking it right now, and to eliminate some possibilities: which version of owned zones are you using in that mission? The legacy 1.x or new (unfortunately not complete) 2.x versiion (the one that is currently undergoing refactoring into owned zones and factory zones)? It looks as if you may be using the newer version. If that is the case, simply replacing ownedZones with the legacy one should resolve the issue.
mimamema Posted May 16, 2023 Posted May 16, 2023 7 hours ago, cfrag said: Thanks for the headsup! I'm looking it right now, and to eliminate some possibilities: which version of owned zones are you using in that mission? The legacy 1.x or new (unfortunately not complete) 2.x versiion (the one that is currently undergoing refactoring into owned zones and factory zones)? It looks as if you may be using the newer version. If that is the case, simply replacing ownedZones with the legacy one should resolve the issue. Yeah! That was the reason, I was using the last version yes, now with the legacy one the troops get start heading to the blue owned zone, thank you! . About this, what is the default way of pathing them? What I understand after reading the docs is that they should go on the roads by default? What I see is that they go mainly off-road and that is making a bit of trouble while trying to find their way through the town, getting stucked often, being this more a DCS problem than anything. Probably I'm missing something here.
cfrag Posted May 16, 2023 Author Posted May 16, 2023 8 minutes ago, mimamema said: About this, what is the default way of pathing them? Pathing should be controlled with the cfxCommander module, or, more to the point, the cfxCommander's config zone. Pathing in DCS is a bit voodoo, and some maps with extensive roads can provoke bad crashes, so be careful when pathing through those areas, 1
HungryCoyote Posted May 17, 2023 Posted May 17, 2023 Using DML, is it possible to get colored zones in game and also to change their color based on which coalition owns them (similar to the foothold missions)?
Panthir Posted May 17, 2023 Posted May 17, 2023 (edited) 3 minutes ago, HungryCoyote said: Using DML, is it possible to get colored zones in game and also to change their color based on which coalition owns them (similar to the foothold missions)? Yes 3 ring circus Blue and Red v1.miz Edited May 17, 2023 by Panthir 1 My Hardware: ROG Strix X570-F Gaming - AMD 5600X @ 4.7 ghz - G.SKILL TRIDENT 32GB DDR4 3200 (14-14-14-34 CL) - GigaByte 3080ti OC 12gb - Corsair MP600 Force 1TB - 2 x EVO Nvme 500GB - Virpil Warbird Base T-50CM2 and TM Throttle + Trackhat + G25 + AOC AG271QG 27" My Modules: JF-17, F-16C, AV-8N/A, F-18C, ASJ37, MiG-15Bis, MiG-21Bis, Fw-190D, Bf-109K, P-51D, F-86F, Ka-50 III, UH-1H, Mi-8MTV2, NS430, FC3, A-10C, Mirage 2000C, L-39, F-5E-3, SA342, Spitfire, AH-64, Mirage F-1CE. My Maps: Nevada, Normandy, Persian Gulf, Syria, South Atlantic.
HungryCoyote Posted May 17, 2023 Posted May 17, 2023 Exactly what I needed. DML is like my tool box. Everything is in there. I just can't find it.
HungryCoyote Posted May 17, 2023 Posted May 17, 2023 (edited) Next question. My zones are on oil drilling platforms. I would like them to change color based on when a sling loaded cargo is unhooked in zone rather than by units just moving into zone.3 ring circus Blue and Red platform v2.miz Edited May 17, 2023 by HungryCoyote
Panthir Posted May 17, 2023 Posted May 17, 2023 2 hours ago, HungryCoyote said: Next question. My zones are on oil drilling platforms. I would like them to change color based on when a sling loaded cargo is unhooked in zone rather than by units just moving into zone.3 ring circus Blue and Red platform v2.miz It works only with units mate My Hardware: ROG Strix X570-F Gaming - AMD 5600X @ 4.7 ghz - G.SKILL TRIDENT 32GB DDR4 3200 (14-14-14-34 CL) - GigaByte 3080ti OC 12gb - Corsair MP600 Force 1TB - 2 x EVO Nvme 500GB - Virpil Warbird Base T-50CM2 and TM Throttle + Trackhat + G25 + AOC AG271QG 27" My Modules: JF-17, F-16C, AV-8N/A, F-18C, ASJ37, MiG-15Bis, MiG-21Bis, Fw-190D, Bf-109K, P-51D, F-86F, Ka-50 III, UH-1H, Mi-8MTV2, NS430, FC3, A-10C, Mirage 2000C, L-39, F-5E-3, SA342, Spitfire, AH-64, Mirage F-1CE. My Maps: Nevada, Normandy, Persian Gulf, Syria, South Atlantic.
cfrag Posted May 17, 2023 Author Posted May 17, 2023 5 hours ago, HungryCoyote said: Using DML, is it possible to get colored zones in game and also to change their color based on which coalition owns them (similar to the foothold missions)? As @Panthir already kindly commented, yes. That is a function of ownedZones. The upcoming release (slated for next week) has the option of providing zone-individual coloring if you want to go wild, or stay at red / blue / grey for ownership: 4 hours ago, HungryCoyote said: Next question. My zones are on oil drilling platforms. I would like them to change color based on when a sling loaded cargo is unhooked That's an interesting idea. Currently, the color of an owned zone is tied to who (faction) owns the zone. I'll see if I can come up with a 'colorZone' that can assume the color based on a table of colors that you can provide, and the value of an input flag whose value selects the color from the table. 1
HungryCoyote Posted May 17, 2023 Posted May 17, 2023 Cool. Appreciate all your work on DML. BTW, that mission that Panthir provided only works for ground vehicles but not helo or boat.
cfrag Posted May 17, 2023 Author Posted May 17, 2023 37 minutes ago, HungryCoyote said: that mission that Panthir provided only works for ground vehicles but not helo or boat. Indeed. DCS rules decree that a zone can only be captured when boots are on the ground. Aircraft don't count, and neither do naval units. Then again, that only applies to Airfields and FARPS. So for owned zones I think I should be able tweak the rules in DML as config options. Let's see it I can do it and get it into the next release
cfrag Posted May 17, 2023 Author Posted May 17, 2023 (edited) 2 hours ago, cfrag said: Let's see it I can do it and get it into the next release Looking good... Zone was only captured after the helo landed inside the neutral owned zone. Still a lot to test, but this feature (allow naval, helo, fixed wing to also capture owned zones) will very likely make the cut for the next release as part of the new OwnedZones 2.0 EDIT: oh, yeah. right. Quad owned zones are coming too. Edited May 17, 2023 by cfrag 1 2
Recommended Posts