Jump to content

johnnyboy

Member
  • Content Count

    2693
  • Joined

  • Last visited

  • Medals

  • Medals

Everything posted by johnnyboy

  1. Watch this video to see how we want to use the generated positions to have an AI clear a building. The script used in this video has hardcoded positions for all the red arrows. If only these positions could be calculated for each building!!!
  2. Absolutely. We should compile a path library that anybody can contribute to. If it turns out we have to hardcode scripts per building, there's no way I can do them all. So as people are interested in a particular building, they can contribute their own assault paths. Personal preferences may drive many different paths for any given building. And if the building generated path concept does end up working, a mission maker can choose that path, or a preferred hardcoded path. I will have to document how create your own path, to make it as easy as possible for mission designers to construct their own. I probably won't do that until the design is more mature. All good ideas. I'm considering how best to parameterize this type of stuff. Hopefully support both fully customized at each move point, and more high level instructions as per your suggestion ("minimum force", "use non-lethal weapons", "maximum force"). But I need to get the basic framework and mechanics down before I take on too many requirements. It will evolve. Good thinking...we are on the same wavelength.
  3. johnnyboy

    EGO

    I had you boys pegged more along the lines of Corey and Trevor...
  4. johnnyboy

    EGO

    Hahaha. Poor Cosmic...now I know why he hasn't been around for awhile...he's institutionalized with no internet access. I know how it is...you start small, tweak, feature creep, and pretty soon you have a monster. But if you could isolate some code for those 2 things that would be awesome. If you come thru on that I promise not to name the pervert character in my next mission after you.
  5. Thanks amigo. That is EXACTLY what this script is good for. Oil Rigs, Ship Addons, the new Destroyer, a custom fortification...they all are missing AI paths, so any missions made are all placing static AI units that can't move (i.e., a little boring...). But a mission maker can now put AI on an oil rig and make different move scripts (patrol, etc.) and make the rig come alive. And you could also script AI to assault the oil rig using different paths.
  6. I attached invisible targets to dogs, and reveal the targets to the near AI (which make them target it) and run loops forcing them to fire with useWeapon command. You can look at JBOY Dog scripts. I know that is daunting as there is a ton of code, and not all of it is easy to read. But I don't have time to isolate exact code to work for you, so if you want it, you will have to work for it a bit. Look at my script JBOY_dogCommand. Its a monster, but if you just focus on the code in the FOLLOW/HEEL command section you should be able to understand it. Just ignore stuff you don't care about (like If "swimming", etc.). Previously I used the doMoves like you are for making dog follow unit. But I discovered later that doFollow worked, and dog stayed much closer to unit. So you may be able to use doFollow for the heel case. And you still use your "distance from unit" checks to modify the dog's animations (Sprint when far away, then Run when closer, then Walk when closest, and maybe Stop if close and unit being followed is stopped). Here's the banner/header for the section of code you want to look at in JBOY_DogCommand. Just the code under this IF IN HEEL MODE if statement: while {(alive _dog)} do { //main loop _handler = _dog getVariable "vHandler"; //******************************************************************************************************************* //********** FOLLOW/HEEL *********** FOLLOW/HEEL ************** FOLLOW/HEEL ************** FOLLOW/HEEL ************* //******************************************************************************************************************* if ((_dog getVariable "vCommand") == "follow" or (_dog getVariable "vCommand") == "heel" and (alive _handler)) then { Thanks man, but I have too many projects going, so doubt I'll take that on. Look at heel code and use doFollow like suggested above. Also maybe adjust your sleeps to match how JBOY_DocCommand does sleeps.
  7. Great minds think alike! 🙂 I plan on making a separate Script Challenge post for this with a screenshot showing existing Building Positions and Door positions, plus helper arrows marking the additional line of sight markers that I need for complete paths. It is probably possible to do that starting from a door and raycasting around, but its not something I'm willing to take on... I should post this request later today.
  8. johnnyboy

    EGO

    Yo froggo. Have you considered releasing some of these features as separate scripts? Instead of one monster script, we can then pick and choose what to use. For example, right now I'm most interested in "Adjusted Camo in shade/Buildings" and "AI fire RPG thru windows".
  9. @LSValmont Hey buddy, woke up early so took a look. In your while loop you are executing a playMove on the dog on every iteration. Animals work funny, so you only want to execute the playMove one time and the dog repeats that move forever until you playMove a different move. So if you want the dog to follow you playMove Run animation only once, and give him new moveTo position commands. He will keep running and move to each new position. When you finally want him to stop you playMove Stop animation once and he stops. Then playMove Run again to get him to run. Your current code is giving him a million playMoves so he's going crazy. Here's how to fix that: Before the while dog alive loop, add this line: _last_anim = ""; while {alive _dog} do Then go through your code and wrap every playMove with an IF statement that only executes the playMove if the move is different than last animation. For example, you would replace this line: _dog playMove "Dog_Run"; ...with this line: if !(_last_anim == "Dog_Run") then { _dog playMove "Dog_Run"; _last_anim = "Dog_Run";}; Follow that pattern and replace every playMove in your script. That should solve your problem (unless there are other problems). And here's some friendly advice from an old software engineer: Format your code so you indent all loops and IF statements. This makes it much more readable. Here's your same code formatted with tabs (hopefully pasting into the forum code box keeps the tabs).
  10. I googled the crap out of this and couldn't find an answer. How do I get the ASL positions of doors for a building? The code below correctly finds all the door selections for the house. But it does not place a helper object at the physical position of the door. _house = nearestBuilding getMarkerPos "mrkBldg1"; _doors = []; { if (_x find "door" >= 0 and _x find "handle" < 0) then { _doors pushback _x; _ball = "Sign_Arrow_Cyan_F" createVehicleLocal [0,0,0]; _ball attachTo [_house,[0,0,0],_x]; }; } forEach selectionNames _house; hint str _doors; Solved. The code below creates a blue arrow on each house position the AI can move to. And creates a yellow arrow at each Door.
  11. Hey guys Hey guys, my first cut at this is actually showing some promise (and I still have a job and a wife!). Check it out here:
  12. Hey man, I'll try and take a look at it. But it might not be until early next week as I have alot going on through the weekend.
  13. johnnyboy

    AZC JBOY Pain Mod

    Love it! The high pitch dude totally cracks me up. Thanks for the enhancements and making the mod. This is 100% JBOY approved!
  14. No problemo, amigo. [...quits job...files divorce papers...scores some amphetamines..]
  15. You boys are funny! I never should have made that last post, lol. Expectations are way too high!!!! 🦄s and 🌈s for all!!! I'm already scaling back on auto-detecting the paths thru buildings, because doors and building positions are not a complete path. I need line of sight to each place an AI would need to move in order to go around a corner or go upstairs, and those positions are missing. Instead, I'm recording a series of positions by walking the building. Then making a path based on the recorded positions. If there are multiple entrances I can make multiple paths. We will see how it goes. Wish me luck!
  16. I looked a this bis function and I didn't waste my time after all. Their function is hardcoded to a walk animation only with no weapon. My script will support any animation, and provide option to force firing while moving. I may adopt their turning code though...not sure.
  17. All of the above is good advice: Driver in separate group. Driver set to CARELESS. Clear the path of rocks to the beach (I'd do that last if nothing else works). Also consider setting a Move waypoint short of the beach, and placing a trigger there. When boat reaches trigger use setVelocity to push it up the beach (should guarantee no retard ai swimming in circles). Then the infantry can disembark. I've had no problem using this technique with landing zodiacs, and team disembarks on beach. Your last resort is to use UnitCapture and UnitPlay so boat travels exact desired path every time.
  18. Good thinking. I thought you were referring to which way doors open. For external doors we can assume doors open inward. For internal doors I don't know.
  19. A girl can dream... 🙂 I'm sure I will fail miserably, but I am toying with "aggressive ai clearing". I have scripted point to point movement with passing in animation name. I can force fire while moving. Working on adding smooth turning to next point. My hopes are: If in aggressive mode, AI will shoot thru door before opening it. Or shoot handle if locked. Move quickly inside. If aggressive, spray while moving. If stacked, 1st guy enters further, 2nd guy follows but stops short of 1st guy position. Hopefully both sweeping different arcs. If aggressive, hose arc. On stairs, may side step up if top of stairs open to right or left (cover potential threats instead of blindly moving straight up facing forward only). On stairs, may toss grenade up if looking towards top of stairs (not landing) Before entering doors, may toss grenade in first (and side-step to cover) Call out "clear" Problems: While forcing scripted animation move, AI can't acquire and shoot targets using normal AI. I can force shooting while move, but that is only in direction of move. But if you pause between scripted moves, their normal AI takes over and they can target and shoot on their own. If that can be balanced somehow, it might work ok. Incorporate smooth turning with moves. Stop moves at correct points so don't ghost thru walls and objects. If the above doesn't work the script will still be good for cutscenes, and scripted scenarios (Example: street fight with lots of stationary cover objects (cars, barricades, dumpsters) - player attacks, and AI tactically retreats as they lose guys (move to next cover, walk backwards while firing, leap frog backward, sidestep strafing between cover, etc. If properly mixed with normal AI enemy behaviour, and randomized a bit, it could spice things up and player would hopefully not notice the scripting).
  20. A doMove to a position away from camp might be better, as I think scriptedMoves will freak out if there is an object in their path (they either will get stuck not moving while still playing animation or ghost through it...I think).
  21. I can't promising anything dude. I'm just scratching the surface on this right now. But I'll let you know if I discover something Holy crap EO. He collected and hardcoded all the door positions. That is a dedicated man. Much like the brutal grunt work Phronk is doing with furniture I think. For my little test I also want to collect position at base of stairs, stair landings and top of stairs. That I hardcoded for my example. But I'm not excited about doing that for all buildings. Maybe we can draft some newbie to do that. Start with ALL vanilla buildings + ALL CUP buildings, and have it done by tomorrow maggot!!!
  22. No, sadly I don't have direction. Also the door position appears to be on the door jamb on handle side of door, so as Beno said, you need to adjust the position if you want someone standing in front of door.
  23. Goddammit, didn't know about this function. I just spent hours writing my own version of this! Thank mgi!
  24. Thanks much FrogMan, I dug out what I need from there (lots of good stuff in there actually). I miss @das attorney. He was (and I'm sure still is) a cool guy. Maybe he'll be back for Arma 4.
  25. RAVAGE. That is so sweet.
×