mirror of
https://gitlab.com/ryandwyer/perfect-dark
synced 2026-08-18 13:13:11 -04:00
Rename hudmsg functions
This commit is contained in:
@@ -1584,7 +1584,7 @@ glabel var7f1ada9c
|
||||
/* f0d07e0: 0c004dad */ jal sprintf
|
||||
/* f0d07e4: 00403825 */ or $a3,$v0,$zero
|
||||
/* f0d07e8: 27a4006c */ addiu $a0,$sp,0x6c
|
||||
/* f0d07ec: 0fc377c7 */ jal currentPlayerQueueMessage
|
||||
/* f0d07ec: 0fc377c7 */ jal hudmsgCreateViaPreset
|
||||
/* f0d07f0: 00002825 */ or $a1,$zero,$zero
|
||||
/* f0d07f4: 10000033 */ beqz $zero,.L0f0d08c4
|
||||
/* f0d07f8: afa000a0 */ sw $zero,0xa0($sp)
|
||||
|
||||
@@ -4733,7 +4733,7 @@ glabel aiDuplicateChr
|
||||
/**
|
||||
* @cmd 00cb
|
||||
*/
|
||||
bool aiMessage(void)
|
||||
bool aiShowHudmsg(void)
|
||||
{
|
||||
u8 *cmd = g_Vars.ailist + g_Vars.aioffset;
|
||||
char *text = langGet(cmd[4] | (cmd[3] << 8));
|
||||
@@ -4747,7 +4747,7 @@ bool aiMessage(void)
|
||||
}
|
||||
|
||||
setCurrentPlayerNum(playernum);
|
||||
currentPlayerQueueMessage(text, 0);
|
||||
hudmsgCreateViaPreset(text, 0);
|
||||
setCurrentPlayerNum(prevplayernum);
|
||||
|
||||
g_Vars.aioffset += 5;
|
||||
@@ -4758,21 +4758,18 @@ bool aiMessage(void)
|
||||
/**
|
||||
* @cmd 01a4
|
||||
*/
|
||||
bool aiShowText(void)
|
||||
bool aiShowHudmsgMiddle(void)
|
||||
{
|
||||
u8 *cmd = g_Vars.ailist + g_Vars.aioffset;
|
||||
|
||||
// cmd[2] = prop
|
||||
// cmd[3] = color
|
||||
|
||||
if (cmd[2] == 0) {
|
||||
u32 text_id = cmd[5] | (cmd[4] << 8);
|
||||
char *text = langGet(text_id);
|
||||
func0f0de034(text, 7, cmd[3]);
|
||||
hudmsgCreateViaPresetWithColour(text, 7, cmd[3]);
|
||||
} else if (cmd[2] == 1) {
|
||||
u32 text_id = cmd[5] | (cmd[4] << 8);
|
||||
char *text = langGet(text_id);
|
||||
func0f0de034(text, 8, cmd[3]);
|
||||
hudmsgCreateViaPresetWithColour(text, 8, cmd[3]);
|
||||
} else {
|
||||
hudmsgRemoveAll();
|
||||
}
|
||||
@@ -4785,7 +4782,7 @@ bool aiShowText(void)
|
||||
/**
|
||||
* @cmd 00cc
|
||||
*/
|
||||
bool aiShowText2(void)
|
||||
bool aiShowHudmsgTopMiddle(void)
|
||||
{
|
||||
u8 *cmd = g_Vars.ailist + g_Vars.aioffset;
|
||||
char *text = langGet(cmd[4] | (cmd[3] << 8));
|
||||
@@ -4799,7 +4796,7 @@ bool aiShowText2(void)
|
||||
}
|
||||
|
||||
setCurrentPlayerNum(playernum);
|
||||
func0f0de034(text, 6, cmd[5]);
|
||||
hudmsgCreateViaPresetWithColour(text, 6, cmd[5]);
|
||||
setCurrentPlayerNum(prevplayernum);
|
||||
|
||||
g_Vars.aioffset += 6;
|
||||
@@ -7941,7 +7938,7 @@ glabel aiSayQuip
|
||||
/* f05a8a0: 8fa40080 */ lw $a0,0x80($sp)
|
||||
/* f05a8a4: 8fae009c */ lw $t6,0x9c($sp)
|
||||
/* f05a8a8: 24050006 */ addiu $a1,$zero,0x6
|
||||
/* f05a8ac: 0fc3780d */ jal func0f0de034
|
||||
/* f05a8ac: 0fc3780d */ jal hudmsgCreateViaPresetWithColour
|
||||
/* f05a8b0: 91c60009 */ lbu $a2,0x9($t6)
|
||||
/* f05a8b4: 100000be */ beqz $zero,.L0f05abb0
|
||||
/* f05a8b8: 00000000 */ sll $zero,$zero,0x0
|
||||
@@ -7964,7 +7961,7 @@ glabel aiSayQuip
|
||||
/* f05a8f8: 8fa40080 */ lw $a0,0x80($sp)
|
||||
/* f05a8fc: 8fac009c */ lw $t4,0x9c($sp)
|
||||
/* f05a900: 24050006 */ addiu $a1,$zero,0x6
|
||||
/* f05a904: 0fc3780d */ jal func0f0de034
|
||||
/* f05a904: 0fc3780d */ jal hudmsgCreateViaPresetWithColour
|
||||
/* f05a908: 91860009 */ lbu $a2,0x9($t4)
|
||||
/* f05a90c: 100000a8 */ beqz $zero,.L0f05abb0
|
||||
/* f05a910: 00000000 */ sll $zero,$zero,0x0
|
||||
@@ -8132,7 +8129,7 @@ glabel aiSayQuip
|
||||
/* f05ab6c: 8fa40080 */ lw $a0,0x80($sp)
|
||||
/* f05ab70: 8fab009c */ lw $t3,0x9c($sp)
|
||||
/* f05ab74: 24050006 */ addiu $a1,$zero,0x6
|
||||
/* f05ab78: 0fc3780d */ jal func0f0de034
|
||||
/* f05ab78: 0fc3780d */ jal hudmsgCreateViaPresetWithColour
|
||||
/* f05ab7c: 91660009 */ lbu $a2,0x9($t3)
|
||||
/* f05ab80: 1000000b */ beqz $zero,.L0f05abb0
|
||||
/* f05ab84: 00000000 */ sll $zero,$zero,0x0
|
||||
@@ -8339,14 +8336,14 @@ glabel aiSayQuip
|
||||
//
|
||||
// if (!audioIsFiltered(audioid)) {
|
||||
// // 8ac
|
||||
// func0f0de034(text, 6, cmd[9]);
|
||||
// hudmsgCreateViaPresetWithColour(text, 6, cmd[9]);
|
||||
// }
|
||||
// } else if (cmd[8]) {
|
||||
// text = langGet(g_QuipTexts[cmd[8] - 1][1 + g_Vars.chrdata->tude]);
|
||||
//
|
||||
// if (!audioIsFiltered(audioid)) {
|
||||
// // 904
|
||||
// func0f0de034(text, 6, cmd[9]);
|
||||
// hudmsgCreateViaPresetWithColour(text, 6, cmd[9]);
|
||||
// }
|
||||
// }
|
||||
// } else {
|
||||
@@ -8398,7 +8395,7 @@ glabel aiSayQuip
|
||||
//
|
||||
// if (!audioIsFiltered(audioid)) {
|
||||
// // b78
|
||||
// func0f0de034(text, 6, cmd[9]);
|
||||
// hudmsgCreateViaPresetWithColour(text, 6, cmd[9]);
|
||||
// }
|
||||
// }
|
||||
// } else {
|
||||
|
||||
@@ -3561,7 +3561,7 @@ u8 func0016_show_objective_failed_msg[] = {
|
||||
|
||||
// Show message first time
|
||||
label(0x13)
|
||||
message(CHR_BOND, L_MISC(69)) // "OBJECTIVES FAILED - abort mission."
|
||||
show_hudmsg(CHR_BOND, L_MISC(69)) // "OBJECTIVES FAILED - abort mission."
|
||||
|
||||
// Wait 60 seconds
|
||||
restart_timer
|
||||
@@ -3581,7 +3581,7 @@ u8 func0016_show_objective_failed_msg[] = {
|
||||
|
||||
// Show message second time
|
||||
label(0x13)
|
||||
message(CHR_BOND, L_MISC(69)) // "OBJECTIVES FAILED - abort mission."
|
||||
show_hudmsg(CHR_BOND, L_MISC(69)) // "OBJECTIVES FAILED - abort mission."
|
||||
restart_timer
|
||||
|
||||
// Wait 2 minutes
|
||||
@@ -3600,7 +3600,7 @@ u8 func0016_show_objective_failed_msg[] = {
|
||||
|
||||
// Show message third time
|
||||
label(0x13)
|
||||
message(CHR_BOND, L_MISC(69)) // "OBJECTIVES FAILED - abort mission."
|
||||
show_hudmsg(CHR_BOND, L_MISC(69)) // "OBJECTIVES FAILED - abort mission."
|
||||
restart_timer
|
||||
|
||||
// Wait 5 minutes
|
||||
|
||||
@@ -226,8 +226,8 @@ bool (*g_CommandPointers[])(void) = {
|
||||
/*0x00c8*/ aiTryEquipWeapon,
|
||||
/*0x00c9*/ aiTryEquipHat,
|
||||
/*0x00ca*/ aiDuplicateChr,
|
||||
/*0x00cb*/ aiMessage,
|
||||
/*0x00cc*/ aiShowText2,
|
||||
/*0x00cb*/ aiShowHudmsg,
|
||||
/*0x00cc*/ aiShowHudmsgTopMiddle,
|
||||
/*0x00cd*/ aiSpeak,
|
||||
/*0x00ce*/ aiPlaySound,
|
||||
/*0x00cf*/ ai00cf,
|
||||
@@ -443,7 +443,7 @@ bool (*g_CommandPointers[])(void) = {
|
||||
/*0x01a1*/ aiSetRoomToSearch,
|
||||
/*0x01a2*/ aiSayCiStaffQuip,
|
||||
/*0x01a3*/ aiDoPresetAnimation,
|
||||
/*0x01a4*/ aiShowText,
|
||||
/*0x01a4*/ aiShowHudmsgMiddle,
|
||||
/*0x01a5*/ ai01a5,
|
||||
/*0x01a6*/ aiIfTargetYDifferenceLessThan,
|
||||
/*0x01a7*/ aiIfChrPropsoundcountZero,
|
||||
|
||||
@@ -182,7 +182,7 @@ glabel func0f0b05a4
|
||||
/* f0b0610: 0c004dad */ jal sprintf
|
||||
/* f0b0614: 8d47001c */ lw $a3,0x1c($t2)
|
||||
/* f0b0618: 27a40038 */ addiu $a0,$sp,0x38
|
||||
/* f0b061c: 0fc377c7 */ jal currentPlayerQueueMessage
|
||||
/* f0b061c: 0fc377c7 */ jal hudmsgCreateViaPreset
|
||||
/* f0b0620: 00002825 */ or $a1,$zero,$zero
|
||||
/* f0b0624: 3c08800a */ lui $t0,%hi(g_Vars)
|
||||
/* f0b0628: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars)
|
||||
@@ -318,7 +318,7 @@ glabel func0f0b0764
|
||||
/* f0b07f8: 8fa60028 */ lw $a2,0x28($sp)
|
||||
/* f0b07fc: 27a40030 */ addiu $a0,$sp,0x30
|
||||
.L0f0b0800:
|
||||
/* f0b0800: 0fc377c7 */ jal currentPlayerQueueMessage
|
||||
/* f0b0800: 0fc377c7 */ jal hudmsgCreateViaPreset
|
||||
/* f0b0804: 00002825 */ or $a1,$zero,$zero
|
||||
/* f0b0808: 8fbf001c */ lw $ra,0x1c($sp)
|
||||
.L0f0b080c:
|
||||
@@ -378,7 +378,7 @@ glabel func0f0b0818
|
||||
/* f0b08c8: 0c004dad */ jal sprintf
|
||||
/* f0b08cc: 00403025 */ or $a2,$v0,$zero
|
||||
/* f0b08d0: 27a40040 */ addiu $a0,$sp,0x40
|
||||
/* f0b08d4: 0fc377c7 */ jal currentPlayerQueueMessage
|
||||
/* f0b08d4: 0fc377c7 */ jal hudmsgCreateViaPreset
|
||||
/* f0b08d8: 00002825 */ or $a1,$zero,$zero
|
||||
/* f0b08dc: 3c09800a */ lui $t1,%hi(g_Vars)
|
||||
/* f0b08e0: 25299fc0 */ addiu $t1,$t1,%lo(g_Vars)
|
||||
@@ -675,7 +675,7 @@ glabel func0f0b09f4
|
||||
/* f0b0cf8: 0c004dad */ jal sprintf
|
||||
/* f0b0cfc: 00403025 */ or $a2,$v0,$zero
|
||||
/* f0b0d00: 27a4003c */ addiu $a0,$sp,0x3c
|
||||
/* f0b0d04: 0fc377c7 */ jal currentPlayerQueueMessage
|
||||
/* f0b0d04: 0fc377c7 */ jal hudmsgCreateViaPreset
|
||||
/* f0b0d08: 00002825 */ or $a1,$zero,$zero
|
||||
.L0f0b0d0c:
|
||||
/* f0b0d0c: 0fc2c1d9 */ jal func0f0b0764
|
||||
@@ -758,7 +758,7 @@ glabel func0f0b09f4
|
||||
/* f0b0e1c: 0c004dad */ jal sprintf
|
||||
/* f0b0e20: 00403025 */ or $a2,$v0,$zero
|
||||
/* f0b0e24: 27a4003c */ addiu $a0,$sp,0x3c
|
||||
/* f0b0e28: 0fc377c7 */ jal currentPlayerQueueMessage
|
||||
/* f0b0e28: 0fc377c7 */ jal hudmsgCreateViaPreset
|
||||
/* f0b0e2c: 00002825 */ or $a1,$zero,$zero
|
||||
.L0f0b0e30:
|
||||
/* f0b0e30: 0fc2c169 */ jal func0f0b05a4
|
||||
|
||||
+13
-13
@@ -1270,9 +1270,9 @@ glabel func0f0ddeac
|
||||
/* f0ddf18: 00601025 */ or $v0,$v1,$zero
|
||||
);
|
||||
|
||||
void currentPlayerQueueMessage(char *text, s32 confignum)
|
||||
void hudmsgCreateViaPreset(char *text, s32 confignum)
|
||||
{
|
||||
func0f0deebc(text, confignum,
|
||||
hudmsgCreate(text, confignum,
|
||||
g_HudMessageConfigs[confignum].unk00,
|
||||
g_HudMessageConfigs[confignum].unk01,
|
||||
g_HudMessageConfigs[confignum].unk02,
|
||||
@@ -1289,7 +1289,7 @@ void currentPlayerQueueMessage(char *text, s32 confignum)
|
||||
|
||||
void func0f0ddfa4(char *text, s32 confignum, s32 arg2)
|
||||
{
|
||||
func0f0deebc(text, confignum,
|
||||
hudmsgCreate(text, confignum,
|
||||
g_HudMessageConfigs[confignum].unk00,
|
||||
g_HudMessageConfigs[confignum].unk01,
|
||||
g_HudMessageConfigs[confignum].unk02,
|
||||
@@ -1304,11 +1304,11 @@ void func0f0ddfa4(char *text, s32 confignum, s32 arg2)
|
||||
-1, arg2);
|
||||
}
|
||||
|
||||
void func0f0de034(char *text, s32 confignum, u8 colournum)
|
||||
void hudmsgCreateViaPresetWithColour(char *text, s32 confignum, u8 colournum)
|
||||
{
|
||||
g_HudMessageConfigs[confignum].colour = g_Colours[colournum];
|
||||
|
||||
func0f0deebc(text, confignum,
|
||||
hudmsgCreate(text, confignum,
|
||||
g_HudMessageConfigs[confignum].unk00,
|
||||
g_HudMessageConfigs[confignum].unk01,
|
||||
g_HudMessageConfigs[confignum].unk02,
|
||||
@@ -1323,9 +1323,9 @@ void func0f0de034(char *text, s32 confignum, u8 colournum)
|
||||
-1, 0);
|
||||
}
|
||||
|
||||
void func0f0de0d4(char *text, s32 confignum, struct hudmessageconfig *config, s32 arg3)
|
||||
void hudmsgCreateViaStruct(char *text, s32 confignum, struct hudmessageconfig *config, s32 arg3)
|
||||
{
|
||||
func0f0deebc(text, confignum,
|
||||
hudmsgCreate(text, confignum,
|
||||
config->unk00,
|
||||
config->unk01,
|
||||
config->unk02,
|
||||
@@ -1656,7 +1656,7 @@ glabel func0f0de160
|
||||
/* f0de5c4: 02c02025 */ or $a0,$s6,$zero
|
||||
/* f0de5c8: 4600328d */ trunc.w.s $f10,$f6
|
||||
/* f0de5cc: 44075000 */ mfc1 $a3,$f10
|
||||
/* f0de5d0: 0fc37835 */ jal func0f0de0d4
|
||||
/* f0de5d0: 0fc37835 */ jal hudmsgCreateViaStruct
|
||||
/* f0de5d4: 00000000 */ sll $zero,$zero,0x0
|
||||
/* f0de5d8: 24090072 */ addiu $t1,$zero,0x72
|
||||
/* f0de5dc: 240a0052 */ addiu $t2,$zero,0x52
|
||||
@@ -1682,7 +1682,7 @@ glabel func0f0de160
|
||||
/* f0de628: 8fa504c4 */ lw $a1,0x4c4($sp)
|
||||
/* f0de62c: 4600818d */ trunc.w.s $f6,$f16
|
||||
/* f0de630: 44073000 */ mfc1 $a3,$f6
|
||||
/* f0de634: 0fc37835 */ jal func0f0de0d4
|
||||
/* f0de634: 0fc37835 */ jal hudmsgCreateViaStruct
|
||||
/* f0de638: 00000000 */ sll $zero,$zero,0x0
|
||||
/* f0de63c: 24090072 */ addiu $t1,$zero,0x72
|
||||
/* f0de640: 240a0052 */ addiu $t2,$zero,0x52
|
||||
@@ -1733,7 +1733,7 @@ glabel func0f0de160
|
||||
/* f0de6dc: 46049202 */ mul.s $f8,$f18,$f4
|
||||
/* f0de6e0: 4600440d */ trunc.w.s $f16,$f8
|
||||
/* f0de6e4: 44078000 */ mfc1 $a3,$f16
|
||||
/* f0de6e8: 0fc37835 */ jal func0f0de0d4
|
||||
/* f0de6e8: 0fc37835 */ jal hudmsgCreateViaStruct
|
||||
/* f0de6ec: 00000000 */ sll $zero,$zero,0x0
|
||||
/* f0de6f0: 1000001b */ beqz $zero,.L0f0de760
|
||||
/* f0de6f4: 8fbf006c */ lw $ra,0x6c($sp)
|
||||
@@ -1762,7 +1762,7 @@ glabel func0f0de160
|
||||
/* f0de748: 860f0018 */ lh $t7,0x18($s0)
|
||||
/* f0de74c: afa00038 */ sw $zero,0x38($sp)
|
||||
/* f0de750: afb40034 */ sw $s4,0x34($sp)
|
||||
/* f0de754: 0fc37baf */ jal func0f0deebc
|
||||
/* f0de754: 0fc37baf */ jal hudmsgCreate
|
||||
/* f0de758: afaf0030 */ sw $t7,0x30($sp)
|
||||
.L0f0de75c:
|
||||
/* f0de75c: 8fbf006c */ lw $ra,0x6c($sp)
|
||||
@@ -1800,7 +1800,7 @@ glabel func0f0de160
|
||||
/* f0de7d8: afaa0028 */ sw $t2,0x28($sp)
|
||||
/* f0de7dc: afab002c */ sw $t3,0x2c($sp)
|
||||
/* f0de7e0: afac0030 */ sw $t4,0x30($sp)
|
||||
/* f0de7e4: 0fc37baf */ jal func0f0deebc
|
||||
/* f0de7e4: 0fc37baf */ jal hudmsgCreate
|
||||
/* f0de7e8: afad0034 */ sw $t5,0x34($sp)
|
||||
/* f0de7ec: 8fbf0044 */ lw $ra,0x44($sp)
|
||||
/* f0de7f0: 27bd0048 */ addiu $sp,$sp,0x48
|
||||
@@ -2320,7 +2320,7 @@ glabel var7f1adec0
|
||||
);
|
||||
|
||||
GLOBAL_ASM(
|
||||
glabel func0f0deebc
|
||||
glabel hudmsgCreate
|
||||
/* f0deebc: 27bdfe08 */ addiu $sp,$sp,-504
|
||||
/* f0deec0: afb10024 */ sw $s1,0x24($sp)
|
||||
/* f0deec4: 24110006 */ addiu $s1,$zero,0x6
|
||||
|
||||
@@ -5036,7 +5036,7 @@ glabel func0f16b96c
|
||||
/* f16c4b0: 0fc5b9f1 */ jal langGet
|
||||
/* f16c4b4: 24045844 */ addiu $a0,$zero,0x5844
|
||||
/* f16c4b8: 00402025 */ or $a0,$v0,$zero
|
||||
/* f16c4bc: 0fc377c7 */ jal currentPlayerQueueMessage
|
||||
/* f16c4bc: 0fc377c7 */ jal hudmsgCreateViaPreset
|
||||
/* f16c4c0: 00002825 */ or $a1,$zero,$zero
|
||||
/* f16c4c4: 8e99006c */ lw $t9,0x6c($s4)
|
||||
/* f16c4c8: 26100001 */ addiu $s0,$s0,0x1
|
||||
@@ -5697,7 +5697,7 @@ glabel func0f16b96c
|
||||
// s32 i;
|
||||
// for (i = 0; i < PLAYERCOUNT(); i++) {
|
||||
// setCurrentPlayerNum(i);
|
||||
// currentPlayerQueueMessage(langGet(L_MISC(68)), 0); // "One minute left."
|
||||
// hudmsgCreateViaPreset(langGet(L_MISC(68)), 0); // "One minute left."
|
||||
// }
|
||||
// }
|
||||
//
|
||||
|
||||
@@ -1674,7 +1674,7 @@ glabel func0f19df58
|
||||
/* f19e008: 0fc677c6 */ jal func0f19df18
|
||||
/* f19e00c: 90c40001 */ lbu $a0,0x1($a2)
|
||||
/* f19e010: 00402025 */ or $a0,$v0,$zero
|
||||
/* f19e014: 0fc377c7 */ jal currentPlayerQueueMessage
|
||||
/* f19e014: 0fc377c7 */ jal hudmsgCreateViaPreset
|
||||
/* f19e018: 2405000a */ addiu $a1,$zero,0xa
|
||||
/* f19e01c: 3c07800b */ lui $a3,%hi(var800acd20)
|
||||
/* f19e020: 24e7cd20 */ addiu $a3,$a3,%lo(var800acd20)
|
||||
|
||||
Reference in New Issue
Block a user