mirror of
https://github.com/LostArtefacts/TR2X.git
synced 2025-03-01 10:36:00 +00:00
port Option_Compass
This commit is contained in:
parent
7f383277ce
commit
9eaccd584e
@ -69,10 +69,10 @@
|
||||
</g>
|
||||
<g transform="translate(0 116)">
|
||||
<text x="0" y="7.50">Tomb2.exe progress according to the physical function order:</text>
|
||||
<text class="todo" style="font-size: 12px; " x="747" y="9"><tspan text-anchor="end"><tspan class="decompiled">56.98% (694)</tspan> · <tspan class="known">40.56% (494)</tspan> · <tspan class="todo">0% (0)</tspan> · <tspan class="unused">2.46% (30)</tspan></tspan></text>
|
||||
<text class="todo" style="font-size: 12px; " x="747" y="9"><tspan text-anchor="end"><tspan class="decompiled">57.06% (695)</tspan> · <tspan class="known">40.48% (493)</tspan> · <tspan class="todo">0% (0)</tspan> · <tspan class="unused">2.46% (30)</tspan></tspan></text>
|
||||
<g transform="translate(0 20)">
|
||||
<rect width="425.63" height="6" x="0" y="0" class="decompiled"/>
|
||||
<rect width="302.97" height="6" x="425.63" y="0" class="known"/>
|
||||
<rect width="426.24" height="6" x="0" y="0" class="decompiled"/>
|
||||
<rect width="302.36" height="6" x="426.24" y="0" class="known"/>
|
||||
<rect width="18.40" height="6" x="728.60" y="0" class="unused"/>
|
||||
</g>
|
||||
<g transform="translate(0 31)">
|
||||
@ -1125,7 +1125,7 @@
|
||||
<rect width="12" height="12" x="690" y="300" class="decompiled"><title>void __cdecl Option_Passport(INVENTORY_ITEM *item);</title></rect>
|
||||
<rect width="12" height="12" x="705" y="300" class="known"><title>void __cdecl Option_Detail(INVENTORY_ITEM *item);</title></rect>
|
||||
<rect width="12" height="12" x="720" y="300" class="known"><title>void __cdecl Option_Sound(INVENTORY_ITEM *item);</title></rect>
|
||||
<rect width="12" height="12" x="735" y="300" class="known"><title>void __cdecl Option_Compass(INVENTORY_ITEM *item);</title></rect>
|
||||
<rect width="12" height="12" x="735" y="300" class="decompiled"><title>void __cdecl Option_Compass(INVENTORY_ITEM *item);</title></rect>
|
||||
<rect width="12" height="12" x="0" y="315" class="known"><title>void __cdecl Option_Controls_FlashConflicts(void);</title></rect>
|
||||
<rect width="12" height="12" x="15" y="315" class="known"><title>void __cdecl Option_Controls_DefaultConflict(void);</title></rect>
|
||||
<rect width="12" height="12" x="30" y="315" class="known"><title>void __cdecl Option_Controls(INVENTORY_ITEM *item);</title></rect>
|
||||
@ -1298,10 +1298,10 @@
|
||||
</g>
|
||||
<g transform="translate(0 546)">
|
||||
<text x="0" y="7.50">Tomb2.exe progress according to the function sizes:</text>
|
||||
<text class="todo" style="font-size: 12px; " x="747" y="9"><tspan text-anchor="end"><tspan class="decompiled">60.31%</tspan> · <tspan class="known">39.36%</tspan> · <tspan class="todo">0%</tspan> · <tspan class="unused">0.33%</tspan></tspan></text>
|
||||
<text class="todo" style="font-size: 12px; " x="747" y="9"><tspan text-anchor="end"><tspan class="decompiled">60.37%</tspan> · <tspan class="known">39.30%</tspan> · <tspan class="todo">0%</tspan> · <tspan class="unused">0.33%</tspan></tspan></text>
|
||||
<g transform="translate(0 20)">
|
||||
<rect width="450.55" height="6" x="0" y="0" class="decompiled"/>
|
||||
<rect width="294.01" height="6" x="450.55" y="0" class="known"/>
|
||||
<rect width="450.97" height="6" x="0" y="0" class="decompiled"/>
|
||||
<rect width="293.59" height="6" x="450.97" y="0" class="known"/>
|
||||
<rect width="2.44" height="6" x="744.56" y="0" class="unused"/>
|
||||
</g>
|
||||
<g transform="translate(0 31)">
|
||||
@ -1763,7 +1763,7 @@
|
||||
<rect width="9.54" height="9.77" x="521.63" y="201.42" class="known"><title>int32_t __cdecl Inv_GetItemOption(GAME_OBJECT_ID object_num);</title></rect>
|
||||
<rect width="9.54" height="9.77" x="521.63" y="214.20" class="decompiled"><title>void __cdecl Gun_AimWeapon(WEAPON_INFO *winfo, LARA_ARM *arm);</title></rect>
|
||||
<rect width="9.54" height="9.71" x="521.63" y="226.97" class="known"><title>void __cdecl ChangeRequesterItem(REQUEST_INFO *req, int32_t item, const char *text1, uint32_t flags1, const char *text2, uint32_t flags2);</title></rect>
|
||||
<rect width="9.54" height="9.71" x="521.63" y="239.68" class="known"><title>void __cdecl Option_Compass(INVENTORY_ITEM *item);</title></rect>
|
||||
<rect width="9.54" height="9.71" x="521.63" y="239.68" class="decompiled"><title>void __cdecl Option_Compass(INVENTORY_ITEM *item);</title></rect>
|
||||
<rect width="9.54" height="9.71" x="521.63" y="252.39" class="known"><title>void __cdecl AnimateTextures(int32_t ticks);</title></rect>
|
||||
<rect width="9.54" height="9.64" x="521.63" y="265.09" class="known"><title>void __cdecl DeathSlideCollision(int16_t item_num, ITEM_INFO *lara_item, COLL_INFO *coll);</title></rect>
|
||||
<rect width="9.54" height="9.57" x="521.63" y="277.73" class="decompiled"><title>void __cdecl Lara_Col_StepRight(ITEM_INFO *item, COLL_INFO *coll);</title></rect>
|
||||
|
Before Width: | Height: | Size: 363 KiB After Width: | Height: | Size: 363 KiB |
@ -3976,7 +3976,7 @@ typedef enum {
|
||||
0x0044EED0 0x0648 + void __cdecl Option_Passport(INVENTORY_ITEM *item);
|
||||
0x0044F520 0x02DA - void __cdecl Option_Detail(INVENTORY_ITEM *item);
|
||||
0x0044F800 0x049D - void __cdecl Option_Sound(INVENTORY_ITEM *item);
|
||||
0x0044FCA0 0x00C0 - void __cdecl Option_Compass(INVENTORY_ITEM *item);
|
||||
0x0044FCA0 0x00C0 + void __cdecl Option_Compass(INVENTORY_ITEM *item);
|
||||
0x0044FD60 0x007E - void __cdecl Option_Controls_FlashConflicts(void);
|
||||
0x0044FDE0 0x0040 - void __cdecl Option_Controls_DefaultConflict(void);
|
||||
0x0044FE20 0x06F4 - void __cdecl Option_Controls(INVENTORY_ITEM *item);
|
||||
|
@ -14,4 +14,5 @@ void __cdecl Option_Sound_Shutdown(INVENTORY_ITEM *item);
|
||||
|
||||
void __cdecl Option_Controls_Shutdown(INVENTORY_ITEM *item);
|
||||
|
||||
void __cdecl Option_Compass(INVENTORY_ITEM *item);
|
||||
void __cdecl Option_Compass_Shutdown(INVENTORY_ITEM *item);
|
||||
|
@ -1,7 +1,31 @@
|
||||
#include "decomp/stats.h"
|
||||
#include "game/option/option.h"
|
||||
#include "game/sound.h"
|
||||
#include "global/funcs.h"
|
||||
#include "global/vars.h"
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
void __cdecl Option_Compass(INVENTORY_ITEM *const item)
|
||||
{
|
||||
char buffer[32];
|
||||
const int32_t sec = g_SaveGame.statistics.timer / FRAMES_PER_SECOND;
|
||||
sprintf(buffer, "%02d:%02d:%02d", sec / 3600, sec / 60 % 60, sec % 60);
|
||||
|
||||
if (g_CurrentLevel == LV_GYM) {
|
||||
ShowGymStatsText(buffer, 1);
|
||||
} else {
|
||||
ShowStatsText(buffer, 1);
|
||||
}
|
||||
|
||||
if ((g_InputDB & IN_SELECT) || (g_InputDB & IN_DESELECT)) {
|
||||
item->anim_direction = 1;
|
||||
item->goal_frame = item->frames_total - 1;
|
||||
}
|
||||
|
||||
Sound_Effect(SFX_MENU_STOPWATCH, 0, SPM_ALWAYS);
|
||||
}
|
||||
|
||||
void Option_Compass_Shutdown(INVENTORY_ITEM *const item)
|
||||
{
|
||||
Remove_Requester(&g_StatsRequester);
|
||||
|
@ -364,7 +364,6 @@
|
||||
#define CalculateWibbleTable ((void __cdecl (*)(void))0x0044D780)
|
||||
#define Option_Detail ((void __cdecl (*)(INVENTORY_ITEM *item))0x0044F520)
|
||||
#define Option_Sound ((void __cdecl (*)(INVENTORY_ITEM *item))0x0044F800)
|
||||
#define Option_Compass ((void __cdecl (*)(INVENTORY_ITEM *item))0x0044FCA0)
|
||||
#define Option_Controls_FlashConflicts ((void __cdecl (*)(void))0x0044FD60)
|
||||
#define Option_Controls_DefaultConflict ((void __cdecl (*)(void))0x0044FDE0)
|
||||
#define Option_Controls ((void __cdecl (*)(INVENTORY_ITEM *item))0x0044FE20)
|
||||
|
@ -345,6 +345,7 @@ static void Inject_Option(const bool enable)
|
||||
{
|
||||
INJECT(enable, 0x0044EDC0, Option_DoInventory);
|
||||
INJECT(enable, 0x0044EED0, Option_Passport);
|
||||
INJECT(enable, 0x0044FCA0, Option_Compass);
|
||||
}
|
||||
|
||||
static void Inject_Text(const bool enable)
|
||||
|
Loading…
x
Reference in New Issue
Block a user