LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: player_in_ship()
bool player_in_ship()
{
	bool player_present = false;
	for(int i=ship_x-1;i<ship_x +2;i++)
	{
		for(int j=ship_y-1;j<ship_y+2;j++)
		{
			actor* a = map_occupants[i][j];
			if(a != NULL)
			{
				if(a->is_player)
				{
					player_present = true;
				}
			}
		}

	}
	actor* a = map_occupants[ship_x-2][ship_y];
	if(a != NULL)
	{
		if(a->is_player)
		{
			player_present = true;
		}
	}
	return player_present;
}

// Assembly:
movb $0x0, -0x1(%rsp)
movl 0x766e1(%rip), %eax     # 0x8826c
subl $0x1, %eax
movl %eax, -0x8(%rsp)
movl -0x8(%rsp), %eax
movl 0x766d0(%rip), %ecx     # 0x8826c
addl $0x2, %ecx
cmpl %ecx, %eax
jge 0x11c20
movl 0x766c7(%rip), %eax     # 0x88270
subl $0x1, %eax
movl %eax, -0xc(%rsp)
movl -0xc(%rsp), %eax
movl 0x766b6(%rip), %ecx     # 0x88270
addl $0x2, %ecx
cmpl %ecx, %eax
jge 0x11c0e
movslq -0x8(%rsp), %rcx
leaq 0x76993(%rip), %rax     # 0x88560
imulq $0x4b0, %rcx, %rcx      # imm = 0x4B0
addq %rcx, %rax
movslq -0xc(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x18(%rsp)
cmpq $0x0, -0x18(%rsp)
je 0x11bff
movq -0x18(%rsp), %rax
testb $0x1, 0x8(%rax)
je 0x11bfd
movb $0x1, -0x1(%rsp)
jmp 0x11bff
jmp 0x11c01
movl -0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rsp)
jmp 0x11bb0
jmp 0x11c10
movl -0x8(%rsp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rsp)
jmp 0x11b92
movl 0x76646(%rip), %eax     # 0x8826c
subl $0x2, %eax
movslq %eax, %rcx
leaq 0x7692d(%rip), %rax     # 0x88560
imulq $0x4b0, %rcx, %rcx      # imm = 0x4B0
addq %rcx, %rax
movslq 0x7662c(%rip), %rcx     # 0x88270
movq (%rax,%rcx,8), %rax
movq %rax, -0x20(%rsp)
cmpq $0x0, -0x20(%rsp)
je 0x11c67
movq -0x20(%rsp), %rax
testb $0x1, 0x8(%rax)
je 0x11c65
movb $0x1, -0x1(%rsp)
jmp 0x11c67
movb -0x1(%rsp), %al
andb $0x1, %al
retq
nop
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: door_closable()
bool door_closable()
{
	//return (bool)(turn_count % 2);
	if (!transmitter_destroyed) return false;
	
	if(map_occupants[ship_x+2][ship_y] != NULL)
	{return false;}
	return player_in_ship();
}

