Jump to content

Photo
- - - - -

Helicopter Transportation Script [RC 1]


  • Please log in to reply
84 replies to this topic
Thread Starter
bob_gneu
bob_gneu

    Private First Class

  • Members
  • 27 posts

#1

Posted 05 May 2013 - 18:25

Posted Image

v1.4 [Gneu.org] [Armaholic]

For those of you looking for the ability to conduct larger scale missions, you would be at a loss without this script. Transporting vehicles across the map is now entirely possible, and easy to do.
[Sample Images]

Description
This script classifies helicopters into three groups and vehicles in the map into two. This package does not require you to apply any code to any units or vehicles in game, instead it applies itself to all vehicles & units at the initialization step of loading the mission. Because it does not require itself to be applied to the units at map initialization you do not need to worry about the use of your vehicle respawn script.

Installation / Usage
Two scripts need to be executed in your mission init.sqf:
[] execVM "scripts\transport\init.sqf";
[] execVM "scripts\player\init.sqf";

If you would like to modify the classifications, review scripts\transport\classify.sqf

Get into a helicopter, hover over a vehicle of the same or lower classification (think size/weight) and you will see an action show up to attach. Once you are attached you will be able to detach that vehicle at your most convenient time. Vehicles are detached automatically when the transporting helicopter takes substantial damage.


Current Classifications:
The mohawk is playing the role the chinook will once we go gold. At which time ill shift the Mohawk down to 3.
The PO-30(What used to be the KA-60) and the KA-50/Rooivalk bastard child are considered class 3.
The Ghost hawk is now a class 2 transport
The MH 9 is still a class 1 transport

Quads, Small boats and submarines are class 1,
Strikers, Offroaders and attack boats are class 2.
Ifrit and Hunters are class 3.
Trucks and APCs are class 4.


Known Issues
Mohawk alignment/positioning is a problem.
Dropping the subs (Yes the subs) causes them to tumble in certain circumstances.
Transported vehicles clip through the world.
Transported vehicles register the speed of the transporting helicopter.
Transported vehicles may be occupied.

Changelog
V 1.4 - Beta Update
- Corrected for entity name changes
- Added new beta vehicles & adjusted positioning
- Created new test map with new vehicles laid out

V 1.3 - MP Release
- Corrected incorrect MP behavior
- Configuration now present in scripts/transport/init.sqf
- To transport only need to be off of the ground, within 20m and the difference in speed between transport and cargo needs to be less than 3kmph
- Cleaned up classification && setup of transports
- No longer using Hints, reports are handed over via Vehicle chat
- Lots of MP testing Thanks to TF20
- Corrects red quads being incorrectly classified

RC 2
- Corrected semicolon issue

RC 1
- Initial Release.

Downloads
1.3 [Gneu.org]

Edited by bob_gneu, 27 June 2013 - 07:59.
Adding support for Beta vehicles. Updated changelog and classification information.


brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#2

Posted 05 May 2013 - 19:41

Vehicles etc wont detach?

Thread Starter
bob_gneu
bob_gneu

    Private First Class

  • Members
  • 27 posts

#3

Posted 05 May 2013 - 20:20

Vehicles etc wont detach?


If you are reporting that as a bug I will need to have more information.
I have tested this for the last week, including in MP, and it appears to be working. Can you forward me the %localappdata%\Arma 3 Alpha\*.rpt file that is tied to the run you made with the script?

brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#4

Posted 05 May 2013 - 20:48

Its in editor but ive switched to multiplayer and i get a cant find script error but its in the right place?

Thread Starter
bob_gneu
bob_gneu

    Private First Class

  • Members
  • 27 posts

#5

Posted 05 May 2013 - 20:54

If you want you can join me on IRC or Email.
I can help you further there.

brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#6

Posted 05 May 2013 - 21:15

Ive emailed you...

Thread Starter
bob_gneu
bob_gneu

    Private First Class

  • Members
  • 27 posts

#7

Posted 06 May 2013 - 02:37

Ive emailed you...


I have not received anything yet. bob@gneu.org

brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#8

Posted 06 May 2013 - 10:57

It musnt of sent, ive just sent it again

megaxd
megaxd

    Rookie

  • Members
  • 3 posts

#9

