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

Fix multiple rebel squad/vehicle price bugs #2151

Merged

Conversation

jaj22
Copy link

@jaj22 jaj22 commented Sep 27, 2021

What type of PR is this.

  1. Bug
  2. Change
  3. Enhancement

What have you changed and why?

Both constructed and single-vehicle AA trucks were being underpriced on purchase due to not calculating truck + static AA costs as the other code did. This PR fixes this for both cases with a horrible hack.

Edit: Additional vehicle price bugs fixed:

  • Fixed doubled check price for AA and AT vehicles (missing isInfantry check).
  • Fixed AT car check price adding SDKTruck price.
  • Fixed ancient bug where zu-23 rebel AA trucks were not refunded on dismissal.
  • Fixed bug where vanilla AA trucks were double-refunded.
  • Fixed misleading error message when you didn't have enough money to purchase a transport vehicle.
  • Fixed wrong price shown for transport vehicle.
  • Fixed squad mortars and MGs not being charged for.

Please specify which Issue this PR Resolves.

closes #2150
closes #2152

Please verify the following and ensure all checks are completed.

  1. Have you loaded the mission in LAN host?
  2. Have you loaded the mission on a dedicated server?

Is further testing or are further changes required?

  1. No
  2. Yes (Please provide further detail below.)

@jaj22 jaj22 added the Bug-fix label Sep 27, 2021
@jaj22 jaj22 added this to the 2.5.3 milestone Sep 27, 2021
@jaj22 jaj22 changed the title Fix cheap rebel AA trucks Fix multiple rebel squad/vehicle price bugs Sep 29, 2021
@jaj22 jaj22 added the Don't merge This needs to be touched before being merged label Sep 29, 2021
@jaj22 jaj22 added Exploit Issue/PR that addresses an exploit. and removed Don't merge This needs to be touched before being merged labels Sep 30, 2021
@jaj22 jaj22 requested a review from HakonRydland October 1, 2021 13:26
Copy link
Collaborator

@HakonRydland HakonRydland left a comment

Choose a reason for hiding this comment

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

one small change and a clerification

A3-Antistasi/REINF/dismissSquad.sqf Outdated Show resolved Hide resolved
A3-Antistasi/REINF/dismissSquad.sqf Show resolved Hide resolved
@jaj22
Copy link
Author

jaj22 commented Oct 1, 2021

Changed to only attempt attached-vehicle refunds if they're in vehFIA. Anything else is left alone (or dumped on the ground, if the parent object is deleted).

@Bob-Murphy Bob-Murphy merged commit 5f177b9 into official-antistasi-community:unstable Oct 2, 2021
@Bob-Murphy Bob-Murphy added the Added to changelog Added to changelog label Oct 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Added to changelog Added to changelog Exploit Issue/PR that addresses an exploit. Ready for merge
Projects
None yet
3 participants