Jump to content


  • Content Count

  • Joined

  • Last visited

  • Medals

Community Reputation

10 Good

1 Follower

About king_richard

  • Rank
    Lance Corporal
  1. king_richard

    Uav (cas)

    Updated first post with the current version. Once again thanks JShock, the groupID is now working on a dedicated server! Calling this v0.8 but don't be alarmed, it works, just missing some polish is all.
  2. king_richard

    Uav (cas)

    The script for the time being is named "UAV_Master.sqf" called by UAV placed in the editor the following code in it's init: null = [this] execVM "UAV_Master.sqf"; There's a check in the script to loop until _vehicle is valid as well. Only caught it on the dedicated server with -showScriptErrors. Perhaps my syntax was wrong, idk, but I'll test what you've posted tomorrow if time permits.
  3. king_richard

    Uav (cas)

    JShock, I saw some examples using the Bis_fnc_MP however when called within my script I kept getting "error undefined variable" using ...."[_vehicle,"Side Text"]..... which is why I resorted to the function method that I've had success with tricky dedicated server issues as I'm not well versed in how to handle locality issues despite reading multiple multiplayer scripting guides! And a switch would clean it up nicely, got carried away with copy/paste ;) Thanks, Richard EDIT: I see where your headed now; Very much appreciated and I'll withhold further comments until I review your critique.
  4. king_richard

    Uav (cas)

    An AI controlled UAV script that is mostly working. But there's a few issues I have at the moment. 1. addEventHandler and the MP version both are not working for sidechat on dedicated server. The alternative is to create another block of code to check weapons #'s and then fire off a side chat when number decreases. ( That's what I've done for the time being ) 2. Bombing runs seem to be done around 250m - 350m, and if I increase the "flyInHeight" then the UAV will still descend to that altitude. Is there a simple way to force the AI to release bombs at a given altitude? I'd like for them to remain above 1000m at a minimum. 3. Setting the group ID is not syncing on a dedicated server, how may I do this within the script? -Thanks JShock for the tips, all gtg except for the dive bombing. RELEASE NOTES: I've included the original editing folder along with a pbo if you want to test it out. Forgot to include a read me so here it is: - Radio trigger is created in the description, I've just tweaked the example from the wiki. - init.sqf contains the code to add the radio trigger to the player ( eventually I'll add in restricting to player "x" ) - UAV_Master is the core of the script - UAV_radioPOS is a simple script solely to get players marker position when radio is triggered and feed that into the UAV_Master I'd suggest plopping this into the editor to check it out for a minute before adding it into your mission. Released as v0.8 ;) not that it matters but I call it about 80% done. There's some more checks I'll add down the road to get rid of messages when UAV first spawns in and when they return to previously called CAS position. Will also add in a RTB radio option to send the UAV home. It's now down to playing with it and seeing what else needs to be done besides the already mentioned. But, I'm a busy man so a final composition will take some time! Download >> https://docs.google.com/file/d/0B5jK56pciK37RXh6a05GNjhUa00/edit --Original Remainder of Original post in-case your curios---
  5. Sorry for the delayed response. I have not been on arma lately but will check it out as soon as I can and hopefully get a fix up. And yes it was working pre-patch. I'll do some digging and let ya know. EDIT: I tested in a local MP session and it worked fine. But unable to test in a dedicated server environment at the moment.
  6. Been busy but finally got around to adding the abandoned vehicle check. Also included the code for checking names of vehicles so you can separate actions per vehicle. MHQVehicleInitExt V1.0 Link is also on the first post of the thread. Distance check is only set to 20, so you can see it in action and so I could test it out. It will also only check for one side. Let me know if there's anything else to add or fix and I'll put her on my todo list.
  7. I will look into running a deserted check and make that part of the extended version I suppose. Won't be hard to implement, it's just the frequency of running a player within area check is what I'd like to play with or atleast leave it easily adjustable. Not sure when I'll get around to implementing that though.
  8. The cold is full blown so been pretty slow the past couple of days. What you summed is up is pretty much it, the Trig involved really isn't complex once you refresh or learn the basics. In order to rotate everything we just need to find the distances from the corner points, or the center point and run that through a small calculation to get what the point will be after rotation. The Khan Academy got me brushed up and can definitely explain it all better then I. The points that the wall builds off of are not necessarily the corner points since they have to accommodate for the width of the walls and the origin of the walls model. The section count is used for calculating the points and the length and width of the FOB since each wall may vary in length. The idea is to have something flexible enough to use different types of walls in the future. We use the wall type's length to calculate the length of the FOB since it will not be equal to the exact marker size input. So, placing the buildings in the FOB will require coming up with a fraction or percentage of length or width from corner x, or from the center coordinate aka marker location. If you want a helipad 1/4 of the width away from the upper left corner or c1 then it'd be, for x: c1 - 25, for y: c1 - (width * 0.25), for z: _mZ < the -25 is just an estimate and would move the helipad 25m from the back wall. I get the x and y confused alot since this FOB gate is on the West wall. I think X was running the length of the FOB and Y is running the Width. N/S should be the Y axis and W/E should be the X axis in game. Just recalling from memory so hopefully it's mostly correct :) Perhaps once I get the towers set it'll give you an example to work off.
  9. Kabs, I am unsure of what your requesting. Could you expand on left behind vehicles.
  10. _H = createVehicle[_Towerzz ,[ ((_c4 select 0) + 0), ((_c4 select 1) + 0), _mZ],[],0,"CAN_COLLIDE"]; // Should be - for HQ _H = createVehicle[_HQ,[ ((_c4 select 0) + 0), ((_c4 select 1) + 0), _mZ],[],0,"CAN_COLLIDE"]; And Mwidth should be _wWidth I'll work on putting the building locations into a separate file. Also, if it helps you can build the templates however your comfortable and I'll work on converting them into something that's scale-able afterwards.
  11. No rush. I just finally resolved my rotation issue, was something extremely simple that I missed, but still need to redo the height code and then clean up the code so it'll take me a bit as well. edit -- The code is not cleaned up yet but I need you to look at it how to reference the placement of the objects within the FOB. As it is now, the wall will rotate but the towers have not been coded to rotate properly yet but I'm burnt out on it for the day. There's 4 corner markers that I've placed down that represent the corners of the FOB, these are the markers to do distance adjustments on. Or, you can do adjustments from the center coordinate as well. I tried to explain a bit better in the script too. I'll be continuing to re organize this script and perhaps add a few more functions to tidy everything up but didn't want to get too far into creating all of the templates with out first checking out how they need to be referenced now. FOB-DownLoad Also, I'm considering moving the object placement into another sqf file, since it'll make it cleaner and easier to modify the templates for the different sizes.
  12. Will get around to checking out the 11x11 some time today. I've got some of the stuff working for rotating but need to rebuild the code that builds the walls to accommodate for it plus figure out some extra stuff that goes along with it. Just looked at your code and see a problem with _Width = round floor (_markSize select 1); // ^ This variable was actually used to count the number of sections which is used _Yspacing = (((_Width + 1) * 5.6) - 4) * 0.5; // Orig _Width = round floor ((_markSize select 1) / 5.6); The variable's name is misleading and should be changed. I see your using the length and width of the marker for setting placement of the other objects so I'll just rename it to sectionCnt or similar.
  13. @Kabs, Good to hear it's working. As Doodle pointed out, perhaps the setObjectTextureGlobal command is what your looking for? A lot of things I've yet to tinker with and locality is one of those things that I can only learn through experience. But when you find a solution to something like that please do post what worked for you, may help the next guy. @Doodle, If you'd like to add further conditions to the actions you can do so in the function itself. You'll notice I've structured the function into 3 lines for the action, - the first is the name and sqf to execute - second line is the Bis stuff that generally stays the same for most actions: arguments, priority, showWindow, hideOnUse, shortcut - the third line is the condition that must be true for the action to be available more detailed info needed: addAction Now if you'd like to make it so that you can only use the action while outside of the vehicle than you could try: Change the == to != to make it so you have to be inside of the vehicle. I believe their was a vehicle cargo command to so you could possibly set up so that only players in the cargo could use the actions while inside of the vehicle. Do not recall the exact command off the top of my head.
  14. Fixes - MHQ_vehAction2 publicVariable named incorrectly - Multiple if(_state == 1) not necessary - Closing brackets on those if statements were missing - Declared all name checks outside of the scope if(_state == 1) - easier to read - Declared a new variable _nameCheckAll which adds all of the arrays together for the final if not in nameCheck - Updated the vehicle spawn to use the createVehicle array - undefined variable _heli changed to _vehicle - think that about sums it up Do note, this is untested code but should work, if not let me know and I'll put in some hints for you to check out where the code breaks down, or you can insert those hints yourself.
  15. I messed up when getting the size of the marker. Completely slipped my mind that the markers use radius instead of diameter. So, the fixed code is _Length = round floor (((_markSize select 0) * 2) / 5.6); _Width = round floor (((_markSize select 1) * 2) / 5.6); That might fix the large Icon issue! And yes my markers are scripted, except for the FOB atm since it's in production phase. However, there's a good chance that the "5.6" measurement will change. Just found that I can actually get the size of an object and then compute from there which is what I'll be working on later. So, the hard measurements that I've defined will likely be replaced with variables. That way you could change the type of wall if needed too. I've simplified the rotating issue, but I still need to brush up on some math before I can start piecing that portion together. I did test out one wall and was able to align it, but I just used estimates for the placements instead of trig. Hopefully when you get the sizes down and their default designs I'll be done with the rotation so we can merge the results. Depending on my cold and the weather it may take a few days though. Gonna have to go look for pictures of vehicles on buildings now, lol.