// File: /workspace/github_c_makefile_star2_O1/garnett1966[P]Mystery-Mansion/src/mansion.c
// Function: MMRI
void MMRI(IV, IRS)
	int IV;
	int IRS;
{
	int J;

	IR=ITST[1];
	IC=0;
	for (J=1; J<=53; J++) {
		if ((IV == 1) && ((IVEN[J] > 10000) || 
		    ((IVEN[J]-100*(IVEN[J]/100)) != IR))) continue;
		if ((IV == 2) && (IVEN[J] < 20000)) continue;
		if ((IV == 4) && (IRS != J)) continue;
		if ((IV == 3) && ((IVEN[J] < 10000) || (IVEN[J] > 20000) ||
		    (IFSD(IVEN[J]) != IRS))) continue;
		if ((IV == 1) && (J == 4) && ((IVEN[4] == 493) ||
		    (IVEN[4] == 1493))) continue;
		if ((IV == 1) && (J == 5) && (IVEN[5] == 1316)) continue;
		if ((IV == 1) && (J == 17) && (IVEN[17] == 1141)) continue;
		if ((IV == 1) && (J == 19) && (IR == 16)) continue;
		if ((IV == 1) && (J == 29) && (IVEN[29] == 1214)) continue;
		if ((IV == 1) && (J == 30) && (IR == 25)) continue;
		if ((IV == 1) && (J == 37) && (IVEN[37] == 1153)) continue;
		if ((IV == 1) && (J == 39) && (IVEN[39] == 1253)) continue;
		if ((IV == 1) && (J == 40) && (IVEN[40] == 1151)) continue;
		if ((IV == 1) && (J == 42) && (IVEN[42] == 1151)) continue;
		if ((IV == 1) && (J == 46) && (IVEN[46] == 1101)) continue;
		if ((IV == 1) && (J == 28) && (IVEN[28] == 1184)) continue;
		if ((IV == 1) && (IC == 0)) printf("\n\nYOU CAN SEE:");
		if ((IV == 2) && (J == 53)) continue;
		if (J == 1) printf("\nTHE VAMPIRE RING ");
		if (J == 2) printf("\nA SET OF KEYS    ");
		if (J == 3) printf("\nA WIND UP CLOCK  ");
		if (J == 4) printf("\nA BATTERY LANTERN");
		if (J == 5) printf("\nA SILVER CROSS   ");
		if (J == 6) printf("\nA POCKET COMPASS ");
		if (J == 7) printf("\nA PIRATE TREASURE");
		if (J == 8) printf("\nA NEW BATTERY    ");
		if (J == 9) printf("\nA HAND GUN       ");
		if (J == 10) printf("\nA BUTCHER KNIFE  ");
		if (J == 11) printf("\nA TWO BLADED AXE ");
		if (J == 12) printf("\nA SWORD          ");
		if ((J == 13) && (ITST[10] != 13)) 
			printf("\nA VIAL OF POISON ");
		if ((J == 13) && (ITST[10] == 13)) 
			printf("\nAN EMPTY VIAL    ");
		if (J == 14) printf("\nA CLUB           ");
		if (J == 15) printf("\nA COIL OF ROPE   ");
		if (J == 16) printf("\nA DESK CHAIR     ");
		if (J == 17) printf("\nAN UNEVEN AMULET ");
		if (J == 18) printf("\nAN OLD TALISMAN  ");
		if ((J == 19) && (IFD(IVEN[19]) == 1)) 
			printf("\nA LIT CANDLE     ");
		if ((J == 19) && (IFD(IVEN[19]) != 1)) 
			printf("\nA CANDLE         ");
		if (J == 20) printf("\nA SILVER BULLET  ");
		if (J == 21) printf("\nA BOOK           ");
		if (J == 22) printf("\nA NOTE           ");
		if (J == 23) printf("\nA MATTER XMITTER ");
		if (J == 24) printf("\nSOME FOOD        ");
		if (J == 25) printf("\nA WITCH'S BROOM  ");
		if (J == 26) printf("\nA MATTER RECEIVER");
		if ((J == 27) && (IFD(IVEN[27]) == 1)) 
			printf("\nA BURNING TORCH  ");
		if ((J == 27) && (IFD(IVEN[27]) != 1)) 
			printf("\nA USELESS TORCH  ");
		if (J == 28) printf("\nA SMALL ROAD MAP ");
		if (J == 29) printf("\nA WOODEN WEDGE   ");
		if (J == 30) printf("\nA DUSTY GLOBE    ");
		if (J == 31) printf("\nA KITCHEN MATCH  ");
		if (J == 32) printf("\nA RUSTY SHOVEL   ");
		if (J == 33) printf("\nA SMALL OILCAN   ");
		if (J == 34) printf("\nA GREASY HATCHET ");
		if (J == 35) printf("\nA MYSTERY CHEST  ");
		if (J == 36) printf("\nA BAG OF PEARLS  ");
		if (J == 37) printf("\nA LARGE EMERALD  ");
		if (J == 38) printf("\nTWELVE GOLD COINS");
		if (J == 39) printf("\nA SILVER GOBLET  ");
		if (J == 40) printf("\nSEVERAL DIAMONDS ");
		if (J == 41) printf("\nSOME FINE JEWELRY");
		if (J == 42) printf("\nA RUBY NECKLACE  ");
		if (J == 43) printf("\nA JEWELED CROWN  ");
		if (J == 44) printf("\nSOME DARTS       ");
		if (J == 45) printf("\nA METAL SHIELD   ");
		if (J == 46) printf("\nA DUNGEON KEY    ");
		if (J == 47) printf("\nAN OLD BATTERY   ");
		if (J == 48) printf("\nA GAUDY GAUNTLET ");
		if (J == 49) printf("\nA PARANOID PARROT");
		if (J == 50) printf("\nA MENACING MACE  ");
		if (J == 51) printf("\nA BLANK          ");
		if (J == 52) printf("\nA BLANK          ");
		if (J == 53) printf("\nYOUR CLOTHES     ");
		IC=1;
	}
	if (((IV == 2) || (IV == 3)) && (IC == 0))
		printf("\nNOTHING");
	return;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %ebx
movl 0x2006c(%rip), %eax     # 0x23374
movl %eax, 0x206b2(%rip)     # 0x239c0
movl $0x0, 0x206ac(%rip)     # 0x239c4
movl %esi, %r12d
movl $0x1, %r13d
leaq 0x12130(%rip), %r14     # 0x15458
leaq 0x1f871(%rip), %r15     # 0x22ba0
movsd 0x11cd1(%rip), %xmm1    # 0x15008
leaq 0x12126(%rip), %rsi     # 0x15464
leaq 0x1213b(%rip), %r8      # 0x15480
leaq 0x12dba(%rip), %r9      # 0x16106
cmpl $0x1, %ebx
jne 0x3388
movl (%r15,%r13,4), %eax
cmpl $0x2710, %eax           # imm = 0x2710
jg 0x3a2c
movslq %eax, %rcx
imulq $0x51eb851f, %rcx, %rcx # imm = 0x51EB851F
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x25, %rcx
addl %edx, %ecx
imull $0x64, %ecx, %ecx
subl %ecx, %eax
cmpl 0x2063e(%rip), %eax     # 0x239c0
jne 0x3a2c
cmpl $0x2, %ebx
jne 0x33b0
cmpl $0x4, %ebx
setne %al
cmpq %r13, %r12
sete %cl
cmpl $0x4e20, (%r15,%r13,4)  # imm = 0x4E20
jl 0x3a2c
orb %cl, %al
jne 0x33c4
jmp 0x3a2c
cmpl $0x4, %ebx
sete %al
cmpq %r13, %r12
setne %cl
testb %cl, %al
jne 0x3a2c
cmpl $0x3, %ebx
jne 0x33fc
movl (%r15,%r13,4), %eax
leal -0x4e21(%rax), %ecx
cmpl $0xffffd8ef, %ecx       # imm = 0xFFFFD8EF
jb 0x3a2c
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
divsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
imull $-0x64, %ecx, %ecx
addl %eax, %ecx
cmpl %r12d, %ecx
jne 0x3a2c
cmpl $0x1, %ebx
setne %al
cmpq $0x4, %r13
setne %cl
orb %al, %cl
jne 0x3429
movl 0x1f79d(%rip), %eax     # 0x22bb0
cmpl $0x1ed, %eax            # imm = 0x1ED
je 0x3a2c
cmpl $0x5d5, %eax            # imm = 0x5D5
je 0x3a2c
cmpl $0x1, %ebx
jne 0x3444
cmpq $0x5, %r13
jne 0x3444
cmpl $0x524, 0x1f776(%rip)   # imm = 0x524
je 0x3a2c
cmpl $0x1, %ebx
jne 0x345f
cmpq $0x11, %r13
jne 0x345f
cmpl $0x475, 0x1f78b(%rip)   # imm = 0x475
je 0x3a2c
cmpl $0x1, %ebx
sete %al
cmpq $0x13, %r13
sete %cl
andb %al, %cl
movl 0x2054c(%rip), %eax     # 0x239c0
cmpl $0x10, %eax
sete %dl
testb %dl, %cl
jne 0x3a2c
cmpl $0x1, %ebx
jne 0x349d
cmpq $0x1d, %r13
jne 0x349d
cmpl $0x4be, 0x1f77d(%rip)   # imm = 0x4BE
je 0x3a2c
cmpl $0x1, %ebx
sete %cl
cmpq $0x1e, %r13
sete %dl
andb %cl, %dl
cmpl $0x19, %eax
sete %al
testb %al, %dl
jne 0x3a2c
cmpl $0x1, %ebx
jne 0x34d5
cmpq $0x25, %r13
jne 0x34d5
cmpl $0x481, 0x1f765(%rip)   # imm = 0x481
je 0x3a2c
cmpl $0x1, %ebx
jne 0x34f0
cmpq $0x27, %r13
jne 0x34f0
cmpl $0x4e5, 0x1f752(%rip)   # imm = 0x4E5
je 0x3a2c
cmpl $0x1, %ebx
jne 0x350b
cmpq $0x28, %r13
jne 0x350b
cmpl $0x47f, 0x1f73b(%rip)   # imm = 0x47F
je 0x3a2c
cmpl $0x1, %ebx
jne 0x3526
cmpq $0x2a, %r13
jne 0x3526
cmpl $0x47f, 0x1f728(%rip)   # imm = 0x47F
je 0x3a2c
cmpl $0x1, %ebx
jne 0x3541
cmpq $0x2e, %r13
jne 0x3541
cmpl $0x44d, 0x1f71d(%rip)   # imm = 0x44D
je 0x3a2c
cmpl $0x1, %ebx
jne 0x355c
cmpq $0x1c, %r13
jne 0x355c
cmpl $0x4a0, 0x1f6ba(%rip)   # imm = 0x4A0
je 0x3a2c
cmpl $0x1, %ebx
jne 0x3595
cmpl $0x0, 0x2045c(%rip)     # 0x239c4
jne 0x3595
leaq 0x12926(%rip), %rdi     # 0x15e97
xorl %eax, %eax
callq 0x3070
leaq 0x12b87(%rip), %r9      # 0x16106
leaq 0x11efa(%rip), %r8      # 0x15480
leaq 0x11ed7(%rip), %rsi     # 0x15464
movsd 0x11a73(%rip), %xmm1    # 0x15008
cmpl $0x2, %ebx
sete %al
cmpq $0x35, %r13
sete %cl
testb %cl, %al
jne 0x3a2c
cmpq $0x3, %r13
ja 0x35d9
movslq (%r14), %rdi
leaq 0x11e9e(%rip), %rax     # 0x15458
addq %rax, %rdi
xorl %eax, %eax
callq 0x3070
leaq 0x12b3b(%rip), %r9      # 0x16106
leaq 0x11eae(%rip), %r8      # 0x15480
leaq 0x11e8b(%rip), %rsi     # 0x15464
cmpq $0x4, %r13
jne 0x3602
leaq 0x128f9(%rip), %rdi     # 0x15edf
xorl %eax, %eax
callq 0x3070
leaq 0x12b12(%rip), %r9      # 0x16106
leaq 0x11e85(%rip), %r8      # 0x15480
leaq 0x11e62(%rip), %rsi     # 0x15464
cmpq $0x5, %r13
jne 0x362b
leaq 0x128e3(%rip), %rdi     # 0x15ef2
xorl %eax, %eax
callq 0x3070
leaq 0x12ae9(%rip), %r9      # 0x16106
leaq 0x11e5c(%rip), %r8      # 0x15480
leaq 0x11e39(%rip), %rsi     # 0x15464
leaq -0x6(%r13), %rax
cmpl $0x6, %eax
ja 0x3652
movl %eax, %eax
movslq (%rsi,%rax,4), %rdi
addq %rsi, %rdi
xorl %eax, %eax
callq 0x3070
leaq 0x12abb(%rip), %r9      # 0x16106
leaq 0x11e2e(%rip), %r8      # 0x15480
cmpq $0xd, %r13
jne 0x367d
cmpl $0xd, 0x1fd39(%rip)     # 0x23398
je 0x367d
leaq 0x12922(%rip), %rdi     # 0x15f8a
xorl %eax, %eax
callq 0x3070
leaq 0x12a90(%rip), %r9      # 0x16106
leaq 0x11e03(%rip), %r8      # 0x15480
cmpq $0xd, %r13
jne 0x36a8
cmpl $0xd, 0x1fd0e(%rip)     # 0x23398
jne 0x36a8
leaq 0x1290a(%rip), %rdi     # 0x15f9d
xorl %eax, %eax
callq 0x3070
leaq 0x12a65(%rip), %r9      # 0x16106
leaq 0x11dd8(%rip), %r8      # 0x15480
leaq -0xe(%r13), %rax
cmpl $0x2, %eax
ja 0x36c8
movl %eax, %eax
movslq (%r8,%rax,4), %rdi
addq %r8, %rdi
xorl %eax, %eax
callq 0x3070
leaq 0x12a3e(%rip), %r9      # 0x16106
cmpq $0x11, %r13
jne 0x36e3
leaq 0x12914(%rip), %rdi     # 0x15fe9
xorl %eax, %eax
callq 0x3070
leaq 0x12a23(%rip), %r9      # 0x16106
cmpq $0x12, %r13
jne 0x36fe
leaq 0x1290c(%rip), %rdi     # 0x15ffc
xorl %eax, %eax
callq 0x3070
leaq 0x12a08(%rip), %r9      # 0x16106
cmpq $0x13, %r13
jne 0x37a8
movslq 0x1f4dd(%rip), %rax     # 0x22bec
imulq $0x10624dd3, %rax, %rcx # imm = 0x10624DD3
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x26, %rcx
addl %edx, %ecx
imulq $0x68db8bad, %rax, %rax # imm = 0x68DB8BAD
movq %rax, %rdx
shrq $0x3f, %rdx
sarq $0x2c, %rax
addl %edx, %eax
addl %eax, %eax
leal (%rax,%rax,4), %eax
subl %eax, %ecx
cmpl $0x1, %ecx
jne 0x3758
leaq 0x128c5(%rip), %rdi     # 0x1600f
xorl %eax, %eax
callq 0x3070
leaq 0x129ae(%rip), %r9      # 0x16106
movslq 0x1f48d(%rip), %rax     # 0x22bec
imulq $0x10624dd3, %rax, %rcx # imm = 0x10624DD3
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x26, %rcx
addl %edx, %ecx
imulq $0x68db8bad, %rax, %rax # imm = 0x68DB8BAD
movq %rax, %rdx
shrq $0x3f, %rdx
sarq $0x2c, %rax
addl %edx, %eax
addl %eax, %eax
leal (%rax,%rax,4), %eax
subl %eax, %ecx
cmpl $0x1, %ecx
je 0x37a8
leaq 0x12888(%rip), %rdi     # 0x16022
xorl %eax, %eax
callq 0x3070
leaq 0x1295e(%rip), %r9      # 0x16106
leal -0x14(%r13), %eax
cmpl $0x7, %eax
ja 0x38b8
leaq 0x119ec(%rip), %rcx     # 0x151a8
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
leaq 0x1286b(%rip), %rdi     # 0x16035
jmpq *%rax
leaq 0x12875(%rip), %rdi     # 0x16048
jmp 0x3800
leaq 0x12892(%rip), %rdi     # 0x1606e
jmp 0x3800
leaq 0x12876(%rip), %rdi     # 0x1605b
jmp 0x3800
leaq 0x128b9(%rip), %rdi     # 0x160a7
jmp 0x3800
leaq 0x1288a(%rip), %rdi     # 0x16081
jmp 0x3800
leaq 0x12894(%rip), %rdi     # 0x16094
xorl %eax, %eax
callq 0x3070
leaq 0x128f8(%rip), %r9      # 0x16106
cmpq $0x1b, %r13
jne 0x38b8
movslq 0x1f3ed(%rip), %rax     # 0x22c0c
imulq $0x10624dd3, %rax, %rcx # imm = 0x10624DD3
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x26, %rcx
addl %edx, %ecx
imulq $0x68db8bad, %rax, %rax # imm = 0x68DB8BAD
movq %rax, %rdx
shrq $0x3f, %rdx
sarq $0x2c, %rax
addl %edx, %eax
addl %eax, %eax
leal (%rax,%rax,4), %eax
subl %eax, %ecx
cmpl $0x1, %ecx
jne 0x3868
leaq 0x12860(%rip), %rdi     # 0x160ba
xorl %eax, %eax
callq 0x3070
leaq 0x1289e(%rip), %r9      # 0x16106
movslq 0x1f39d(%rip), %rax     # 0x22c0c
imulq $0x10624dd3, %rax, %rcx # imm = 0x10624DD3
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x26, %rcx
addl %edx, %ecx
imulq $0x68db8bad, %rax, %rax # imm = 0x68DB8BAD
movq %rax, %rdx
shrq $0x3f, %rdx
sarq $0x2c, %rax
addl %edx, %eax
addl %eax, %eax
leal (%rax,%rax,4), %eax
subl %eax, %ecx
cmpl $0x1, %ecx
je 0x38b8
leaq 0x12823(%rip), %rdi     # 0x160cd
xorl %eax, %eax
callq 0x3070
leaq 0x1284e(%rip), %r9      # 0x16106
cmpq $0x1c, %r13
jne 0x38d3
leaq 0x1281b(%rip), %rdi     # 0x160e0
xorl %eax, %eax
callq 0x3070
leaq 0x12833(%rip), %r9      # 0x16106
cmpq $0x1d, %r13
jne 0x38ee
leaq 0x12813(%rip), %rdi     # 0x160f3
xorl %eax, %eax
callq 0x3070
leaq 0x12818(%rip), %r9      # 0x16106
cmpq $0x1e, %r13
jne 0x38fe
movq %r9, %rdi
xorl %eax, %eax
callq 0x3070
leaq -0x1f(%r13), %rax
cmpl $0x5, %eax
ja 0x3925
movl %eax, %eax
leaq 0x11b7c(%rip), %rcx     # 0x1548c
movslq (%rcx,%rax,4), %rdi
leaq 0x11b71(%rip), %rax     # 0x1548c
addq %rax, %rdi
xorl %eax, %eax
callq 0x3070
cmpq $0x25, %r13
jne 0x3939
leaq 0x12859(%rip), %rdi     # 0x1618b
xorl %eax, %eax
callq 0x3070
cmpq $0x26, %r13
jne 0x394d
leaq 0x12858(%rip), %rdi     # 0x1619e
xorl %eax, %eax
callq 0x3070
cmpq $0x27, %r13
jne 0x3961
leaq 0x12857(%rip), %rdi     # 0x161b1
xorl %eax, %eax
callq 0x3070
cmpq $0x28, %r13
jne 0x3975
leaq 0x12856(%rip), %rdi     # 0x161c4
xorl %eax, %eax
callq 0x3070
cmpq $0x29, %r13
jne 0x3989
leaq 0x12855(%rip), %rdi     # 0x161d7
xorl %eax, %eax
callq 0x3070
cmpq $0x2a, %r13
jne 0x399d
leaq 0x12854(%rip), %rdi     # 0x161ea
xorl %eax, %eax
callq 0x3070
leaq -0x2b(%r13), %rax
cmpl $0x2, %eax
leaq 0x11af9(%rip), %rcx     # 0x154a4
ja 0x39bd
movl %eax, %eax
movslq (%rcx,%rax,4), %rdi
addq %rcx, %rdi
xorl %eax, %eax
callq 0x3070
cmpq $0x2e, %r13
jne 0x39d1
leaq 0x1286c(%rip), %rdi     # 0x16236
xorl %eax, %eax
callq 0x3070
leaq -0x2f(%r13), %rax
cmpl $0x5, %eax
leaq 0x11ad1(%rip), %rcx     # 0x154b0
ja 0x39f1
movl %eax, %eax
movslq (%rcx,%rax,4), %rdi
addq %rcx, %rdi
xorl %eax, %eax
callq 0x3070
cmpq $0x35, %r13
jne 0x3a05
leaq 0x128aa(%rip), %rdi     # 0x162a8
xorl %eax, %eax
callq 0x3070
movl $0x1, 0x1ffb5(%rip)     # 0x239c4
movsd 0x115f1(%rip), %xmm1    # 0x15008
leaq 0x11a46(%rip), %rsi     # 0x15464
leaq 0x11a5b(%rip), %r8      # 0x15480
leaq 0x126da(%rip), %r9      # 0x16106
incq %r13
addq $0x4, %r14
cmpq $0x36, %r13
jne 0x334c
andl $-0x2, %ebx
cmpl $0x2, %ebx
jne 0x3a6a
cmpl $0x0, 0x1ff78(%rip)     # 0x239c4
jne 0x3a6a
leaq 0x12866(%rip), %rdi     # 0x162bb
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3070
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq