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

Replace createVehicleCrew with fn_createCrew #963

Open
wants to merge 18 commits into
base: v0.96.8
Choose a base branch
from

Conversation

PiG13BR
Copy link

@PiG13BR PiG13BR commented Aug 28, 2024

Q A
Bug fix? no
New feature? no
Needs wipe? no

Description:

  • Ditch createVehicleCrew command and replace it with a function that uses preset configuration only. Now you can put a different faction assets in the same preset without spawning crew that not fit into your scenario.
  • The function checks what kind of vehicle is to get the correct type of crew.
  • The function tries to find empty seats for driver, gunner and commander. For the turret seat (generally from helicopters), only gets the co-pilot.

Content:

  • [ x] Add new function called fn_createCrew
  • [ x] Replace all createVehicleCrew command in the files
  • Put the new variables (used in the function) in other presets

Successfully tested on:

  • [ x] Local MP
  • [ x] Dedicated MP

@some-evil-kitty
Copy link
Collaborator

Most presets don't have pilots and crew defined yet - maybe add some logic inside the function to default to something if they're not defined? I was thinking rifleman for crew at the very least.

@PiG13BR
Copy link
Author

PiG13BR commented Sep 1, 2024

Yes, I can do that for now, but I could also add those variables on the other presets aswell, it's boring but I can do it with time. Tell me if this is worth it so I can manage my time to add them.

@PiG13BR
Copy link
Author

PiG13BR commented Sep 2, 2024

Done. I've put the placeholder types of crew that already exist on presets for each side.

@veteran29 veteran29 added the enhancement New feature or request label Oct 9, 2024
Missionframework/functions/fn_createCrew.sqf Outdated Show resolved Hide resolved
Missionframework/functions/fn_createCrew.sqf Outdated Show resolved Hide resolved
Missionframework/functions/fn_createCrew.sqf Outdated Show resolved Hide resolved
PiG13BR and others added 3 commits October 9, 2024 13:51
- Add BIS_fnc_vehicleCrewTurrets to simplify the script.
- Removed the MPKilled event (createManagedUnit already add this event)

Co-authored-by: Filip Maciejewski <[email protected]>
@veteran29 veteran29 added this to the v0.96.8 milestone Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants