Commit Graph
4053 Commits
Author SHA1 Message Date
Marco Antonio Jaguaribe Costaandmajcosta eca4086d30 inherit minimum cmake version from ja2
all this does is silence the warning that cmake 2.6 is deprecated, we're
never building bfVFS standalone anyway
2023-10-07 09:21:11 -03:00
AsdowandGitHub b8a870df02 Reduce code duplication (#233)
* Use ConvertGridNoToCenterCellXY instead of CenterX & CenterY

* Add direction utility function

We have a lot of places in the code that calculate direction based on center cell coordinates, but lack a utility function for it similar to other direction methods.

* Use utility function for calculating direction

* Use ConvertGridNoToCenterCellXY

* Use utility function for direction

* Use ConvertGridNoToCenterCellXY instead of CenterX & CenterY

* Use ConvertGridNoToCenterCellXY instead of CenterX & CenterY

* Remove CenterX & CenterY functions

Use ConvertGridNoToCenterCellXY instead

* Remove CenterX & CenterY calls from UB configuration

* Address review feedback

* Remove duplicate function

ConvertGridNoToCenterCellXY and ConvertMapPosToWorldTileCenter do the exact same thing

* Use PythSpacesAway instead of GetRangeFromGridNoDiff

Both functions calculate the same thing

* Remove GetRangeFromGridNoDiff

* Remove calls to abs()

The values end up being squared anyways making these unnecessary
2023-10-07 15:14:15 +03:00
Marco Antonio Jaguaribe Costaandmajcosta b68f206969 remove annoying warning on MSVC 19.37.32822
`register` keyword does exactly nothing:
https://learn.microsoft.com/en-us/cpp/error-messages/compiler-warnings/c5033?view=msvc-170
2023-10-07 09:13:55 -03:00
Andrzej FałkowskiandGitHub 8d49e74df4 Face gear render fixes (#232)
* Face gear is shaded the same as a face

* Render continue button above icons and facegear

* Face gear rendered below "hatch" (inactivity overlay)

* Consistent naming
2023-10-03 15:20:36 +03:00
Andrzej FałkowskiandGitHub 14ec138fc7 Fixed UI movement mode not switching to crawl on character collapse, leading to deadlocks (#231) 2023-10-02 19:32:15 +03:00
Andrzej FałkowskiandGitHub a3be3ecd7e Specific drug types and drug items for background and facilities. (#226) 2023-10-02 19:30:59 +03:00
Andrzej FałkowskiandGitHub 9033e1097a Radar and overhead map color variants (#219) 2023-10-02 19:30:17 +03:00
Xiaoxun92andGitHub 4ebae982dd Downgrade startup ini errors to warnings (#229) 2023-09-22 18:10:08 -07:00
sun-alfandGitHub 8a241d277d Merge pull request #228 from 1dot13/master_1dot13
[Fix] One of optimizations in (2482234e) commit is not suitable for M…
2023-09-14 00:37:04 +02:00
sun-alf 5bfd19e5a8 [Fix] One of optimizations in (2482234e) commit is not suitable for MOLLE stuff in 1.13
It is revealed, MOLLE things in 1.13 are configured in XMLs using both NAS and OAS (old attachment system) methods even if NAS is enabled in New Game Options. Given this, logic of SetAttachmentSlotsFlag() cannot be splitted onto NAS and OAS parts, and both Attachment[] and AttachmentPoints must be checked disregarding the NAS option.
2023-09-14 01:04:55 +03:00
KittyandGitHub 07591e50f5 Merge pull request #225 from zwwooooo/master
Chinese translation update(by TBS)
2023-09-11 17:07:21 +02:00
zwwooooo 556641377c Chinese translation update(by TBS) 2023-09-10 22:31:47 +08:00
zwwooooo 985dace82e Merge branch 'master' of github.com:1dot13/source 2023-09-10 22:03:41 +08:00
sun-alfandGitHub bb73a458ee Merge pull request #224 from 1dot13/master_1dot13
Master 1dot13
2023-09-10 10:21:03 +02:00
sun-alf f8637e5972 [~] Performance optimizations around Attachment[] and Launchable[] arrays
AIMNAS with its ~50K elements in Attachment[] suffered of performance drop when MOLLE stuff is in the visible inventory. To resolve it the following is done:
* Introduce gMAXATTACHMENTS_READ with actual number of elements in Attachment[]; according refactoring.
* Introduce gMAXLAUNCHABLES_READ with actual number of elements in Launchable[]; according refactoring.
* Introduce std::multimap AttachmentBackmap for quick access to attachments using itemId as a key.
* Sort Attachment[] by attachmentIndex right after loading from XML. According order in XML is not needed anymore.
* Introduce FindAttachmentRange() for quick access to attachments using attachmentId as a key (binary search in Attachment[]).
In a few words, GetHelpTextForItemInLaptop(), ValidAttachment(), SetAttachmentSlotsFlag() were heavily optimized.
2023-09-08 21:58:14 +03:00
sun-alf 4c861e441a [Fix] Revive FPS drawing overlay
To enable built-in FPS, change gbFPSDisplay to SHOW_FULL_FPS (1) in debugger (or change it in src code and rebuild).
2023-09-08 21:58:13 +03:00
AsdowandGitHub fc5573f73d Correct check for stance (#222)
Same issue as in commit 23ceb0f
2023-09-05 18:57:40 +03:00
AsdowandGitHub 23ceb0fa4c Fix bug in OCTH prone CTH calculation (by Seven) (#221)
GetToHitBonus() expects BOOLEAN for fProneStance argument, with no comparison to ANIM_PRONE, the ubEndHeight ends up adding bipod bonuses to *all* stances
2023-09-05 17:33:42 +03:00
rftrdevandGitHub 28aa73a859 Clamp coolness to valid values when generating ARC ammo cache (#220)
Fixes #217
2023-09-02 23:01:17 -07:00
KittyandGitHub cd186a2b1c Merge pull request #218 from andrzejfalkowski/loading-screens-multi-res
Loadscreen - Multiple resolutions and stretch modes
2023-09-02 16:13:52 +02:00
Andrzej Fałkowski 019b9c4907 Merge branch 'master' into loading-screens-multi-res 2023-08-31 23:29:21 +02:00
KittyandGitHub 5740a0af08 Merge pull request #214 from andrzejfalkowski/face-gear-offset-fix
Face gear offset fix
2023-08-30 19:42:55 +02:00
KittyandGitHub 9a46abe394 Merge pull request #215 from kitty624/Backgrounds
Fix character check for backgrounds during IMP creation
2023-08-30 19:40:31 +02:00
kitty624 7910be0ab7 Fix personality check for backgrounds during IMP creation 2023-08-30 19:34:30 +02:00
Andrzej Fałkowski ee3d2472e7 Removed unnecessary offset for face gear 2023-08-29 21:25:14 +02:00
Andrzej FałkowskiandGitHub 7edecd6849 Fixed vehicle body not properly removed when destroyed during ramming (#210) 2023-08-28 16:26:46 +03:00
Andrzej FałkowskiandGitHub d56288e313 Fixed incorrect vehicle group id after reloading the game and vehicle movement plot issues. (#207) 2023-08-28 16:26:34 +03:00
Andrzej FałkowskiandGitHub 3ddacf1a44 Fix vehicles consuming fuel after instant movement cancel (#213) 2023-08-28 16:26:02 +03:00
rftrdevandGitHub 8ec02b2d40 Add version info to main menu (#209) 2023-08-23 01:21:22 -07:00
rftrdevandGitHub 6bae48658e Fix personality check for backgrounds during IMP creation (#208) 2023-08-23 00:34:54 -07:00
KittyandGitHub 28a5c76775 Merge pull request #206 from kitty624/ExtraItems
Update XML.h

- added path to sub-directory for Extra Items
- to avoid cluttering up the parent directory when using this feature
- it allows to place extra items in sector via xml and based on difficulty level
- the new directory "ExtraItems" will contain more details on how-to-use
2023-08-22 00:36:01 +02:00
kitty624 1289c399ce Update XML.h
- added path to sub-directory for Extra Items
- to avoid cluttering up the parent directory when using this feature
- it allows to place extra items in sector via xml and based on difficulty level
- the new directory "ExtraItems" will contain more details on how-to-use
2023-08-22 00:22:20 +02:00
Andrzej FałkowskiandGitHub 1e1d456fd2 Prevent deadlocks due to self-healing interactive spots and self-attacking (#205) 2023-08-21 19:44:02 +03:00
Andrzej FałkowskiandGitHub 2060022e94 Battle Panel Multi Resolution (#203)
* Battle panel interface with support for multiple resolutions and scrollable list

* Support for localized versions of battle panel

* Removed commented out code

* Fixed wrong copypasta in German version
2023-08-20 20:52:34 +03:00
Andrzej Fałkowski 8f08eb15d2 Merge branch 'master' into loading-screens-multi-res 2023-08-19 23:02:54 +02:00
Andrzej Fałkowski 5400fb019d Loading screen multiple resolutions support and stretch modes, loading bar fixes 2023-08-19 22:30:57 +02:00
rftrdevandGitHub b91871b518 Move grenade bonuses from Demolitions to Throwing (#202)
* Copy grenade settings from demolitions to throwing

* Fix setting strings

* Add throwing bonuses to the same spots as demolitions

* Delete grenade bonuses from Demolitions

* Update text

* Reapply throwing check
2023-08-11 11:27:29 -07:00
rftrdevandGitHub aaeea9aac8 Replace evolution with growth rates (#201) 2023-08-09 18:36:44 -07:00
AsdowandGitHub 43c6943399 Don't modify gMAXITEM_READ when reading localized file (#198) 2023-08-04 14:25:35 +03:00
AsdowandGitHub 52ccc7cc3c Fix widescreen UI militia popup box y-coordinate (#196) 2023-08-04 13:45:54 +03:00
CptMooreandGitHub 200ac73f7a Merge pull request #195 from 1dot13/another-try-to-fix-latest-1
Update build.yml
2023-07-31 00:28:50 +02:00
CptMooreandGitHub 1bb8a214c9 Update build.yml 2023-07-31 00:28:42 +02:00
CptMooreandGitHub f78d91f3a3 Merge pull request #194 from 1dot13/another-try-to-fix-latest
Update build.yml
2023-07-30 23:34:09 +02:00
CptMooreandGitHub 32e49784a0 Update build.yml 2023-07-30 23:33:28 +02:00
CptMooreandGitHub 8824d32da9 Merge pull request #193 from 1dot13/correct-working-dir
Update build.yml
2023-07-30 19:23:13 +02:00
CptMooreandGitHub 2345dd0ae6 Update build.yml 2023-07-30 19:22:23 +02:00
CptMooreandGitHub cc6adb70f6 Merge pull request #191 from 1dot13/create-latest-tag-explicitly
Create latest tag explicitly
2023-07-30 09:53:06 +02:00
CptMooreandGitHub f16f137f2b Create latest tag explicitly
Apparently the github API does too much magic, lets hope removing a step will make it behave
2023-07-30 09:48:11 +02:00
majcostaandGitHub c8c7066969 Refactor merc backpack checking in FindBestPath (#162)
* remove unused fNonFenceJumper from AstarPathfinder::GetPath

* Extract backpack check into function and flip logic

Avoiding double negatives is nice
v1
2023-07-28 12:07:25 -03:00
majcostaandGitHub a0ac81aa65 Add support for AddressSanitizer instrumentation (#189)
To use, just set `ADDRESS_SANITIZER` to `ON` on the command-line or your
CMakeUserPresets.json file
2023-07-27 18:15:53 +03:00