// Assembly:
pushq %rax
testb $0x1, 0x29698(%rip)     # 0x3b380
jne 0x11cf1
movb $0x0, 0x7(%rsp)
jmp 0x11d2e
movl 0x76575(%rip), %eax     # 0x8826c
addl $0x2, %eax
movslq %eax, %rcx
leaq 0x7685c(%rip), %rax     # 0x88560
imulq $0x4b0, %rcx, %rcx      # imm = 0x4B0
addq %rcx, %rax
movslq 0x7655b(%rip), %rcx     # 0x88270
cmpq $0x0, (%rax,%rcx,8)
je 0x11d23
movb $0x0, 0x7(%rsp)
jmp 0x11d2e
callq 0x11b80
andb $0x1, %al
movb %al, 0x7(%rsp)
movb 0x7(%rsp), %al
andb $0x1, %al
popq %rcx
retq
nopw %cs:(%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: win_condition()
bool win_condition()
{
	if (!transmitter_destroyed) return false;
	bool player_present = false;
	bool monster_present = false;
	for(int i=ship_x-1;i<ship_x +2;i++)
	{
		for(int j=ship_y-1;j<ship_y+2;j++)
		{
			actor* a = map_occupants[i][j];
			if(a != NULL)
			{
				if(a->is_player)
				{
					player_present = true;
				}
				else return false;
			}
		}

	}
	actor* a = map_occupants[ship_x-2][ship_y];
	if(a != NULL)
	{
		if(a->is_player)
		{
			player_present = true;
		}
		else return false;
	}
	if(map_occupants[ship_x+2][ship_y] != NULL)
	{return false;}
	return player_present;
}

// Assembly:
testb $0x1, 0x29639(%rip)     # 0x3b380
jne 0x11d53
movb $0x0, -0x1(%rsp)
jmp 0x11e94
movb $0x0, -0x2(%rsp)
movb $0x0, -0x3(%rsp)
movl 0x76509(%rip), %eax     # 0x8826c
subl $0x1, %eax
movl %eax, -0x8(%rsp)
movl -0x8(%rsp), %eax
movl 0x764f8(%rip), %ecx     # 0x8826c
addl $0x2, %ecx
cmpl %ecx, %eax
jge 0x11e08
movl 0x764eb(%rip), %eax     # 0x88270
subl $0x1, %eax
movl %eax, -0xc(%rsp)
movl -0xc(%rsp), %eax
movl 0x764da(%rip), %ecx     # 0x88270
addl $0x2, %ecx
cmpl %ecx, %eax
jge 0x11df6
movslq -0x8(%rsp), %rcx
leaq 0x767b7(%rip), %rax     # 0x88560
imulq $0x4b0, %rcx, %rcx      # imm = 0x4B0
addq %rcx, %rax
movslq -0xc(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x18(%rsp)
cmpq $0x0, -0x18(%rsp)
je 0x11de7
movq -0x18(%rsp), %rax
testb $0x1, 0x8(%rax)
je 0x11ddb
movb $0x1, -0x2(%rsp)
jmp 0x11de5
movb $0x0, -0x1(%rsp)
jmp 0x11e94
jmp 0x11de7
jmp 0x11de9
movl -0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rsp)
jmp 0x11d8c
jmp 0x11df8
movl -0x8(%rsp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rsp)
jmp 0x11d6a
movl 0x7645e(%rip), %eax     # 0x8826c
subl $0x2, %eax
movslq %eax, %rcx
leaq 0x76745(%rip), %rax     # 0x88560
imulq $0x4b0, %rcx, %rcx      # imm = 0x4B0
addq %rcx, %rax
movslq 0x76444(%rip), %rcx     # 0x88270
movq (%rax,%rcx,8), %rax
movq %rax, -0x20(%rsp)
cmpq $0x0, -0x20(%rsp)
je 0x11e58
movq -0x20(%rsp), %rax
testb $0x1, 0x8(%rax)
je 0x11e4f
movb $0x1, -0x2(%rsp)
jmp 0x11e56
movb $0x0, -0x1(%rsp)
jmp 0x11e94
jmp 0x11e58
movl 0x7640e(%rip), %eax     # 0x8826c
addl $0x2, %eax
movslq %eax, %rcx
leaq 0x766f5(%rip), %rax     # 0x88560
imulq $0x4b0, %rcx, %rcx      # imm = 0x4B0
addq %rcx, %rax
movslq 0x763f4(%rip), %rcx     # 0x88270
cmpq $0x0, (%rax,%rcx,8)
je 0x11e8a
movb $0x0, -0x1(%rsp)
jmp 0x11e94
movb -0x2(%rsp), %al
andb $0x1, %al
movb %al, -0x1(%rsp)
movb -0x1(%rsp), %al
andb $0x1, %al
retq
nopl (%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: init_actors()
void init_actors()
{
	p_ptr = add_actor(zoo[0],true,ship_x,ship_y);
	std::pair<int,int> ploc;// = random_occupiable_square();
	//ploc = random_occupiable_square_away_from_player();
	for(int i=0;i<10+difficulty;i++)
	{
		ploc = random_occupiable_square_away_from_player();
		add_actor(zoo[(rand()%ZOO_SIZE)+1],false,ploc.first,ploc.second);
	}

}

// Assembly:
subq $0x18, %rsp
leaq 0x75405(%rip), %rdi     # 0x88460
xorl %eax, %eax
movl %eax, %esi
callq 0x20650
movq (%rax), %rdi
movl 0x751ff(%rip), %edx     # 0x8826c
movl 0x751fd(%rip), %ecx     # 0x88270
movl $0x1, %esi
xorl %r8d, %r8d
callq 0xfdf0
movq %rax, 0x754c9(%rip)     # 0x88550
leaq 0x10(%rsp), %rdi
callq 0x20f70
movl $0x0, 0xc(%rsp)
movl 0xc(%rsp), %eax
movl 0x282d9(%rip), %ecx     # 0x3b37c
addl $0xa, %ecx
cmpl %ecx, %eax
jge 0x13105
callq 0xf130
movq %rax, 0x4(%rsp)
leaq 0x10(%rsp), %rdi
leaq 0x4(%rsp), %rsi
callq 0x20f90
callq 0x50b0
movl $0x7, %ecx
cltd
idivl %ecx
addl $0x1, %edx
movslq %edx, %rsi
leaq 0x75383(%rip), %rdi     # 0x88460
callq 0x20650
movq (%rax), %rdi
movl 0x10(%rsp), %edx
movl 0x14(%rsp), %ecx
xorl %r8d, %r8d
movl %r8d, %esi
callq 0xfdf0
movl 0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xc(%rsp)
jmp 0x13099
addq $0x18, %rsp
retq
nopw (%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: destroy_item(item*)
void destroy_item(item* a)
{
	if (a->device_type != NOT_DEVICE)
	{
		if(a->player_has)
		{
			inv_remove(a);
		}
		else
		{
			map_items[a->x][a->y] = NULL;
		}
		if (a->configuration == ON_REMOTE)
		{
			rm_devices[a->wavelength] = NULL;
		}
		if (a->configuration == ON_TIMER)
		{
			kill_velement(timer_devices,a);
		}
		if(a->device_type == LOW_EXPLOSIVE)
		{
			explosion ex;
			ex.x = a->x;
			ex.y = a->y;
			ex.radius = 2;
			ex.centre_damage = 20;
			explosions_this_turn.push_back(ex);
		}
		if(a->device_type == HIGH_EXPLOSIVE)
		{
			explosion ex;
			ex.x = a->x;
			ex.y = a->y;
			ex.radius = 4;
			ex.centre_damage = 60;
			explosions_this_turn.push_back(ex);
		}
	}
	kill_velement(items,a);

}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rax
cmpl $-0x1, 0x70(%rax)
je 0x13e0b
movq 0x20(%rsp), %rax
testb $0x1, 0x98(%rax)
je 0x13d02
movq 0x20(%rsp), %rdi
callq 0xfa90
jmp 0x13d33
movq 0x20(%rsp), %rax
movslq 0x90(%rax), %rcx
leaq 0xa081b(%rip), %rax     # 0xb4530
imulq $0x4b0, %rcx, %rcx      # imm = 0x4B0
addq %rcx, %rax
movq 0x20(%rsp), %rcx
movslq 0x94(%rcx), %rcx
movq $0x0, (%rax,%rcx,8)
movq 0x20(%rsp), %rax
cmpl $0x2, 0x8c(%rax)
jne 0x13d59
movq 0x20(%rsp), %rax
movslq 0x74(%rax), %rcx
leaq 0xa077f(%rip), %rax     # 0xb44d0
movq $0x0, (%rax,%rcx,8)
movq 0x20(%rsp), %rax
cmpl $0x1, 0x8c(%rax)
jne 0x13d78
movq 0x20(%rsp), %rsi
leaq 0xa0785(%rip), %rdi     # 0xb44f8
callq 0x20b60
movq 0x20(%rsp), %rax
cmpl $0x0, 0x70(%rax)
jne 0x13dc2
movq 0x20(%rsp), %rax
movl 0x90(%rax), %eax
movl %eax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movl 0x94(%rax), %eax
movl %eax, 0x14(%rsp)
movl $0x2, 0x18(%rsp)
movl $0x14, 0x1c(%rsp)
leaq 0xa06c8(%rip), %rdi     # 0xb4480
leaq 0x10(%rsp), %rsi
callq 0x21120
movq 0x20(%rsp), %rax
cmpl $0x1, 0x70(%rax)
jne 0x13e09
movq 0x20(%rsp), %rax
movl 0x90(%rax), %eax
movl %eax, (%rsp)
movq 0x20(%rsp), %rax
movl 0x94(%rax), %eax
movl %eax, 0x4(%rsp)
movl $0x4, 0x8(%rsp)
movl $0x3c, 0xc(%rsp)
leaq 0xa067f(%rip), %rdi     # 0xb4480
movq %rsp, %rsi
callq 0x21120
jmp 0x13e0b
movq 0x20(%rsp), %rsi
leaq 0xcc651(%rip), %rdi     # 0xe0468
callq 0x20b60
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: walk_description[abi:cxx11](species*)
std::string walk_description(species* sp)
{
	if(!sp->walk_known) return "    ";
	if(sp->walk_energy > human_sp->run_energy) return "vfst";
	else if(sp->walk_energy > human_sp->walk_energy) return "fast";
	else if(sp->walk_energy < human_sp->walk_energy) return "slow";
	return "avrg";
}

// Assembly:
subq $0x68, %rsp
movq %rdi, 0x30(%rsp)
movq %rdi, %rax
movq %rax, 0x38(%rsp)
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
movq 0x58(%rsp), %rax
testb $0x1, 0x47(%rax)
jne 0x14849
leaq 0x57(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rdx
leaq 0x1ab3d(%rip), %rsi     # 0x2f353
callq 0x53d0
jmp 0x1481d
leaq 0x57(%rsp), %rdi
callq 0x5310
jmp 0x149c9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x57(%rsp), %rdi
callq 0x5310
jmp 0x149d3
movq 0x58(%rsp), %rax
movl 0x2c(%rax), %eax
movq 0x73c40(%rip), %rcx     # 0x88498
cmpl 0x30(%rcx), %eax
jle 0x148b0
leaq 0x43(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x20(%rsp), %rdx
leaq 0x19919(%rip), %rsi     # 0x2e196
callq 0x53d0
jmp 0x14884
leaq 0x43(%rsp), %rdi
callq 0x5310
jmp 0x149c9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x43(%rsp), %rdi
callq 0x5310
jmp 0x149d3
movq 0x58(%rsp), %rax
movl 0x2c(%rax), %eax
movq 0x73bd9(%rip), %rcx     # 0x88498
cmpl 0x2c(%rcx), %eax
jle 0x14917
leaq 0x42(%rsp), %rdi
movq %rdi, 0x18(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x18(%rsp), %rdx
leaq 0x198b7(%rip), %rsi     # 0x2e19b
callq 0x53d0
jmp 0x148eb
leaq 0x42(%rsp), %rdi
callq 0x5310
jmp 0x149c9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x42(%rsp), %rdi
callq 0x5310
jmp 0x149d3
movq 0x58(%rsp), %rax
movl 0x2c(%rax), %eax
movq 0x73b72(%rip), %rcx     # 0x88498
cmpl 0x2c(%rcx), %eax
jge 0x14978
leaq 0x41(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x10(%rsp), %rdx
leaq 0x1b31c(%rip), %rsi     # 0x2fc67
callq 0x53d0
jmp 0x14952
leaq 0x41(%rsp), %rdi
callq 0x5310
jmp 0x149c9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x41(%rsp), %rdi
callq 0x5310
jmp 0x149d3
jmp 0x1497a
jmp 0x1497c
leaq 0x40(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x8(%rsp), %rdx
leaq 0x19820(%rip), %rsi     # 0x2e1bc
callq 0x53d0
jmp 0x149a3
leaq 0x40(%rsp), %rdi
callq 0x5310
jmp 0x149c9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x40(%rsp), %rdi
callq 0x5310
jmp 0x149d3
movq 0x38(%rsp), %rax
addq $0x68, %rsp
retq
movq 0x48(%rsp), %rdi
callq 0x5480
nopl (%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: run_description[abi:cxx11](species*)
std::string run_description(species* sp)
{
	if(!sp->run_known) return "    ";
	if(sp->run_energy > human_sp->run_energy) return "fast";
	else if(sp->run_energy < human_sp->walk_energy) return "vslw";
	else if(sp->run_energy < human_sp->run_energy) return "slow";
	return "avrg";
}

// Assembly:
subq $0x68, %rsp
movq %rdi, 0x30(%rsp)
movq %rdi, %rax
movq %rax, 0x38(%rsp)
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
movq 0x58(%rsp), %rax
testb $0x1, 0x48(%rax)
jne 0x14a59
leaq 0x57(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rdx
leaq 0x1a92d(%rip), %rsi     # 0x2f353
callq 0x53d0
jmp 0x14a2d
leaq 0x57(%rsp), %rdi
callq 0x5310
jmp 0x14bd9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x57(%rsp), %rdi
callq 0x5310
jmp 0x14be3
movq 0x58(%rsp), %rax
movl 0x30(%rax), %eax
movq 0x73a30(%rip), %rcx     # 0x88498
cmpl 0x30(%rcx), %eax
jle 0x14ac0
leaq 0x43(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x20(%rsp), %rdx
leaq 0x1970e(%rip), %rsi     # 0x2e19b
callq 0x53d0
jmp 0x14a94
leaq 0x43(%rsp), %rdi
callq 0x5310
jmp 0x14bd9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x43(%rsp), %rdi
callq 0x5310
jmp 0x14be3
movq 0x58(%rsp), %rax
movl 0x30(%rax), %eax
movq 0x739c9(%rip), %rcx     # 0x88498
cmpl 0x2c(%rcx), %eax
jge 0x14b27
leaq 0x42(%rsp), %rdi
movq %rdi, 0x18(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x18(%rsp), %rdx
leaq 0x196ac(%rip), %rsi     # 0x2e1a0
callq 0x53d0
jmp 0x14afb
leaq 0x42(%rsp), %rdi
callq 0x5310
jmp 0x14bd9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x42(%rsp), %rdi
callq 0x5310
jmp 0x14be3
movq 0x58(%rsp), %rax
movl 0x30(%rax), %eax
movq 0x73962(%rip), %rcx     # 0x88498
cmpl 0x30(%rcx), %eax
jge 0x14b88
leaq 0x41(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x10(%rsp), %rdx
leaq 0x1b10c(%rip), %rsi     # 0x2fc67
callq 0x53d0
jmp 0x14b62
leaq 0x41(%rsp), %rdi
callq 0x5310
jmp 0x14bd9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x41(%rsp), %rdi
callq 0x5310
jmp 0x14be3
jmp 0x14b8a
jmp 0x14b8c
leaq 0x40(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x8(%rsp), %rdx
leaq 0x19610(%rip), %rsi     # 0x2e1bc
callq 0x53d0
jmp 0x14bb3
leaq 0x40(%rsp), %rdi
callq 0x5310
jmp 0x14bd9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x40(%rsp), %rdi
callq 0x5310
jmp 0x14be3
movq 0x38(%rsp), %rax
addq $0x68, %rsp
retq
movq 0x48(%rsp), %rdi
callq 0x5480
nopl (%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: damage_description[abi:cxx11](species*)
std::string damage_description(species* sp)
{
	if(!sp->damage_known) return "    ";
	if(sp->damage <= 4) return "weak";
	if(sp->damage <= 8) return "strg";
	if(sp->damage <= 14) return "dngr";
	return "argh";
}

// Assembly:
subq $0x68, %rsp
movq %rdi, 0x30(%rsp)
movq %rdi, %rax
movq %rax, 0x38(%rsp)
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
movq 0x58(%rsp), %rax
testb $0x1, 0x45(%rax)
jne 0x14c69
leaq 0x57(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rdx
leaq 0x1a71d(%rip), %rsi     # 0x2f353
callq 0x53d0
jmp 0x14c3d
leaq 0x57(%rsp), %rdi
callq 0x5310
jmp 0x14dca
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x57(%rsp), %rdi
callq 0x5310
jmp 0x14dd4
movq 0x58(%rsp), %rax
cmpl $0x4, 0xc(%rax)
jg 0x14cc7
leaq 0x43(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x20(%rsp), %rdx
leaq 0x1ac04(%rip), %rsi     # 0x2f898
callq 0x53d0
jmp 0x14c9b
leaq 0x43(%rsp), %rdi
callq 0x5310
jmp 0x14dca
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x43(%rsp), %rdi
callq 0x5310
jmp 0x14dd4
movq 0x58(%rsp), %rax
cmpl $0x8, 0xc(%rax)
jg 0x14d25
leaq 0x42(%rsp), %rdi
movq %rdi, 0x18(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x18(%rsp), %rdx
leaq 0x18c32(%rip), %rsi     # 0x2d924
callq 0x53d0
jmp 0x14cf9
leaq 0x42(%rsp), %rdi
callq 0x5310
jmp 0x14dca
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x42(%rsp), %rdi
callq 0x5310
jmp 0x14dd4
movq 0x58(%rsp), %rax
cmpl $0xe, 0xc(%rax)
jg 0x14d7d
leaq 0x41(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x10(%rsp), %rdx
leaq 0x19455(%rip), %rsi     # 0x2e1a5
callq 0x53d0
jmp 0x14d57
leaq 0x41(%rsp), %rdi
callq 0x5310
jmp 0x14dca
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x41(%rsp), %rdi
callq 0x5310
jmp 0x14dd4
leaq 0x40(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x5490
movq 0x30(%rsp), %rdi
movq 0x8(%rsp), %rdx
leaq 0x1940d(%rip), %rsi     # 0x2e1aa
callq 0x53d0
jmp 0x14da4
leaq 0x40(%rsp), %rdi
callq 0x5310
jmp 0x14dca
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x40(%rsp), %rdi
callq 0x5310
jmp 0x14dd4
movq 0x38(%rsp), %rax
addq $0x68, %rsp
retq
movq 0x48(%rsp), %rdi
callq 0x5480
nop
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: tile_visible(int, int)
bool tile_visible(int x, int y)
{
	if (debug) return true;
	if(sym_los_in_range(p_ptr->x,p_ptr->y,x,y,is_opaque)) return true;
	for(unsigned int i=0; i<active_devices.size(); i++)
	{
		//if(active_devices[i]->device_type == HOLOGRAM_PROJECTOR) // put spy cameras on *all* devices
		{
			if(sym_los_in_range(active_devices[i]->x,active_devices[i]->y,x,y,is_opaque)) return true;
		}
	}
	return false;

}

// Assembly:
subq $0x28, %rsp
movl %edi, 0x20(%rsp)
movl %esi, 0x1c(%rsp)
testb $0x1, 0x24ddf(%rip)     # 0x3b382
je 0x165af
movb $0x1, 0x27(%rsp)
jmp 0x16687
movq 0x71f9a(%rip), %rax     # 0x88550
movl 0x20(%rax), %edi
movq 0x71f90(%rip), %rax     # 0x88550
movl 0x24(%rax), %esi
movl 0x20(%rsp), %edx
movl 0x1c(%rsp), %ecx
leaq -0x3122(%rip), %r8      # 0x134b0
callq 0x213d0
testb $0x1, %al
jne 0x165dd
jmp 0x165e7
movb $0x1, 0x27(%rsp)
jmp 0x16687
movl $0x0, 0x18(%rsp)
movl 0x18(%rsp), %eax
movq %rax, 0x10(%rsp)
leaq 0x9deb1(%rip), %rdi     # 0xb44b0
callq 0x20b10
movq %rax, %rcx
movq 0x10(%rsp), %rax
cmpq %rcx, %rax
jae 0x16682
movl 0x18(%rsp), %eax
movl %eax, %esi
leaq 0x9de92(%rip), %rdi     # 0xb44b0
callq 0x21440
movq (%rax), %rax
movl 0x90(%rax), %eax
movl %eax, 0xc(%rsp)
movl 0x18(%rsp), %eax
movl %eax, %esi
leaq 0x9de73(%rip), %rdi     # 0xb44b0
callq 0x21440
movl 0xc(%rsp), %edi
movq (%rax), %rax
movl 0x94(%rax), %esi
movl 0x20(%rsp), %edx
movl 0x1c(%rsp), %ecx
leaq -0x31ae(%rip), %r8      # 0x134b0
callq 0x213d0
testb $0x1, %al
jne 0x16669
jmp 0x16670
movb $0x1, 0x27(%rsp)
jmp 0x16687
jmp 0x16672
movl 0x18(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x18(%rsp)
jmp 0x165ef
movb $0x0, 0x27(%rsp)
movb 0x27(%rsp), %al
andb $0x1, %al
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: scent_strength(float)
char scent_strength(float scent)
{
	if (scent < 0.001) return '.';
	if (scent < 0.01) return ',';
	if (scent < 0.1) return ':';
	if (scent < 0.3) return ';';
	if (scent < 0.6) return '-';
	if (scent < 1.0) return '=';
	if (scent < 10.0) return '/';
	if(scent < 50.0) return '*';
	if (scent < 100.0) return '&';
	return '&';
	
	
}

// Assembly:
movss %xmm0, -0x8(%rsp)
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x16280(%rip), %xmm0    # 0x2d098
ucomisd %xmm1, %xmm0
jbe 0x16e28
movb $0x2e, -0x1(%rsp)
jmp 0x16f31
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x16266(%rip), %xmm0    # 0x2d0a0
ucomisd %xmm1, %xmm0
jbe 0x16e4a
movb $0x2c, -0x1(%rsp)
jmp 0x16f31
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x1624c(%rip), %xmm0    # 0x2d0a8
ucomisd %xmm1, %xmm0
jbe 0x16e6c
movb $0x3a, -0x1(%rsp)
jmp 0x16f31
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x16232(%rip), %xmm0    # 0x2d0b0
ucomisd %xmm1, %xmm0
jbe 0x16e8e
movb $0x3b, -0x1(%rsp)
jmp 0x16f31
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x16218(%rip), %xmm0    # 0x2d0b8
ucomisd %xmm1, %xmm0
jbe 0x16eb0
movb $0x2d, -0x1(%rsp)
jmp 0x16f31
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x161fe(%rip), %xmm0    # 0x2d0c0
ucomisd %xmm1, %xmm0
jbe 0x16ecf
movb $0x3d, -0x1(%rsp)
jmp 0x16f31
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x161e7(%rip), %xmm0    # 0x2d0c8
ucomisd %xmm1, %xmm0
jbe 0x16eee
movb $0x2f, -0x1(%rsp)
jmp 0x16f31
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x161d0(%rip), %xmm0    # 0x2d0d0
ucomisd %xmm1, %xmm0
jbe 0x16f0d
movb $0x2a, -0x1(%rsp)
jmp 0x16f31
movss -0x8(%rsp), %xmm0
cvtss2sd %xmm0, %xmm1
movsd 0x161b9(%rip), %xmm0    # 0x2d0d8
ucomisd %xmm1, %xmm0
jbe 0x16f2c
movb $0x26, -0x1(%rsp)
jmp 0x16f31
movb $0x26, -0x1(%rsp)
movb -0x1(%rsp), %al
retq
nopw %cs:(%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: draw_scene(bool)
void draw_scene(bool record_actors=false)
{
	
	draw_tile_description(p_ptr->x,p_ptr->y);
	centre_x = std::min(p_ptr->x,MAP_SIZE - viewport_width/2-1);
	centre_x = std::max(centre_x,viewport_width/2);
	centre_y = std::min(p_ptr->y,MAP_SIZE - viewport_height/2-1);
	centre_y = std::max(centre_y,viewport_height/2-1);
	for(int x=viewport_left_edge();x<=viewport_right_edge(); x++)
	{
		for(int y=viewport_top_edge();y<viewport_bottom_edge(); y++)
		{
			draw_tile(x,y,record_actors);
		}
	}
	draw_stats();
	//for(int x=
	sort(visible_actors.begin(),visible_actors.end(),nearer_actor);
	draw_last_msg();
	wrefresh(stdscr);
}

// Assembly:
subq $0x38, %rsp
movb %dil, %al
andb $0x1, %al
movb %al, 0x37(%rsp)
movq 0x70e6c(%rip), %rax     # 0x88550
movl 0x20(%rax), %edi
movq 0x70e62(%rip), %rax     # 0x88550
movl 0x24(%rax), %esi
callq 0x166a0
movq 0x70e53(%rip), %rdi     # 0x88550
addq $0x20, %rdi
movl $0x7d, 0x30(%rsp)
leaq 0x30(%rsp), %rsi
callq 0x215b0
movl (%rax), %eax
movl %eax, 0x70b35(%rip)     # 0x88250
movl $0x18, 0x2c(%rsp)
leaq 0x70b26(%rip), %rdi     # 0x88250
leaq 0x2c(%rsp), %rsi
callq 0x215f0
movl (%rax), %eax
movl %eax, 0x70b14(%rip)     # 0x88250
movq 0x70e0d(%rip), %rdi     # 0x88550
addq $0x24, %rdi
movl $0x8c, 0x28(%rsp)
leaq 0x28(%rsp), %rsi
callq 0x215b0
movl (%rax), %eax
movl %eax, 0x70af3(%rip)     # 0x88254
movl $0x8, 0x24(%rsp)
leaq 0x70ae4(%rip), %rdi     # 0x88254
leaq 0x24(%rsp), %rsi
callq 0x215f0
movl (%rax), %eax
movl %eax, 0x70ad2(%rip)     # 0x88254
callq 0x21630
movl %eax, 0x20(%rsp)
movl 0x20(%rsp), %eax
movl %eax, 0x4(%rsp)
callq 0x21640
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jg 0x177f2
callq 0x21650
movl %eax, 0x1c(%rsp)
movl 0x1c(%rsp), %eax
movl %eax, (%rsp)
callq 0x21660
movl %eax, %ecx
movl (%rsp), %eax
cmpl %ecx, %eax
jge 0x177e3
movl 0x20(%rsp), %edi
movl 0x1c(%rsp), %esi
movb 0x37(%rsp), %al
andb $0x1, %al
movzbl %al, %edx
callq 0x16f40
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x177ab
jmp 0x177e5
movl 0x20(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x20(%rsp)
jmp 0x1778b
callq 0x15c60
leaq 0x70d3a(%rip), %rdi     # 0x88538
callq 0x20960
movq %rax, 0x10(%rsp)
leaq 0x70d29(%rip), %rdi     # 0x88538
callq 0x209d0
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
movq 0x8(%rsp), %rsi
leaq -0x1da(%rip), %rdx      # 0x17650
callq 0x21670
callq 0x8ce0
movq 0x237a5(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
callq 0x5320
addq $0x38, %rsp
retq
nopl (%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: kill_actor(actor*)
void kill_actor(actor* a)
{
	map_occupants[a->x][a->y] = NULL;
	if(current_target == a) current_target = NULL;
	a->dead = true;
	//if(sym_los_in_range(p_ptr->x,p_ptr->y,a->x,a->y,is_opaque))
	if(tile_visible(a->x,a->y))
	{
		add_message("The "+a->sspecies->name+" dies.");
	}
	a->sspecies->health_known = true;
	add_junk(a->sspecies->name +" corpse","the bloody corpse of a "+a->sspecies->name,'%',a->sspecies->colour,a->x,a->y);
}

// Assembly:
subq $0xa8, %rsp
movq %rdi, 0xa0(%rsp)
movq 0xa0(%rsp), %rax
movslq 0x20(%rax), %rcx
leaq 0x7060e(%rip), %rax     # 0x88560
imulq $0x4b0, %rcx, %rcx      # imm = 0x4B0
addq %rcx, %rax
movq 0xa0(%rsp), %rcx
movslq 0x24(%rcx), %rcx
movq $0x0, (%rax,%rcx,8)
movq 0x705b9(%rip), %rax     # 0x88530
cmpq 0xa0(%rsp), %rax
jne 0x17f8c
movq $0x0, 0x705a4(%rip) # 0x88530
movq 0xa0(%rsp), %rax
movb $0x1, 0x1c(%rax)
movq 0xa0(%rsp), %rax
movl 0x20(%rax), %edi
movq 0xa0(%rsp), %rax
movl 0x24(%rax), %esi
callq 0x16590
testb $0x1, %al
jne 0x17fbc
jmp 0x18061
movq 0xa0(%rsp), %rax
movq (%rax), %rdx
addq $0xf0, %rdx
leaq 0x16483(%rip), %rsi     # 0x2e458
leaq 0x60(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x1ff70
movq 0x8(%rsp), %rsi
leaq 0x1646d(%rip), %rdx     # 0x2e45d
leaq 0x80(%rsp), %rdi
callq 0x21090
jmp 0x17fff
leaq 0x80(%rsp), %rdi
callq 0x6670
jmp 0x1800e
leaq 0x80(%rsp), %rdi
callq 0x54f8
leaq 0x60(%rsp), %rdi
callq 0x54f8
jmp 0x18061
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x58(%rsp)
movl %eax, 0x54(%rsp)
jmp 0x18052
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x58(%rsp)
movl %eax, 0x54(%rsp)
leaq 0x80(%rsp), %rdi
callq 0x54f8
leaq 0x60(%rsp), %rdi
callq 0x54f8
jmp 0x18132
movq 0xa0(%rsp), %rax
movq (%rax), %rax
movb $0x1, 0x46(%rax)
movq 0xa0(%rsp), %rax
movq (%rax), %rsi
addq $0xf0, %rsi
leaq 0x163db(%rip), %rdx     # 0x2e464
leaq 0x30(%rsp), %rdi
callq 0x20670
movq 0xa0(%rsp), %rax
movq (%rax), %rdx
addq $0xf0, %rdx
leaq 0x163c0(%rip), %rsi     # 0x2e46c
leaq 0x10(%rsp), %rdi
callq 0x1ff70
jmp 0x180b8
movq 0xa0(%rsp), %rax
movq (%rax), %rcx
movl 0x28(%rcx), %ecx
movl 0x20(%rax), %r8d
movl 0x24(%rax), %r9d
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rsi
movl $0x25, %edx
callq 0xfcf0
jmp 0x180e4
leaq 0x10(%rsp), %rdi
callq 0x54f8
leaq 0x30(%rsp), %rdi
callq 0x54f8
addq $0xa8, %rsp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x58(%rsp)
movl %eax, 0x54(%rsp)
jmp 0x18128
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x58(%rsp)
movl %eax, 0x54(%rsp)
leaq 0x10(%rsp), %rdi
callq 0x54f8
leaq 0x30(%rsp), %rdi
callq 0x54f8
movq 0x58(%rsp), %rdi
callq 0x5480
nopl (%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: add_score_str()
void add_score_str()
{
	check_achievements();
	char score_str[10] = "";
	sprintf(score_str,"%d",calculate_score());
	//itoa(calculate_score(),score_str,10);
	add_message("Your score is " + std::string(score_str) + ".");
}

// Assembly:
subq $0x98, %rsp
callq 0x11c70
movw $0x0, 0x90(%rsp)
movq $0x0, 0x88(%rsp)
callq 0x18140
movl %eax, %edx
leaq 0x16144(%rip), %rsi     # 0x2e484
xorl %eax, %eax
leaq 0x88(%rsp), %rdi
movq %rdi, (%rsp)
callq 0x5080
leaq 0x27(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x5490
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
leaq 0x28(%rsp), %rdi
callq 0x53d0
jmp 0x18377
leaq 0x16109(%rip), %rsi     # 0x2e487
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x216c0
jmp 0x1838f
leaq 0x17495(%rip), %rdx     # 0x2f82b
leaq 0x68(%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0x21090
jmp 0x183a7
leaq 0x68(%rsp), %rdi
callq 0x6670
jmp 0x183b3
leaq 0x68(%rsp), %rdi
callq 0x54f8
leaq 0x48(%rsp), %rdi
callq 0x54f8
leaq 0x28(%rsp), %rdi
callq 0x54f8
leaq 0x27(%rsp), %rdi
callq 0x5310
addq $0x98, %rsp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
jmp 0x1843f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
jmp 0x18435
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
jmp 0x1842b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
leaq 0x68(%rsp), %rdi
callq 0x54f8
leaq 0x48(%rsp), %rdi
callq 0x54f8
leaq 0x28(%rsp), %rdi
callq 0x54f8
leaq 0x27(%rsp), %rdi
callq 0x5310
movq 0x18(%rsp), %rdi
callq 0x5480
nopw %cs:(%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: lose()
void lose()
{
	died = true;
	
	add_message("You die. Press 'Q' to quit.");
	
	add_score_str();
	draw_scene();
	int kp = 0;
	while(kp != 'Q') kp = fgetch();
	endwin();
	exit(0);

}

// Assembly:
subq $0x48, %rsp
movb $0x1, 0x22f25(%rip)     # 0x3b390
leaq 0x27(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x5490
movq 0x8(%rsp), %rdx
leaq 0x16010(%rip), %rsi     # 0x2e496
leaq 0x28(%rsp), %rdi
callq 0x53d0
jmp 0x18492
leaq 0x28(%rsp), %rdi
callq 0x6670
jmp 0x1849e
leaq 0x28(%rsp), %rdi
callq 0x54f8
leaq 0x27(%rsp), %rdi
callq 0x5310
callq 0x18310
xorl %edi, %edi
callq 0x176d0
movl $0x0, 0x10(%rsp)
cmpl $0x51, 0x10(%rsp)
je 0x1850c
callq 0x21710
movl %eax, 0x10(%rsp)
jmp 0x184c6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
jmp 0x18500
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
leaq 0x28(%rsp), %rdi
callq 0x54f8
leaq 0x27(%rsp), %rdi
callq 0x5310
jmp 0x18518
callq 0x5340
xorl %edi, %edi
callq 0x5360
movq 0x18(%rsp), %rdi
callq 0x5480
nopw %cs:(%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: win()
void win()
{
	if(map_terrain[ship_x+2][ship_y] == DOOR)
	{
		add_message("You close the doors and fly away! Press Q to quit.");
	}
	else
	{
		add_message("You wipe some blood off the control panel and fly away! Press Q to quit.");
	}
	check_achievements();
	closed_doors = true;
	left_planet = true;
	add_score_str();
	map_terrain[ship_x+2][ship_y] = NS;
	draw_scene();
	int kp = 0;
	while(kp != 'Q') kp = fgetch();
	endwin();
	exit(0);

}

// Assembly:
subq $0x78, %rsp
movl 0x6fd32(%rip), %eax     # 0x8826c
addl $0x2, %eax
movslq %eax, %rcx
leaq 0x22e69(%rip), %rax     # 0x3b3b0
imulq $0x258, %rcx, %rcx      # imm = 0x258
addq %rcx, %rax
movslq 0x6fd18(%rip), %rcx     # 0x88270
cmpl $0x5, (%rax,%rcx,4)
jne 0x185e5
leaq 0x57(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x5490
movq 0x10(%rsp), %rdx
leaq 0x15f35(%rip), %rsi     # 0x2e4b2
leaq 0x58(%rsp), %rdi
callq 0x53d0
jmp 0x18589
leaq 0x58(%rsp), %rdi
callq 0x6670
jmp 0x18595
leaq 0x58(%rsp), %rdi
callq 0x54f8
leaq 0x57(%rsp), %rdi
callq 0x5310
jmp 0x18662
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
jmp 0x185d6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x54f8
leaq 0x57(%rsp), %rdi
callq 0x5310
jmp 0x186d2
leaq 0x1f(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x5490
movq 0x8(%rsp), %rdx
leaq 0x15ee5(%rip), %rsi     # 0x2e4e5
leaq 0x20(%rsp), %rdi
callq 0x53d0
jmp 0x1860c
leaq 0x20(%rsp), %rdi
callq 0x6670
jmp 0x18618
leaq 0x20(%rsp), %rdi
callq 0x54f8
leaq 0x1f(%rsp), %rdi
callq 0x5310
jmp 0x18662
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
jmp 0x18656
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x20(%rsp), %rdi
callq 0x54f8
leaq 0x1f(%rsp), %rdi
callq 0x5310
jmp 0x186d2
callq 0x11c70
movb $0x1, 0x22d28(%rip)     # 0x3b396
movb $0x1, 0x22d22(%rip)     # 0x3b397
callq 0x18310
movl 0x6fbec(%rip), %eax     # 0x8826c
addl $0x2, %eax
movslq %eax, %rcx
leaq 0x22d23(%rip), %rax     # 0x3b3b0
imulq $0x258, %rcx, %rcx      # imm = 0x258
addq %rcx, %rax
movslq 0x6fbd2(%rip), %rcx     # 0x88270
movl $0xa, (%rax,%rcx,4)
xorl %edi, %edi
callq 0x176d0
movl $0x0, 0x18(%rsp)
cmpl $0x51, 0x18(%rsp)
je 0x186c6
callq 0x21710
movl %eax, 0x18(%rsp)
jmp 0x186b4
callq 0x5340
xorl %edi, %edi
callq 0x5360
movq 0x48(%rsp), %rdi
callq 0x5480
nopl (%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: hurt_actor(actor*, int)
void hurt_actor(actor* a,int damage)
{
	if(!a->is_hologram)
	{
	a->health -= damage;
	if(a->health <= 0)
	{
		if (a->is_player) {lose();}
		else kill_actor(a);
	}
	}
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movq 0x10(%rsp), %rax
testb $0x1, 0x9(%rax)
jne 0x18734
movl 0xc(%rsp), %edx
movq 0x10(%rsp), %rax
movl 0xc(%rax), %ecx
subl %edx, %ecx
movl %ecx, 0xc(%rax)
movq 0x10(%rsp), %rax
cmpl $0x0, 0xc(%rax)
jg 0x18732
movq 0x10(%rsp), %rax
testb $0x1, 0x8(%rax)
je 0x18726
callq 0x18460
jmp 0x18730
movq 0x10(%rsp), %rdi
callq 0x17f30
jmp 0x18732
jmp 0x18734
addq $0x18, %rsp
retq
nopl (%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: scent_walk(actor*)
void scent_walk(actor* a)
{
	std::pair<int,int> valid_dirs[8];
	int dir_count = 0;
	int best_x = 0; int best_y = 0;
	float best_scent = map_human_scent[a->x][a->y];
	random_shuffle(vdirections.begin(),vdirections.end());
	for(int d=0;d<8;d++)
	{
		std::pair<int,int> dir = directions[d];
		if(!terrain_immovable(a,a->x+dir.first,a->y+dir.second))
		{
			float detect = map_human_scent[a->x+dir.first][a->y+dir.second] + randfloat()*map_human_scent[a->x][a->y]*0.001f;
			if(detect >= best_scent)
			{
				best_scent = detect;
				best_x = dir.first; best_y = dir.second;
			}
		}
	}
	move_actor(a,best_x,best_y);
}

// Assembly:
subq $0x98, %rsp
movq %rdi, 0x90(%rsp)
leaq 0x50(%rsp), %rax
movq %rax, %rcx
addq $0x40, %rcx
movq %rcx, 0x10(%rsp)
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x20f70
movq 0x8(%rsp), %rax
movq 0x10(%rsp), %rcx
addq $0x8, %rax
cmpq %rcx, %rax
movq %rax, 0x18(%rsp)
jne 0x19805
movl $0x0, 0x4c(%rsp)
movl $0x0, 0x48(%rsp)
movl $0x0, 0x44(%rsp)
movq 0x90(%rsp), %rax
movslq 0x20(%rax), %rcx
leaq 0x37ae9(%rip), %rax     # 0x51340
imulq $0x258, %rcx, %rcx      # imm = 0x258
addq %rcx, %rax
movq 0x90(%rsp), %rcx
movslq 0x24(%rcx), %rcx
movss (%rax,%rcx,4), %xmm0
movss %xmm0, 0x40(%rsp)
leaq 0x6ea11(%rip), %rdi     # 0x88290
callq 0x21850
movq %rax, 0x38(%rsp)
leaq 0x6ea00(%rip), %rdi     # 0x88290
callq 0x21880
movq %rax, 0x30(%rsp)
movq 0x38(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x21770
movl $0x0, 0x2c(%rsp)
cmpl $0x8, 0x2c(%rsp)
jge 0x199d0
movslq 0x2c(%rsp), %rcx
leaq 0x13f38(%rip), %rax     # 0x2d800
movq (%rax,%rcx,8), %rax
movq %rax, 0x24(%rsp)
movq 0x90(%rsp), %rdi
movq 0x90(%rsp), %rax
movl 0x20(%rax), %esi
addl 0x24(%rsp), %esi
movq 0x90(%rsp), %rax
movl 0x24(%rax), %edx
addl 0x28(%rsp), %edx
callq 0xef90
testb $0x1, %al
jne 0x199be
movq 0x90(%rsp), %rax
movl 0x20(%rax), %eax
addl 0x24(%rsp), %eax
movslq %eax, %rcx
leaq 0x37a23(%rip), %rax     # 0x51340
imulq $0x258, %rcx, %rcx      # imm = 0x258
addq %rcx, %rax
movq 0x90(%rsp), %rcx
movl 0x24(%rcx), %ecx
addl 0x28(%rsp), %ecx
movslq %ecx, %rcx
movss (%rax,%rcx,4), %xmm0
movss %xmm0, 0x4(%rsp)
callq 0x6650
movss 0x4(%rsp), %xmm1
movq 0x90(%rsp), %rax
movslq 0x20(%rax), %rcx
leaq 0x379de(%rip), %rax     # 0x51340
imulq $0x258, %rcx, %rcx      # imm = 0x258
addq %rcx, %rax
movq 0x90(%rsp), %rcx
movslq 0x24(%rcx), %rcx
mulss (%rax,%rcx,4), %xmm0
movss 0x136d7(%rip), %xmm2    # 0x2d05c
mulss %xmm2, %xmm0
addss %xmm1, %xmm0
movss %xmm0, 0x20(%rsp)
movss 0x20(%rsp), %xmm0
ucomiss 0x40(%rsp), %xmm0
jb 0x199bc
movss 0x20(%rsp), %xmm0
movss %xmm0, 0x40(%rsp)
movl 0x24(%rsp), %eax
movl %eax, 0x48(%rsp)
movl 0x28(%rsp), %eax
movl %eax, 0x44(%rsp)
jmp 0x199be
jmp 0x199c0
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
jmp 0x198b1
movq 0x90(%rsp), %rdi
movl 0x48(%rsp), %esi
movl 0x44(%rsp), %edx
callq 0x17850
addq $0x98, %rsp
retq
nopl (%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: random_walk(actor*)
void random_walk(actor* a)
{
	std::pair<int,int> valid_dirs[8];
	int dir_count = 0;
	for(int d=0;d<8;d++)
	{
		std::pair<int,int> dir = directions[d];
		if(is_wall(a->x+dir.first,a->y+dir.second))
		{
			valid_dirs[dir_count] = dir;
			dir_count++;
		}
		if(dir_count != 0)
		{
			int choice = rand()%dir_count;
			move_actor(a,valid_dirs[choice].first,valid_dirs[choice].second);
		}
	}
}

// Assembly:
subq $0x78, %rsp
movq %rdi, 0x70(%rsp)
leaq 0x30(%rsp), %rax
movq %rax, %rcx
addq $0x40, %rcx
movq %rcx, 0x8(%rsp)
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movq %rdi, (%rsp)
callq 0x20f70
movq (%rsp), %rax
movq 0x8(%rsp), %rcx
addq $0x8, %rax
cmpq %rcx, %rax
movq %rax, 0x10(%rsp)
jne 0x19a0f
movl $0x0, 0x2c(%rsp)
movl $0x0, 0x28(%rsp)
cmpl $0x8, 0x28(%rsp)
jge 0x19af0
movslq 0x28(%rsp), %rcx
leaq 0x13da5(%rip), %rax     # 0x2d800
movq (%rax,%rcx,8), %rax
movq %rax, 0x20(%rsp)
movq 0x70(%rsp), %rax
movl 0x20(%rax), %edi
addl 0x20(%rsp), %edi
movq 0x70(%rsp), %rax
movl 0x24(%rax), %esi
addl 0x24(%rsp), %esi
callq 0x13140
testb $0x1, %al
jne 0x19a87
jmp 0x19aad
movslq 0x2c(%rsp), %rax
leaq 0x30(%rsp), %rdi
shlq $0x3, %rax
addq %rax, %rdi
leaq 0x20(%rsp), %rsi
callq 0x218b0
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
cmpl $0x0, 0x2c(%rsp)
je 0x19ade
callq 0x50b0
cltd
idivl 0x2c(%rsp)
movl %edx, 0x1c(%rsp)
movq 0x70(%rsp), %rdi
movslq 0x1c(%rsp), %rax
movl 0x30(%rsp,%rax,8), %esi
movslq 0x1c(%rsp), %rax
movl 0x34(%rsp,%rax,8), %edx
callq 0x17850
jmp 0x19ae0
movl 0x28(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x28(%rsp)
jmp 0x19a44
addq $0x78, %rsp
retq
nopw %cs:(%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: update_map_seen()
void update_map_seen()
{
	int px = p_ptr->x;
	int py = p_ptr->y;
	for (int x=px - vis_range;x <= px + vis_range; x++)
	{
		for (int y=py - vis_range;y <= py + vis_range; y++)
		{
			if(on_map(x,y))
			{
				if (!map_seen[x][y])
				{
					if(tile_visible(x,y))
						map_seen[x][y] = true;
				}
			}
		}
	}
}

// Assembly:
subq $0x18, %rsp
movq 0x6db55(%rip), %rax     # 0x88550
movl 0x20(%rax), %eax
movl %eax, 0x14(%rsp)
movq 0x6db47(%rip), %rax     # 0x88550
movl 0x24(%rax), %eax
movl %eax, 0x10(%rsp)
movl 0x14(%rsp), %eax
subl $0x8, %eax
movl %eax, 0xc(%rsp)
movl 0xc(%rsp), %eax
movl 0x14(%rsp), %ecx
addl $0x8, %ecx
cmpl %ecx, %eax
jg 0x1aad6
movl 0x10(%rsp), %eax
subl $0x8, %eax
movl %eax, 0x8(%rsp)
movl 0x8(%rsp), %eax
movl 0x10(%rsp), %ecx
addl $0x8, %ecx
cmpl %ecx, %eax
jg 0x1aac4
movl 0xc(%rsp), %edi
movl 0x8(%rsp), %esi
callq 0x20770
testb $0x1, %al
jne 0x1aa5b
jmp 0x1aab2
movslq 0xc(%rsp), %rcx
leaq 0x627f9(%rip), %rax     # 0x7d260
imulq $0x96, %rcx, %rcx
addq %rcx, %rax
movslq 0x8(%rsp), %rcx
testb $0x1, (%rax,%rcx)
jne 0x1aab0
movl 0xc(%rsp), %edi
movl 0x8(%rsp), %esi
callq 0x16590
testb $0x1, %al
jne 0x1aa8f
jmp 0x1aaae
movslq 0xc(%rsp), %rcx
leaq 0x627c5(%rip), %rax     # 0x7d260
imulq $0x96, %rcx, %rcx
addq %rcx, %rax
movslq 0x8(%rsp), %rcx
movb $0x1, (%rax,%rcx)
jmp 0x1aab0
jmp 0x1aab2
jmp 0x1aab4
movl 0x8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x8(%rsp)
jmp 0x1aa39
jmp 0x1aac6
movl 0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xc(%rsp)
jmp 0x1aa1b
addq $0x18, %rsp
retq
nopl (%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: selectghjk_individual_device_from_type_and_config(int, int)
item* selectghjk_individual_device_from_type_and_config(int type, int config)
{
	bool unacceptable = true;
	std::vector<item*>* options = &dev_inv[type][config];
	attron(COLOR_PAIR(COLOR_WHITE));
	clear_area(0,0,viewport_width,options->size());
	for(unsigned int i=0;i<options->size();i++)
	{
		mvprintw(i,0,"(%c) %s with %d seconds remaining",'a'+i, (*options)[i]->name.c_str(), (*options)[i]->time_remaining);
	}

	int kp = fgetch();
	while(unacceptable)
	{
		unacceptable = false;
	}
	draw_scene();
	return (*options)[kp-'a'];
}

// Assembly:
subq $0x38, %rsp
movl %edi, 0x34(%rsp)
movl %esi, 0x30(%rsp)
movb $0x1, 0x2f(%rsp)
movslq 0x34(%rsp), %rsi
leaq 0xc4633(%rip), %rdi     # 0xe04b0
callq 0x20ad0
movq %rax, %rdi
movslq 0x30(%rsp), %rsi
callq 0x20af0
movq %rax, 0x20(%rsp)
movq 0x1f145(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
movl $0x700, %esi            # imm = 0x700
xorl %eax, %eax
movl %eax, %edx
callq 0x51a0
movq 0x20(%rsp), %rdi
callq 0x20b10
movl %eax, %ecx
xorl %esi, %esi
movl $0x31, %edx
movl %esi, %edi
callq 0x8b80
movl $0x0, 0x1c(%rsp)
movl 0x1c(%rsp), %eax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rdi
callq 0x20b10
movq %rax, %rcx
movq 0x10(%rsp), %rax
cmpq %rcx, %rax
jae 0x1bf64
movl 0x1c(%rsp), %eax
movl %eax, (%rsp)
movl 0x1c(%rsp), %eax
addl $0x61, %eax
movl %eax, 0x4(%rsp)
movq 0x20(%rsp), %rdi
movl 0x1c(%rsp), %eax
movl %eax, %esi
callq 0x21440
movq (%rax), %rdi
addq $0x10, %rdi
callq 0x5160
movq %rax, 0x8(%rsp)
movq 0x20(%rsp), %rdi
movl 0x1c(%rsp), %eax
movl %eax, %esi
callq 0x21440
movl (%rsp), %edi
movl 0x4(%rsp), %ecx
movq 0x8(%rsp), %r8
movq (%rax), %rax
movl 0x7c(%rax), %r9d
xorl %esi, %esi
leaq 0x127e3(%rip), %rdx     # 0x2e730
movb $0x0, %al
callq 0x53a0
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x1bece
callq 0x21710
movl %eax, 0x18(%rsp)
testb $0x1, 0x2f(%rsp)
je 0x1bf7b
movb $0x0, 0x2f(%rsp)
jmp 0x1bf6d
xorl %edi, %edi
callq 0x176d0
movq 0x20(%rsp), %rdi
movl 0x18(%rsp), %eax
subl $0x61, %eax
movslq %eax, %rsi
callq 0x21440
movq (%rax), %rax
addq $0x38, %rsp
retq
nop
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: ask_for_time()
int ask_for_time()
{
	clear_area(0,0,viewport_width,1);
	mvaddstr(0,0,"Choose delay (0 to 9 seconds). q or ESC to cancel");
	int t = -2;
	while(t == -2)
	{
		int kp = fgetch();
		if(kp == 'q' || kp == 'Q' || kp == KEY_ESC)
		{
			t = -1;
		}
		else if(kp >='0' && kp <= '9')
		{
			t = kp - '0';
		}
	}
	draw_scene();
	return t*10;
}

// Assembly:
pushq %rax
xorl %esi, %esi
movl $0x31, %edx
movl $0x1, %ecx
movl %esi, %edi
callq 0x8b80
movq 0x1f025(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
xorl %edx, %edx
movl %edx, %esi
callq 0x52f0
cmpl $-0x1, %eax
jne 0x1bfce
jmp 0x1bfe9
movq 0x1f00b(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
leaq 0x12773(%rip), %rsi     # 0x2e752
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x5100
movl $0xfffffffe, 0x4(%rsp)  # imm = 0xFFFFFFFE
cmpl $-0x2, 0x4(%rsp)
jne 0x1c036
callq 0x21710
movl %eax, (%rsp)
cmpl $0x71, (%rsp)
je 0x1c012
cmpl $0x51, (%rsp)
je 0x1c012
cmpl $0x1b, (%rsp)
jne 0x1c01c
movl $0xffffffff, 0x4(%rsp)  # imm = 0xFFFFFFFF
jmp 0x1c034
cmpl $0x30, (%rsp)
jl 0x1c032
cmpl $0x39, (%rsp)
jg 0x1c032
movl (%rsp), %eax
subl $0x30, %eax
movl %eax, 0x4(%rsp)
jmp 0x1c034
jmp 0x1bff1
xorl %edi, %edi
callq 0x176d0
imull $0xa, 0x4(%rsp), %eax
popq %rcx
retq
nopw %cs:(%rax,%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: ask_for_wavelength()
int ask_for_wavelength()
{
	clear_area(0,0,viewport_width,3);
	mvaddstr(0,0,"Use which wavelength? Choosing a wavelength");
	mvaddstr(1,0,"already in use will destroy the existing link.");
	mvaddstr(2,0,"q or ESC to cancel");
	for (int i=0;i<WAVELENGTHS;i++)
	{
		item* a = rm_devices[i];
		if (a==NULL)
		{
			mvprintw(i+3,0,"(%d) no device detected",i+1);
		}
		else
		{
			mvprintw(i+3,0,"(%d) %s", a->name.c_str());
		}
	}
	int w = -2;
	while(w == -2)
	{
		int kp = fgetch();
		if(kp == 'q' || kp == 'Q' || kp == KEY_ESC)
		{
			w = -1;
		}
		else if(kp >'0' && kp <= '0'+WAVELENGTHS)
		{
			w = kp - '1';
		}
	}
	draw_scene();
	return w;
}

// Assembly:
subq $0x28, %rsp
xorl %esi, %esi
movl $0x31, %edx
movl $0x3, %ecx
movl %esi, %edi
callq 0x8b80
movq 0x1ef72(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
xorl %edx, %edx
movl %edx, %esi
callq 0x52f0
cmpl $-0x1, %eax
jne 0x1c081
jmp 0x1c09c
movq 0x1ef58(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
leaq 0x126f2(%rip), %rsi     # 0x2e784
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x5100
movq 0x1ef3d(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
movl $0x1, %esi
xorl %edx, %edx
callq 0x52f0
cmpl $-0x1, %eax
jne 0x1c0b9
jmp 0x1c0d4
movq 0x1ef20(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
leaq 0x126e6(%rip), %rsi     # 0x2e7b0
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x5100
movq 0x1ef05(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
movl $0x2, %esi
xorl %edx, %edx
callq 0x52f0
cmpl $-0x1, %eax
jne 0x1c0f1
jmp 0x1c10c
movq 0x1eee8(%rip), %rax     # 0x3afe0
movq (%rax), %rdi
leaq 0x1266f(%rip), %rsi     # 0x2e771
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
callq 0x5100
movl $0x0, 0x24(%rsp)
cmpl $0x5, 0x24(%rsp)
jge 0x1c19a
movslq 0x24(%rsp), %rcx
leaq 0x983a9(%rip), %rax     # 0xb44d0
movq (%rax,%rcx,8), %rax
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
jne 0x1c158
movl 0x24(%rsp), %edi
addl $0x3, %edi
movl 0x24(%rsp), %ecx
addl $0x1, %ecx
xorl %esi, %esi
leaq 0x12690(%rip), %rdx     # 0x2e7df
movb $0x0, %al
callq 0x53a0
jmp 0x1c188
movl 0x24(%rsp), %eax
addl $0x3, %eax
movl %eax, 0xc(%rsp)
movq 0x18(%rsp), %rdi
addq $0x10, %rdi
callq 0x5160
movl 0xc(%rsp), %edi
movq %rax, %rcx
xorl %esi, %esi
leaq 0x12676(%rip), %rdx     # 0x2e7f7
movb $0x0, %al
callq 0x53a0
jmp 0x1c18a
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x1c114
movl $0xfffffffe, 0x14(%rsp) # imm = 0xFFFFFFFE
cmpl $-0x2, 0x14(%rsp)
jne 0x1c1ee
callq 0x21710
movl %eax, 0x10(%rsp)
cmpl $0x71, 0x10(%rsp)
je 0x1c1c7
cmpl $0x51, 0x10(%rsp)
je 0x1c1c7
cmpl $0x1b, 0x10(%rsp)
jne 0x1c1d1
movl $0xffffffff, 0x14(%rsp) # imm = 0xFFFFFFFF
jmp 0x1c1ec
cmpl $0x30, 0x10(%rsp)
jle 0x1c1ea
cmpl $0x35, 0x10(%rsp)
jg 0x1c1ea
movl 0x10(%rsp), %eax
subl $0x31, %eax
movl %eax, 0x14(%rsp)
jmp 0x1c1ec
jmp 0x1c1a2
xorl %edi, %edi
callq 0x176d0
movl 0x14(%rsp), %eax
addq $0x28, %rsp
retq
nop
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: set_unconfigured(item*)
void set_unconfigured(item* dev)
{
	if(dev->player_has && dev->configuration != UNCONFIGURED)
	{
		inv_remove(dev);
		dev_inv[dev->device_type][UNCONFIGURED].push_back(dev);
	}
	if(dev->configuration == ON_TIMER)
	{
		dev->time_remaining = -1;
		kill_velement(timer_devices,dev);
	}
	else if(dev->configuration == ON_REMOTE)
	{
		rm_devices[dev->wavelength] = NULL;
		dev->wavelength = -1;
	}
	dev->configuration = UNCONFIGURED;
}

// Assembly:
pushq %rax
movq %rdi, (%rsp)
movq (%rsp), %rax
testb $0x1, 0x98(%rax)
je 0x1c253
movq (%rsp), %rax
cmpl $0x0, 0x8c(%rax)
je 0x1c253
movq (%rsp), %rdi
callq 0xfa90
movq (%rsp), %rax
movslq 0x70(%rax), %rsi
leaq 0xc4279(%rip), %rdi     # 0xe04b0
callq 0x20ad0
movq %rax, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x20af0
movq %rax, %rdi
movq %rsp, %rsi
callq 0x20c30
movq (%rsp), %rax
cmpl $0x1, 0x8c(%rax)
jne 0x1c27d
movq (%rsp), %rax
movl $0xffffffff, 0x7c(%rax) # imm = 0xFFFFFFFF
movq (%rsp), %rsi
leaq 0x98282(%rip), %rdi     # 0xb44f8
callq 0x20b60
jmp 0x1c2ae
movq (%rsp), %rax
cmpl $0x2, 0x8c(%rax)
jne 0x1c2ac
movq (%rsp), %rax
movslq 0x74(%rax), %rcx
leaq 0x98237(%rip), %rax     # 0xb44d0
movq $0x0, (%rax,%rcx,8)
movq (%rsp), %rax
movl $0xffffffff, 0x74(%rax) # imm = 0xFFFFFFFF
jmp 0x1c2ae
movq (%rsp), %rax
movl $0x0, 0x8c(%rax)
popq %rax
retq
nop
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: set_timer(item*, int)
void set_timer(item* dev,int t)
{
	if(dev->configuration != ON_TIMER)
	{
		set_unconfigured(dev);
		timer_devices.push_back(dev);
		//if(dev->player_has)
		//{
		//	//inv_remove(dev);
		//	//dev_inv[dev->device_type][ON_TIMER].push_back(dev);
		//}
	}
	//if(dev->configuration == ON_REMOTE)
	//{
	//	rm_devices[dev->wavelength] = NULL;
	//	dev->wavelength = -1;
	//}
	if(dev->device_type == NOISE_GENERATOR)
	{
		dev->next_action = rand()%2+1;
	}
	dev->configuration = ON_TIMER;
	dev->time_remaining = t;
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movq 0x10(%rsp), %rax
cmpl $0x1, 0x8c(%rax)
je 0x1c2f6
movq 0x10(%rsp), %rdi
callq 0x1c200
leaq 0x9820c(%rip), %rdi     # 0xb44f8
leaq 0x10(%rsp), %rsi
callq 0x20c30
movq 0x10(%rsp), %rax
cmpl $0x3, 0x70(%rax)
jne 0x1c31c
callq 0x50b0
movl $0x2, %ecx
cltd
idivl %ecx
addl $0x1, %edx
movq 0x10(%rsp), %rax
movl %edx, 0x88(%rax)
movq 0x10(%rsp), %rax
movl $0x1, 0x8c(%rax)
movl 0xc(%rsp), %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x7c(%rax)
addq $0x18, %rsp
retq
nopl (%rax)
// File: essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: set_remote(item*, int)
void set_remote(item* dev,int w)
{
	if(dev->player_has && dev->configuration != ON_REMOTE)
	{
		set_unconfigured(dev);
		inv_remove(dev);
		dev_inv[dev->device_type][ON_REMOTE].push_back(dev);
	}
	//if(dev->configuration == ON_TIMER)
	//{
	//	dev->time_remaining = -1;
	//	kill_velement(timer_devices,dev);
	//}
	dev->configuration = ON_REMOTE;
	dev->wavelength = w;
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movq 0x10(%rsp), %rax
testb $0x1, 0x98(%rax)
je 0x1c3ac
movq 0x10(%rsp), %rax
cmpl $0x2, 0x8c(%rax)
je 0x1c3ac
movq 0x10(%rsp), %rdi
callq 0x1c200
movq 0x10(%rsp), %rdi
callq 0xfa90
movq 0x10(%rsp), %rax
movslq 0x70(%rax), %rsi
leaq 0xc4123(%rip), %rdi     # 0xe04b0
callq 0x20ad0
movq %rax, %rdi
movl $0x2, %esi
callq 0x20af0
movq %rax, %rdi
leaq 0x10(%rsp), %rsi
callq 0x20c30
movq 0x10(%rsp), %rax
movl $0x2, 0x8c(%rax)
movl 0xc(%rsp), %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x74(%rax)
addq $0x18, %rsp
retq
nopl (%rax)