tr2/data: add pickup item rotation injections

This adds injections to rotate pickup items to better suit 3D pickup
mode.

Resolves #1613.
This commit is contained in:
lahm86 2024-11-29 21:05:41 +00:00
parent 67a7531355
commit ae24a693ee
20 changed files with 53 additions and 6 deletions

View file

@ -7,7 +7,11 @@
{},
// 1. The Great Wall
{},
{
"injections": [
"data/injections/wall_itemrots.bin",
],
},
// 2. Venice
{},
@ -19,14 +23,23 @@
{
"injections": [
"data/injections/opera_fd.bin",
"data/injections/opera_itemrots.bin",
],
},
// 5. Offshore Rig
{},
{
"injections": [
"data/injections/rig_itemrots.bin",
],
},
// 6. Diving Area
{},
{
"injections": [
"data/injections/diving_itemrots.bin",
],
},
// 7. 40 Fathoms
{},
@ -35,6 +48,7 @@
{
"injections": [
"data/injections/wreck_fd.bin",
"data/injections/wreck_itemrots.bin",
],
},
@ -42,12 +56,17 @@
{},
// 10. The Deck
{},
{
"injections": [
"data/injections/deck_itemrots.bin",
],
},
// 11. Tibetan Foothills
{
"injections": [
"data/injections/tibet_fd.bin",
"data/injections/tibet_itemrots.bin",
],
"object_strings": {
"O_TIGER": "Snow Leopard",
@ -55,12 +74,17 @@
},
// 12. Barkhang Monastery
{},
{
"injections": [
"data/injections/barkhang_itemrots.bin",
],
},
// 13. Catacombs of the Talion
{
"injections": [
"data/injections/catacombs_fd.bin",
"data/injections/catacombs_itemrots.bin",
],
"object_strings": {
"O_TIGER": "Snow Leopard",
@ -71,6 +95,7 @@
{
"injections": [
"data/injections/palace_fd.bin",
"data/injections/palace_itemrots.bin",
],
"object_strings": {
"O_TIGER": "Snow Leopard",
@ -81,6 +106,7 @@
{
"injections": [
"data/injections/xian_fd.bin",
"data/injections/xian_itemrots.bin",
],
},
@ -88,6 +114,7 @@
{
"injections": [
"data/injections/floating_fd.bin",
"data/injections/floating_itemrots.bin",
],
},
@ -95,7 +122,11 @@
{},
// 18. Home Sweet Home
{},
{
"injections": [
"data/injections/house_itemrots.bin",
],
},
// 19. Demo 1
{},

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

@ -3,6 +3,7 @@
- added an option to fix inventory item usage duplication (#1586)
- added optional automatic key/puzzle inventory item pre-selection (#1884)
- added a search feature to the config tool (#1889)
- added an option to fix rotation on some pickup items to better suit 3D pickup mode (#1613)
- fixed a crash relating to audio decoding (#1895)
- fixed depth problems when drawing certain rooms (#1853, regression from 0.6)
- fixed Lara getting stuck in her hit animation if she is hit while mounting the boat or skidoo (#1606)

View file

@ -15,6 +15,7 @@ typedef struct {
struct {
bool enable_3d_pickups;
bool fix_item_rots;
} visuals;
struct {

View file

@ -4,6 +4,7 @@ CFG_BOOL(g_Config, gameplay.fix_item_duplication_glitch, false)
CFG_BOOL(g_Config, gameplay.enable_auto_item_selection, true)
CFG_BOOL(g_Config, gameplay.fix_floor_data_issues, true)
CFG_BOOL(g_Config, visuals.enable_3d_pickups, true)
CFG_BOOL(g_Config, visuals.fix_item_rots, true)
CFG_ENUM(g_Config, rendering.screenshot_format, SCREENSHOT_FORMAT_JPEG, SCREENSHOT_FORMAT)
CFG_INT32(g_Config, rendering.turbo_speed, 0)
CFG_INT32(g_Config, input.keyboard_layout, INPUT_LAYOUT_DEFAULT)

View file

@ -21,6 +21,7 @@ typedef enum {
typedef enum {
INJ_GENERAL = 0,
INJ_FLOOR_DATA = 4,
INJ_ITEM_POSITION = 7,
} INJECTION_TYPE;
typedef enum {
@ -89,6 +90,9 @@ static void M_LoadFromFile(INJECTION *const injection, const char *filename)
case INJ_FLOOR_DATA:
injection->relevant = g_Config.gameplay.fix_floor_data_issues;
break;
case INJ_ITEM_POSITION:
injection->relevant = g_Config.visuals.fix_item_rots;
break;
default:
LOG_WARNING("%s is of unknown type %d", filename, injection->type);
break;

View file

@ -33,6 +33,10 @@
"Title": "Fix floor data issues",
"Description": "Fixes original issues with floor data/triggers."
},
"fix_item_rots": {
"Title": "Fix item rotation issues",
"Description": "Fixes original issues with some incorrectly rotated pickups when using the 3D pickups option."
},
"enable_auto_item_selection": {
"Title": "Key item pre-selection",
"Description": "When Lara presses action against a keyhole or puzzle slot, and she has the corresponding item in the inventory, that item will be pre-selected."

View file

@ -31,6 +31,11 @@
"Field": "fix_floor_data_issues",
"DataType": "Bool",
"DefaultValue": true
},
{
"Field": "fix_item_rots",
"DataType": "Bool",
"DefaultValue": true
}
]
},