#include "game_types.h"

/* Level_Veneer459C @ 0x0800459C (real 98B) -- halfword compare selected by word-15 tag (4/2/other). Mirrors src/matched/Level_Veneer459C.c. */
/* Dispatches on word 15: tag 4 yields 1; tag 2 yields (x >= y); any other
   tag yields (x != y), over the halfwords at +136. */
int Level_Veneer459C(char *a, char *b)
{
    int k = ((int *)b)[15];
    short x = *(short *)(a + 136);
    short y = *(short *)(b + 136);
    if (k == 4)
        return 1;
    if (k == 2)
        return x >= y;
    return x != y;
}