Posted 06 May 2013 - 13:35

Im gettin this error when i try to detach:

ht[]tp://imageshack.us/scaled/landing/17/errorxh.[]jpg

I took a look at that script but didnt find any error. (but that means nothin, im not really good in that scripting stuff:);)

(Sorry for not postin the link correctly, but this is my first post so i cant)

brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#10

Posted 06 May 2013 - 15:43

Im gettin this error when i try to detach:

ht[]tp://imageshack.us/scaled/landing/17/errorxh.[]jpg

I took a look at that script but didnt find any error. (but that means nothin, im not really good in that scripting stuff:);)

(Sorry for not postin the link correctly, but this is my first post so i cant)


Does it not detach for you either?

megaxd
megaxd

    Rookie

  • Members
  • 3 posts

#11

Posted 06 May 2013 - 15:49

No, it doesn't detach at all, but attaching is no problem.

brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#12

Posted 06 May 2013 - 15:50

Yeh im having the same problem...

keewa
keewa

    Sergeant

  • Members
  • 163 posts

#13

Posted 06 May 2013 - 16:23

Hi there, your mod is awesome, but there is, indeed, a bug and the "Detach" option seems not working.

Pic is better than long story :

Posted Image

Thread Starter
bob_gneu
bob_gneu

    Private First Class

  • Members
  • 27 posts

#14

Posted 06 May 2013 - 20:38

Thank you for your posts. I have a new build together. I think the 0.56 release broke something.
The reported error was not actually explaining the problem well.

Try out this build and let me know if it works for you.

[Gneu.org]

brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#15

Posted 06 May 2013 - 21:02

works fine now thanks...

keewa
keewa

    Sergeant

  • Members
  • 163 posts

#16

Posted 06 May 2013 - 21:05

It works like a charm, but if I want to transport custom vehicle, how do I do ?

brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#17

Posted 06 May 2013 - 21:20

just a little tip, if you can fix the distance way you attach find it hard to attach vehciles can be hovering for a good 5minute..but otherwise a great addition to the game

Thread Starter
bob_gneu
bob_gneu

    Private First Class

  • Members
  • 27 posts

#18

Posted 06 May 2013 - 21:33

@Keewa:
For Custom vehicles, there are two routes.
1. They need to be included in the [allUnits + vehicles] list and be able to pass the isKindOf test, resulting in either an air, ship or landvehicle option.
2. Apply the actions to your vehicles directly and you will need to change the player test to include your vehicle in the set of acceptable vehicles, controlled with the filter on nearestObjects.

You may be able to get it to work with some combination of the two. If you need assistance I am around pretty often.

---------- Post added at 21:33 ---------- Previous post was at 21:28 ----------

just a little tip, if you can fix the distance way you attach find it hard to attach vehciles can be hovering for a good 5minute..but otherwise a great addition to the game


The attachment is a bit tricky, but done that way for a reason. You are free to modify the script as you see fit, but my unit is a realism group and as such we require the vehicle to be almost directly below the transporting helicopter, capped at 10.0m + 2m of flexibility, for you to not be moving any faster than 1kmph and for the target to be within reasonable bounds (below 0.8 damage). In a future release i will likely toggle some of that off, so instead of transporting vehicles and respawning things, the helicopters will be required to transport the remains of vehicles back to base to "repair" them. Thank you for the input though. If you want I can help you with customizing things to fit your needs better.

.:Bob

brad7
brad7

    Gunnery Sergeant

  • Members
  • 450 posts

#19

Posted 06 May 2013 - 21:49

If you could show/send me the parameters id need to change for speed,height ect. thats would be great thanks

Thread Starter
bob_gneu
bob_gneu

    Private First Class

  • Members
  • 27 posts

#20

Posted 06 May 2013 - 21:57

in scripts/player/transportCheck.sqf there are checks three checks, starting on line 26 - 29 to actually begin searching for a target.

line 32 does the flexibility check.
_target = (nearestObjects [_vehicle, ["LandVehicle", "Ship"], _altitude + 2 min 12.0]) select 0;

nearest object takes a location, a filter on type and a distance to scan, so i take the altitude + a fudge factor and cap it at 12 m. I take the resulting array of elements and return the first element in that listing.

the next release will have this in a configuration step in the initialization.