-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #25 from OverlordZorn/slingload-cargoOwner
add Slingload CargoOwner Function
- Loading branch information
Showing
3 changed files
with
54 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,7 @@ | ||
*.pbo | ||
.hemttout | ||
/.hemttout/* | ||
hemtt | ||
hemtt.exe | ||
*.biprivatekey | ||
.vscode | ||
releases/cvo_aux-latest.zip | ||
releases/cvo_aux-0.1.1-9515.zip | ||
/releases | ||
/releases/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
/* | ||
* Author: Zorn | ||
* Adds eventhandler to the helicopter to change the owner of sling loaded cargo. | ||
* To be used in the helicopters init attribute field. | ||
* | ||
* Arguments: | ||
* | ||
* Return Value: | ||
* None | ||
* | ||
* Example: | ||
* [this] call CVO_Common_fnc_slingload_cargoOwner; | ||
* Public: Yes | ||
*/ | ||
|
||
params [ | ||
["_heli", objNull, [objNull]] | ||
]; | ||
|
||
if (isServer) then { | ||
_heli addEventHandler ["RopeAttach", { | ||
params ["_heli", "_rope", "_cargo"]; | ||
_cargo setOwner (owner driver _heli); | ||
}]; | ||
|
||
_heli addEventHandler ["RopeBreak", { | ||
params ["_heli", "_rope", "_cargo"]; | ||
_cargo setOwner 2; | ||
}]; | ||
}; | ||
|
||
|
||
|
||
|
||
|
||
/* | ||
if (isServer) then { | ||
this addEventHandler ["RopeAttach", { | ||
params ["_heli", "_rope", "_cargo"]; | ||
_cargo setOwner (owner driver _heli); | ||
}]; | ||
this addEventHandler ["RopeBreak", { | ||
params ["_heli", "_rope", "_cargo"]; | ||
_cargo setOwner 2; | ||
}]; | ||
}; | ||
*/ |