Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vehicle quick mount #4931

Merged
merged 8 commits into from
Jun 2, 2017
Merged

Vehicle quick mount #4931

merged 8 commits into from
Jun 2, 2017

Conversation

jameslkingsley
Copy link
Contributor

When merged this pull request will:

  • Add the quick-mount keybind that when pressed will mount the player into the vehicle based on direction and distance

The idea of this module is to provide a fail-safe for when action menus fail to appear when you're trying to quickly mount a vehicle. An example is when you're running towards an extraction helicopter and you're unable to get in when in real life you know you should be able to.

Demonstration: https://www.youtube.com/watch?v=3LWhYdG02xQ

I still need to convert it to ACE, just leaving it here for now.

@PabstMirror
Copy link
Contributor

Ref ACEX PR: acemod/ACEX#29

@PabstMirror PabstMirror added the kind/enhancement Release Notes: **IMPROVED:** label Feb 21, 2017
@jonpas jonpas added this to the 3.10.0 milestone Feb 21, 2017
_sortedSeats append _seats;

{
private _unit = _target call compile format ["assigned%1 _this", _x];
Copy link
Contributor

@commy2 commy2 Feb 22, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

???

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's to avoid repeating code

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

assignedDriver does not report the driver of a vehicle etc.

{
private _unit = _target call compile format ["assigned%1 _this", _x];

if (_unit isEqualType objNull && {!isNull _unit} && {!alive _unit}) exitWith {
Copy link
Contributor

@commy2 commy2 Feb 22, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

_unit isEqualType objNull
As opposed to what?
If it's not OBJECT, line 65 will error anyway.

Copy link
Member

@jonpas jonpas Feb 25, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does line 65 have to do with _unit? It's not even used after this exitWith block.

@bux
Copy link
Member

bux commented Feb 26, 2017

Well made video @jameslkingsley

@jonpas jonpas changed the title Vehicle quick mount (WIP) Vehicle quick mount Mar 24, 2017
Copy link
Contributor

@PabstMirror PabstMirror left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't quick mount into a AH-9 that has a pilot.
Problem seen else where in ace, it's a copilot seat that's also a turret.

class ACE_Module;
class GVAR(module): ACE_Module {
author = ECSTRING(common,ACETeam);
category = "ACEX";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"ACE"

{ACE_player getVariable ["ace_unconscious", false]}
) exitWith {};

private _start = AGLtoASL positionCameraToWorld [0, 0, 0];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

private _start = AGLtoASL (ACE_player modelToWorldVisual (ACE_player selectionPosition "pilot"));
I think this will work a lot better for people using 3rd person

@PabstMirror
Copy link
Contributor

Tweaked the seat search to use fullCrew
handles copilots and turret gunners better.
e.g. the ghosthawk only showed 10 emptyPosition but holds 12

Copy link
Contributor

@PabstMirror PabstMirror left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested this on several vehicles and seems to be working correctly

@PabstMirror PabstMirror merged commit 4872e18 into acemod:master Jun 2, 2017
@jameslkingsley jameslkingsley deleted the quickmount branch June 9, 2017 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Release Notes: **IMPROVED:**
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants