Grimes Posted February 2, 2018 Posted February 2, 2018 (edited) Hey all. Meant to do this on release day but been swamped. Not a whole lot on the scripting side was added, but there are a few nice things in there. Some of this applies to patches for 2.2 but I'm including it mostly for the sake of completeness. lua predicate in the triggers should now be fixed. land.getClosestPointToRoads added land.findPathOnroads added Mark panels have 2 new variables A few countries were added: "ALGERIA" ,"KUWAIT", "QATAR" ," OMAN", UNITED_ARAB_EMIRATES" Activate Static trigger action added. Scenery Objects remove trigger added. The activate static I think is WIP as there doesn't seem to be a way to set a static to not be active. The mark triggers also have the commands. For one reason or another the functions are crashing the sim as of the first release of the 2.5 open beta. It is reported. Ive attached a few screenshots of the new land functions in action. As you can see it can return A TON of entries to the table even for a short distance. It honestly looks like it is using the same code to create the "spans" that get saved with a route in the editor. Needless to say the longer and curvy the route the more points there are. In the shorter example it returned 110 entries. On the longer one it returned 710 points of a 45km route from about halfway between Senaki and Kutasi to the town of Ochamchira. Also I got some clarity on a few functions that exist but had some unknown syntax on. When I get some time I will test it out and add it to the wiki. Mostly stuff like the following that have to do with cargo and troop transport: coalition.checkDescent, coalition.getAllDescents, coalition.checkChooseCargo 2.5.1 Functions for accessing mark panels. - world.getMarkPanels() - 3 event handlers for add, change, and removal of mark panels. Trigger to create large smoke effects trigger.action.effectSmokeBig() Edited May 10, 2018 by Grimes 2 The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
71st_AH Rob Posted February 2, 2018 Posted February 2, 2018 lua predicate in the triggers should now be fixed. About time, have needed this since 1.2 some time A few countries were added: "ALGERIA" ,"KUWAIT", "QATAR" ," OMAN", UNITED_ARAB_EMIRATES" Now if we can get W.Germany and GDR added...
Igneous01 Posted February 4, 2018 Posted February 4, 2018 Grimes - for the function findPathOnroads, does it return the road positions in order (from start to dest) or is the order returned random? Just curious if I can do something like roads[#roads / 2] to get the midway point between the two positions. Developer of Kaukasus Insurgency - a customizable Dynamic PvE Campaign with cloud hosting and stats tracking. (Alpha) http://kaukasusinsurgency.com/
Grimes Posted February 4, 2018 Author Posted February 4, 2018 I think it is in order but I didn't spend a lot of time to confirm it. Basically I just iterated through the smoke colors and spawned a smoke at each point. It certainly looked like all the smokes were in the same pattern. The middle entry for the roads table isn't a guarantee that it is the actual midpoint for the route. As you can see from the first screenshot the vast majority of the returned values are in the background. The middle entry would probably be closer to 3/4 through the route. To find the actual middle you'd probably need to calculate the distance between each point, get the halfway distance, then find the nearest point along the route to it. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
Pikey Posted February 5, 2018 Posted February 5, 2018 Thanks for the clarification and updating the Hoggit, you know there were a few people desperately interested in the new bits, so cheers! ___________________________________________________________________________ SIMPLE SCENERY SAVING * SIMPLE GROUP SAVING * SIMPLE STATIC SAVING *
funkyfranky Posted February 11, 2018 Posted February 11, 2018 Thanks, nice additions :thumbup: Just FYI, there is a typo (also on hoggit) land.findPathOnroads added The "r" in roads must be capitalized, i.e. land.findPathOn[b]R[/b]oads is correct. A warrior's mission is to foster the success of others. i9-12900K | RTX 4090 | 128 GB Ram 3200 MHz DDR-4 | Quest 3 RAT - On the Range - Rescue Helo - Recovery Tanker - Warehouse - Airboss
Delta99 Posted February 12, 2018 Posted February 12, 2018 Grimes, Where would be the best place to suggest a enhancement to land.getSurfaceType? With the introduction of 2.5 and trees / forests playing a much larger role in LOS etc, knowing if the land area is in a forest could be extremely useful when spawning units (ie. might not want to spawn units in the middle of the forest). I haven't done extensive testing but with some of my missions units are now spawned in a forest. I'm not sure they are able to shoot out of the forest and of course they are much harder if not impossible to find. In any event, the mission designer might want to spawn either in or out of a forest. If it is possible to determine this in the DCS engine it would be great to have such an enum returned with this function. My Missions: Valley Patrol Mission :: Valley Escort Mission :: A2A Engagements
Grimes Posted February 12, 2018 Author Posted February 12, 2018 I already made a request for functionality like that. Also for finding the nearest building to a point and if a point is inside a building. Hopefully it'll get implemented. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
fuxx Posted February 13, 2018 Posted February 13, 2018 lua predicate in the triggers should now be fixed. FlightControl seems to be happy if that is true :D I remember how disappointed he was when he said in his Moose video tutorials that this was a known issue since >2 years :D DCS 2.5 Open Beta Nevada - Golf - A-10C - AV-8BNA - CA - F-15C - F/A-18C - Ka-50 - MiG-29 SA342 - Su-25T - SU-33 - TF-51D - UH-1H - :pilotfly:! Windows 10 Prof - Ryzen 2700X - ASUS ROG STRIX X470-F GAMING - Palit GeForce Super JeStream 1080 TI on 34" LG curved monitor @ 3440x1440 - 32GB RAM @ 3200Mhz - Thrustmaster Hotas Warthog - Saitek Pedals - 2 x 7" LCD behind Thrustmaster MFDs
Delta99 Posted February 14, 2018 Posted February 14, 2018 I already made a request for functionality like that. Also for finding the nearest building to a point and if a point is inside a building. Hopefully it'll get implemented. Excellent!!! My Missions: Valley Patrol Mission :: Valley Escort Mission :: A2A Engagements
Grimes Posted May 10, 2018 Author Posted May 10, 2018 DCS 2.5.1 has added a few functions for accessing mark panels. Its already available in the open beta build that is currently live. world.getMarkPanels() event: S_EVENT_MARK_ADDED event: S_EVENT_MARK_CHANGE event: S_EVENT_MARK_REMOVED I've added documentation on it to the updated hoggit wiki. I don't know when that wiki will replace the old one. So eventually the URL will probably change. Links have been edited to the first post above. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
Pikey Posted May 10, 2018 Posted May 10, 2018 (edited) Thanks for the heads up on those events. I noticed 'big smoke' had arrived as a trigger condition in 2.5.1, which is awesome, is this accessible in scripting yet, please? Edited May 10, 2018 by Pikey apostophe catastrophy ___________________________________________________________________________ SIMPLE SCENERY SAVING * SIMPLE GROUP SAVING * SIMPLE STATIC SAVING *
Grimes Posted May 10, 2018 Author Posted May 10, 2018 Should have been able to add it as a static object previously, but I've never tried it. However yes there is new trigger action for that type of smoke. Tested and figured out the input parameters. trigger.action.effectSmokeBig() The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
funkyfranky Posted May 11, 2018 Posted May 11, 2018 However yes there is new trigger action for that type of smoke. Tested and figured out the input parameters. trigger.action.effectSmokeBig() Thanks Grimes, great news :thumbup: FYI, I think the enumerator numbering is slightly off. It should start at zero (small smoke and fire) and end at seven (huge smoke). A warrior's mission is to foster the success of others. i9-12900K | RTX 4090 | 128 GB Ram 3200 MHz DDR-4 | Quest 3 RAT - On the Range - Rescue Helo - Recovery Tanker - Warehouse - Airboss
Grimes Posted May 11, 2018 Author Posted May 11, 2018 I based if off of how it shows up in the .miz file with the trigger. Which is 1-8. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
funkyfranky Posted May 11, 2018 Posted May 11, 2018 I based if off of how it shows up in the .miz file with the trigger. Which is 1-8. Okay, I see. Maybe "enum smoke preset" should be defined somewhere more clearly (or I missed that). I tried 1-8 first and got a "shifted" result because trigger.action.effectSmokeBig(vec3, [b]0[/b], density) gives the small smoke and fire. A warrior's mission is to foster the success of others. i9-12900K | RTX 4090 | 128 GB Ram 3200 MHz DDR-4 | Quest 3 RAT - On the Range - Rescue Helo - Recovery Tanker - Warehouse - Airboss
Grimes Posted May 11, 2018 Author Posted May 11, 2018 Weird. Gonna have to test it out some I guess. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
ESAc_matador Posted May 12, 2018 Posted May 12, 2018 By scripting, Land on Gorund Option used to work for groups. Now seems to be corrupted. I opened thread already... Any info available on that?
Johnny_Rico Posted May 18, 2018 Posted May 18, 2018 played with big smoke seems pretty epic Is there a way to switch it off ? METAR weather for DCS World missions Guide to help out new DCS MOOSE Users -> HERE Havoc Company Dedicated server info Connect IP: 94.23.215.203 SRS enabled - freqs - Main = 243, A2A = 244, A2G = 245 Please contact me HERE if you have any server feedback or METAR issues/requests
Grimes Posted May 18, 2018 Author Posted May 18, 2018 Try creating the smoke as an effects static object and then removing it. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
Johnny_Rico Posted May 18, 2018 Posted May 18, 2018 Try creating the smoke as an effects static object and then removing it. Sorry I am at a bit inexperienced, can you elude as to how to do this please ? METAR weather for DCS World missions Guide to help out new DCS MOOSE Users -> HERE Havoc Company Dedicated server info Connect IP: 94.23.215.203 SRS enabled - freqs - Main = 243, A2A = 244, A2G = 245 Please contact me HERE if you have any server feedback or METAR issues/requests
Grimes Posted May 19, 2018 Author Posted May 19, 2018 Doesn't matter, it appears to be bugged. But under static objects there is a new type called "Effects" which allows you to spawn in smoke. There are also a few other types that appear to be WIP still. The general idea would be to spawn it like any other static object via scripting and then be able to remove it whenever you choose to via Object.destroy(). The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
Johnny_Rico Posted May 19, 2018 Posted May 19, 2018 Thanks grimes, I take it a bug report has been raised and fingesr crossed they could fix it ... soonish Would be handy to be able to enable / disable this .... thinking forest fire operations in helis METAR weather for DCS World missions Guide to help out new DCS MOOSE Users -> HERE Havoc Company Dedicated server info Connect IP: 94.23.215.203 SRS enabled - freqs - Main = 243, A2A = 244, A2G = 245 Please contact me HERE if you have any server feedback or METAR issues/requests
Recommended Posts