Helo Pickup |
Helo Pickup |
Oct 24 2011, 23:54
Post
#1
|
|
Member Group: Members Posts: 43 Joined: 6-April 09 From: Milton Keynes, United Kingdom Member No.: 5,491 |
Hey guys
Can anyone tell me if there is a command or script that makes a transport helo wait until a selected squad/platoon embark it, then lift off and proceed to the desired drop zone? Thanks to anyone who can help |
|
|
Oct 25 2011, 10:02
Post
#2
|
|
Gee, I wish we had one of them doomsday machines. Group: Moderators Posts: 2,037 Joined: 13-November 06 From: Wales Member No.: 155 |
Helicopters land automatically if a get in command is issued. If you're using waypoints, just synchronize the squads "get in" waypoint with the helicopters "move" waypoint at the pick up zone. You can add this code:
CODE {_x assignascargo Heli} foreach units group this to any member of the group (either on init, or at an earlier waypoint) in order to ensure they get in the helicopter, and not a nearby tractor when dealing with AI led groups, if you're dealing with player led group, you might have better luck changing the condition for the helicopters move waypoint to this: CODE vehicle player = heli to ensure the helicopter doesn't fly off before the player can command his team to get in. (obviously where heli is the name you've given your helicopter in the editor!) If you're going down a more script-y route, try something like this: (nb, you'll need to work out the synchronization yourself - probably easiest to split it into three scripts, the script to get the helicopter to the pick-up point, triggered by the group being there, one to get them picked up, triggered by the helicopter being there, and one to move them on, triggered by the group being aboard the helicopter) CODE Heligroup = group HeligroupLeader; //If you've already defined the group as part of another script, you should remove this line and replace all references to heligroup to the correct name for the group
(driver Heli) commandmove (getpos (leader HeligroupLeader)); {_x assignascargo Heli} foreach Heligroup; //Wait until helicopter is near heligroup (units heligroup) ordergetin True; //Wait until Vehicle (leader heligroup) = Heli (driver Heli) commandmove (getpos LZ); //Wait until Heli is near LZ (units heligroup) ordergetin False; -------------------- The Rules - Nothing too complicated, follow these and we'll have no problems.
Moderation Feedback Thread - Tell everyone how much you Site Issues Thread - Complain about site issues here. We might even fix them! Community Chatter Thread - Furthest Mud-sling gets a free subscription to "JdB Monthly". QUOTE(Major Mike Shearer) We can categorically state that we have not released man-eating badgers into the area. QUOTE(Brace Belden) A machine gun is like a woman, I don’t understand it, I’m afraid of it, and one day I’ll accidentally be killed by one. |
|
|
Oct 27 2011, 19:33
Post
#3
|
|
Member Group: Members Posts: 43 Joined: 6-April 09 From: Milton Keynes, United Kingdom Member No.: 5,491 |
Right okay, thanks for that
Something else actually... How do you use the attachTo command? So in other words I want to have a soldier who doesn't wear a burgen or backpack, have one. If that's possible? |
|
|
Oct 27 2011, 20:26
Post
#4
|
|
Gee, I wish we had one of them doomsday machines. Group: Moderators Posts: 2,037 Joined: 13-November 06 From: Wales Member No.: 155 |
Attachto isn't very good for that sort of thing, IIRC it only works relative to the soldiers location, so it won't take into account any animations they'd be playing (so if you were to attach it so it's about where a backpack would be, if your solder where to start crawling, the backpack would just be floating in the air). You can attachto a memory point, but I'm not sure if that'll get the desired effect...
But I digress: CODE Object attachTo [TObject, Offset, MemPoint] Or more commonly just: CODE Object attachTo [TObject, Offset] So, something like: CODE Box attachto [Pickup, [0,0,0], "flatbed"] Or: CODE Soldier attachto [Cow,[0,0,0.25]] (Cow Cavalry! Of course, you can't control the cow, but you can't do that if you're riding a cow in real life, so it's realistic!) If you're curious about the syntax of command, it's better to check on BIKI before posting on the forums, you won't need to wait until someone answers that way! [link] -------------------- The Rules - Nothing too complicated, follow these and we'll have no problems.
Moderation Feedback Thread - Tell everyone how much you Site Issues Thread - Complain about site issues here. We might even fix them! Community Chatter Thread - Furthest Mud-sling gets a free subscription to "JdB Monthly". QUOTE(Major Mike Shearer) We can categorically state that we have not released man-eating badgers into the area. QUOTE(Brace Belden) A machine gun is like a woman, I don’t understand it, I’m afraid of it, and one day I’ll accidentally be killed by one. |
|
|
Lo-Fi Version | Time is now: 26th April 2024 - 04:29 |