Home   Help Search Login Register  

Author Topic: Spawning A10 flying with pilot in the air  (Read 639 times)

0 Members and 1 Guest are viewing this topic.

kevinfostereditguy

  • Guest
Spawning A10 flying with pilot in the air
« on: 14 Dec 2002, 17:11:23 »
i have a few questions for you scripting gurus about spawning an a10 with a pilot what drops in 3 guys all with the same script running for them, then join the player, the plane should fly on then be deleted along woth the pilot


-i need to spawn an A10 in the air, but every time i use this script or flyinheight it just is on the ground.

plane = "A10" createVehicle [(getpos player select 0), (getpos player select 1)-150, (getpos player select 2)+100]

btw, it would help if the A10 flaces the player.


-next, i need to spawn a pilot that isnt connected to any group to be in the pilot's seat to fly the thing, so you would see a plane spawn high in the air and fly towards you (and past cause the pilot will be commanded to fly 150 past you.


-next, i need about 3 units spawned in the air under the plane to simulate a paradrop after the plane passes over the player, all with a certian script running on them (lets just say its [this] exec "thisguy.sqs", i want that to run in the guy's init field as soon as he spawns.

what i have at the moment is-

Code: [Select]
plane = "A10" createVehicle [(getpos player select 0), (getpos player select 1)-150, (getpos player select 2)+100]
; then i need to spawn a pilot in the cockpit to do this-
pilot move player
goto "loop"

#loop
?(plane distance <=20 player):goto "droptroops"
; or it could be after a short time, such as ~3, doesnt really
; matter
goto "loop"

#droptroops
; this should consist of 3 creatunit commands to spawn 3
; identical west soldiors, all with "thisguy.sqs" running in their
; init field
; then the 3 guys just dropped should join the player
pilot domove [(getpos player select 0), (getpos player select 1)+150,(getpos victim select 2)+100]
~3
deletevehicle pilot
deletevehicle plane

anyone able fill in the (admittedley large) gaps or give me a few pointers?

btw, iv just realised the A10 isnt exactly a troop carrying aircraft, lol, so any reccomendations on what would look better?
« Last Edit: 14 Dec 2002, 17:15:35 by kevinfostereditguy »

Pandoz

  • Guest
Re:Spawning A10 flying with pilot in the air
« Reply #1 on: 17 Dec 2002, 00:50:46 »
well the only thing that i see (even though i suck at scripting) is that Flyinheight doesnt work with airplanes..only helos...but that is the only thing i see...i am not knowledgable on these things so any1 else see something wrong?

Offline Skumball

  • Members
  • *
Re:Spawning A10 flying with pilot in the air
« Reply #2 on: 17 Dec 2002, 04:48:31 »
I can't fully answer your question right now, but take a look at the airstrike script that I did and see if it helps. It contains a lot of things which seem to meet your needs.

http://www.ofpec.com/includes/download.php?type=2&id=171