Jump to content

sunski34

Members
  • Posts

    753
  • Joined

  • Last visited

Everything posted by sunski34

  1. Hi ked, actually, you can add a boolean flag for each player and you need to define onCreatePlayer to initialize this flag like this (I suppose player is not in zone when he enters mission, if not you to do a same test you did in onZonePass function) : local thisModule local moduleName = "QuickResponse" local function onCreatePlayer(player) player.modules[moduleName].inZone = false end local function onZonePass(player, events) if player:isInDCSZone("Delta") == true then if player.modules[moduleName].inZone == false then -- Test the flag to do it once local err, var1 = ATME.C_GroupSpawnDatas.duplicateFromMissionDatas(" Delta Quick Response F15", "Delta Quick Response F15" .. math.random(10000)) if err == false then var1:spawn("Delta") player:display("L'ennemi à décollé de batumi faites attention !",10) end -- and just after, set flag to true. player.modules[moduleName].inZone = true end else -- Player leaves zone, flag has to set to false once. if player.modules[moduleName].inZone == true then player.modules[moduleName].inZone = false end end end -- MAIN do local newHandlers = { onCreatePlayerHandler = onCreatePlayer, onDeletePlayerHandler = nil, onUpdatePlayerHandler = onZonePass, onTakeoffPlayerHandler = nil, onLandingPlayerHandler = nil, onStartEnginePlayerHandler = nil, onStopEnginePlayerHandler = nil, onCreateAIUnitHandler = nil, onDeleteAIUnitHandler = nil, onDisableAIUnitHandler = nil, onTakeoffAIUnitHandler = nil, onLandingAIUnitHandler = nil, onStartEngineAIUnitHandler = nil, onStopEngineAIUnitHandler = nil, onCreateGroupHandler = nil, onDeleteGroupHandler = nil, onDisableGroupHandler = nil, onCreateStaticObjectHandler = nil, onDeleteStaticObjectHandler = nil, onTimerHandler = nil, onModuleStartHandler = nil, } thisModule = ATME.C_Module(moduleName, newHandlers, true) end Be careful on callback parameters : onUpdatePlayerHandler has 2 parameters, player and events. I modify it in your code too. events are all ATME event fire each second (ATME Core events, or user trigger event). ATME will have a new possibility soon (in next version) with two new functions in class ATME.C_Area and two new ATME core events to track aircrafts in areas. But you will have to use ATME Core events Sunski
  2. Hi Suntsag, ATME has two functions (see in english doc) : ATME.convertMGRSToLL(tableMGRS) to convert a MGRS to latitude/longitude ATME.convertLLToMGRS(latitude, longitude) to convert latitude/longitude to MGRS For tableMGRS format, here : http://wiki.hoggit.us/view/DCS_func_LLtoMGRS After, I never use it really except to convert JTAC info MGRS into L/L in NATO.lua DCS file. Sunski
  3. Bonsoir à tous, une nouvelle version d'ATME V1.0.9 avec quelques fonctions nouvelles comme l'autorespawn ou la possibilité de patrouiller ou de démarrer un groupe d'aéronefs non contrôlés dans la mission. Quelques détails et une mission exemple ici (en anglais) : https://forums.eagle.ru/showpost.php?p=3065423&postcount=54 comme d'habitude le détail ici avec le lien en bas de page pour le téléchargement : https://forums.eagle.ru/showpost.php?p=3001633&postcount=1 Je mets la documentation en Français à jour rapidement. Merci à vous Sunski.
  4. New Version V1.0.9 : auto respawn and patrol Hi, today a new release of ATME V1.0.9, see here for détails and download : https://forums.eagle.ru/showpost.php?p=3001608&postcount=1 I will update documentation as soon as possible (French and English). Examples of new ATME_C.Group functions : local troops, nb = ATME.C_Group.getGroupsInDCSZoneForCoalition("BLUE", "LoadingZone", false, "GROUND") The last parameter is filter (here "GROUND") : it is optional or can be set to "ALL", "GROUND", "AIRPLANE", "HELICOPTER" or "SHIP" Those kind of functions now return groups (a list of ATME.C_GROUP instances, here a list of troops) and number of groups. group:setAutoRespawn(2) Parameter 2 is rules and represents a delay (number or string with specific format) to before respawn, and it is optional. Of course random time exists, you will see that in future documentation. auto respawn respawn a group after its destruction or desactivation. It must be set after each creation. It's possible to reset it at anytime. group:setPatrol("BeginPatrol", "EndPatrol") setPatrol set a patrol between two points defined by their name or number, same number than id in Mission Editor. An optional parameter stopCondition (string with specific format) will stop patrol under certain conditions (nb of turns, time or random). We will have more informations in documentation. Of course, resetPatrol exists too. You can now use duplicateFormMissionDatas with only one parameter to prepare the same group to be spawned. You can use that function with original groups, defined in mission if that group has been destroyed (or desactivate) before. And, finally, onCreateGroup Handler now accepts a new parameter called alreadyDeleted, so you know when a new group is created if it was already dead before in mission : local function onCreateGroup(_group, _alreadyDeleted) if string.sub(_group:getName(), 1, 6) == "troops" then -- The troops have to be ready to board, if not, troops cannot be embark ! _group:changeReadyToBoard(true) _group:setAutoRespawn() elseif _group:getName() == "H1" then _group:setPatrol("BeginPatrol", "EndPatrol") _group:setAutoRespawn(2) _group:setWaypointsTracking(true) local unit = _group:getFirstUnit() unit.modules[moduleName].onEarth = true unit.modules[moduleName].alreadyBoarding = false unit.modules[moduleName].index = 0 if _alreadyDeleted == true then local troops, nb = ATME.C_Group.getGroupsInDCSZoneForCoalition("BLUE", "LoadingZone", false, "GROUND") thisModule:output("Nb troops on zone = " .. nb, 1) if nb == 0 then _group:resetPatrol() ATME.setFlag(1, true) ATME.setFlag(2, true) else ATME.setFlag(1, false) ATME.setFlag(2, false) end else ATME.setFlag(1, false) ATME.setFlag(2, false) end ATME.displayForAll("Transport unit " .. unit:getName() .. " ready",5) end end I put a small mission here you can destroy troops and transport helicopter. See what happen ! Note : A problem with DCS event S_EVENT_LAND when using task "land" make my script more complex. S_EVEN_TAKEOFF works in that case.. Strange ! Enjoy ATME Sunski test AI transport respawn.miz ATME_AItransport_respawnV2.lua
  5. I want to say that ATME may work with MIST. Some people have done a mix of ATME and MIST, and that works. Sunski
  6. Hi Dart, actually, the rule is not to create dynamic points directly. It's not a question of difficulties, because ATME already do that for troops when disembark from helicopters. I think that it's easier to create WP with ME than with float numbers in lua tables. That's why setRoute function exists. you can create several AA groups with waypoints, set them with late activation and use their route with another AA group. In the future I think a good way is not to create WP dynamically but define tasks dynamically (for example engage group or FAC). For me : -> setRoute to change rouute (use the route of another group defined in ME) -> dynamically change specific tasks (engage group with dynamic target point, or land at a specific dynamic point for examples). I will begin that with land and load/unload troops functions for helicopters (in road map like polygons ;) ). So, step by step, all tasks will be implemented and modify dynamically. If that case is not enough, dynamic waypoints will be implemented but not yet. The next version will add new auto respawn abilities when a group as been destroyed... perhaps more like start function when an aircrafts group is created uncontrolled in ME. Sunski.
  7. Bonsoir à tous, sur un challenge (ici https://forums.eagle.ru/showthread.php?t=183340) j'ai proposé une petite mission test avec 2 groupes d'infanterie qui vont être transportées par un hélico AI. J'ai ajouté un hélico joueur avec des menu F10 pour détruire soit les groupes soit l'hélico AI. L'hélico AI transporte les troupes d'un point à un autre, en cas de destruction, le groupe est recrée à sa position initiale et l'hélico AI tentera de le retransporter. Si l'hélico AI est détruit, il est repawné et il reprend sa mission. La mission s'arrête quand il n'y a plus de troupes à transporter sur le point d'arrivée. Dans ce cas, l'hélico AI fait un RTB (pour le test c'est à côté). le lien sur la mission et le module ATME https://forums.eagle.ru/showpost.php?p=3058448&postcount=10 Il manque encore des fonctionnalités (notamment le respawn automatique pour simplifier le script), mais ca donne une idée des possibilités. ;) Sunski
  8. Hi, I create a small test mission (my answer of a question, see thread for more information https://forums.eagle.ru/showthread.php?t=183340) with 1 helicopter to transport troops and two infantry groups. F10 menu in the player unit can destroy the helicopter or the troops. helicopter transports troops from one point to another. If troop destroyed, it respawns. If helicopter destroyed, it respawns too. https://forums.eagle.ru/showpost.php?p=3058448&postcount=10 Interesting challenge even if some functions are not implemented yet (as automatic respawn). Sunski
  9. Please, try this .... I add a second troops group, and a player with 3 F10 menus : One to explode first group -> then it will respawn Second to explode second group -> then it will respawn Third to explode helicopter -> then it will be respawn and continue its mission Helicopter turns will stop if no more troops in LoadingZone (no use of F10 and WP4 passed), RTB. Of course, you can destroy them by another way ! OUPS ! Forgot to manage explode when helicopter has troops on board in first version ... Now it's good. Sunski test AI transport respawn.miz ATME_AItransport_respawn.lua
  10. Merci à vous ;) J'ai oublié de préciser que la doc était également à jour sur la page historique Sunski
  11. When I created ATME pickup/drop troops abilities (personnel carrier attribute for some helicopters or ground vehicles), there was 4 aims : Be realistic on pickup with dynamic personnel loading : Troops come towards personnel carrier and climb one by one. Of course, if there's a problem due to DCS, there's a timer based on the distance between troops and personnel carriers. Personnel carrier can be an AI unit or a player unit. In that last case, if you takeoff before end of boarding, some unit in troops may be killed. Same if you disembark near water and a unit of troops spawn in water, killed in that case too. The abilitie of pickup troops present in a radius around the personnel carrier vehicle. So you don't have to know the name of troops for pickup. The ability of define pickup zones : When troops enter such a zone, they stopped and become ready to be boarded. You can have signal on pickup zone too when a friendly helicopter (with personnel carrier attribute) is less than a defined radius. A personnel carrier vehicle can load several groups (of troops) with a limit of maximum units to be loaded depending of that personnel carrier vehicle. So MI8 can load more troops than Huey. So ATME can pickup troops with helicopters or some ground vehicules (personnel carrier attribute in ATME), spawned or not, since its first version V1.0.0. Actually, there's just a voluntary limitation in ATME : you can't spawn group which is already exists in mission (defined in DCS Mission Editor), so you have to create a group in DCS ME, then set it "late activation" and spawn it a first time with ATME. That's what I've done for the troops in my example but not for the helicopter. But it's possible to do the same now with helicopter. That limitation seems to be too strong... so I will adjust it in next version. I will send you a full example (with helicopter respawning) ASAP (perhaps this night if I have time).
  12. with 1.5.6, with my new Mobo, min is 38FPS (low alt, upon forest,), max settings.
  13. With 1.5.6, CPU is very important too... I bought a 1080GTX put it on a old I7 2600k and its motherboard (16GB RAM). Compare to the 970GTX I had before not really better performances. I changed my motherboard (32GB RAM) too, add a new 6700K then it's correct but not incredible ;) With 2.0.4, I had much better performances with GTX1080 compare to 970GTX,, using my old motherboard. Of course it was nearly perfect (never under 60FPS when flying upon Vegas) with my new motherboard. But with the last update 2.0.5 FPS dropped (sometimes less than 40FPS upon Vegas) :doh: I hope this will be fixed soon !
  14. Bonjour, un exemple de mission téléchargeable montrant le spawn (véhicule et un groupe de 2 hélicoptères). Le tout est activé par menu F10 pour le player. Il y a également le code du module lua qui s'appuiera sur la V1.0.8 d'ATME Core (obligatoire). le lien : https://forums.eagle.ru/showpost.php?p=3056907&postcount=47 Je reste disponible pour toute question Sunski.
  15. Please, find below an example mission which allows the player to spaws a groud vehicle or a group of 2 helicopters. The player can do that with F10 menu. The route is set by random and for the 2 helicopters, theirs callsigns are changed. You can download the mission and the specific lua module. This mission needs the last version of ATME V1.0.8 Test it and see. Enjoy ATME. Sunski test menu spawn and destroy.miz ATME_menu_spawn_destroy.lua
  16. Hi, no, I didn't do it in this mission but of course it's possible. A link here for such an example : https://forums.eagle.ru/showpost.php?p=3056907&postcount=47 Same problem if you want more than one troops... It's just an example done rapidly. But I think there a new generic ATME module idea here.
  17. Hi, I did that with my script ATME ... Two examples : * One with my idea : transports some troops with one helicopter from a point to another no spawn * One with my comprehension of your idea : 1 heli, 1 troop for example. Heli loads troops goes to the other point, than 30s troops destroyed, helo come back to initial point, take troops etc... (spawn the same group each time) If you want more information, ask me. Sunski. test AI transport respawn.miz test AI transport.miz
  18. Hi, if I understand, you want AI helicopters to tranports troop from a point to another and do it again and again ?
  19. Bonjour à tous, je suis heureux de vous annoncer que maintenant le spawn est pleinement opérationnel pour les groupes d'aéronefs (avion et hélicoptères). Cette possibilité vient compléter le spawn de groupes d'unités sol et de groupes de navires, sans oublier bien sûr le spawn d'objets statiques cargos. la page d'historique et lien vers le téléchargement : https://forums.eagle.ru/showpost.php?p=3001633&postcount=1 Si vous avez des questions n'hésitez pas. Sunski.
  20. Hi everybody, I'm glad to say today that ATME spawning is now fully operational. So you can spawn now AI ground groups, ships groups or Aircraft groups . Of course, spawning cargos is still available. You can change callsign before generate a new group, use setRoute function of ATME.C_Group class to change route of every kind of groups. If you need help, just ask me, I wil upload a simple mission ASAP. Download last version here :https://forums.eagle.ru/showpost.php?p=3001608&postcount=1 English documentation update here : https://forums.eagle.ru/showpost.php?p=3001613&postcount=2 Enjoy ATME :lol: Sunski
  21. Yes Area will help in several cases. My biggest problem actually is to convert a complex polygon (not crossed) into convex ones. Because if I want to spawn surely I need that. Hopefully, return if a point is in such a complex polygon is easier ! I'm going to finish that after the next version which is Airecraft spawning oriented as promised. Sunski
  22. Hi SUNTSAG, you're welcome ;) , your help is precious ! Thank you if you want informations about classes just ask... Even on rescue module to manage dynamic embark troops ! Sunski.
  23. Salut Scalp, si tu es intéressé nous sommes quelques uns à voler cool les samedis et dimanches après midi. Pour ma part, je suis comme toi, je ne vole jamais le soir... Si tu es intéressé, écris moi en privé, je te donnerai les infos qui vont bien et mon mail. Ce samedi vol sur 2000C justement nous serons au moins 3. A bientôt Sunski.
  24. Bonsoir, je viens de mettre à jour ATME suite à un soucis sur la destruction d'objets statiques lié aux maps. Je ne sais pas si c'est une conséquence de la mise à jour DCS 1.5.6 ou pas... mais c'est corrigé. lien : https://forums.eagle.ru/showpost.php?p=3001608&postcount=1 Sunski
  25. Hi, I uploaded a new version of ATME due to a problem of map static objects name which are number not string in lua. Perhaps a problem with DCS 1.5.6 but I'm not sure ! link here https://forums.eagle.ru/showpost.php?p=3001608&postcount=1 No more change Thanks to SUNTSAG for his help ! Sunski
×
×
  • Create New...