// File: /workspace/github_cpp_makefile_star2_O2/essarrdee[P]mutantaliens/mutantaliens.cpp
// Function: init_items()
void init_items()
{
	for(int i=0;i<WAVELENGTHS;i++)
	{rm_devices[i] = NULL;}
	ammo[PISTOL] = 60-difficulty;
	ammo[RIFLE] = 160 - 4*difficulty;
	ammo[CANNON] = 30-difficulty;
	dev_inv = std::vector<std::vector<std::vector<item*>>>(DEVICE_TYPES,(std::vector<std::vector<item*>>(DEVICE_CONFIGURATIONS)));
	item* dev;
	for(int i=0;i<5;i++)
	{
		dev = add_device(LOW_EXPLOSIVE,-1,-1,true);
		device_to_inventory(dev);
	}
	for(int i=0;i<3;i++)
	{
		dev = add_device(HIGH_EXPLOSIVE,-1,-1,true);
		device_to_inventory(dev);
	}
	for(int i=rand()%3+1;i<5;i++)
	{
		dev = add_device(HOLOGRAM_PROJECTOR,-1,-1,true);
		device_to_inventory(dev);
	}
	for(int i=rand()%3+1;i<5;i++)
	{
		dev = add_device(NOISE_GENERATOR,-1,-1,true);
		device_to_inventory(dev);
	}
	for(int i=rand()%3+1;i<5;i++)
	{
		dev = add_device(SCENT_GENERATOR,-1,-1,true);
		device_to_inventory(dev);
	}
	for(int i=rand()%3+1;i<5;i++)
	{
		dev = add_device(BRAIN_SLICE,-1,-1,true);
		device_to_inventory(dev);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
xorl %eax, %eax
leaq 0x8c332(%rip), %rcx     # 0x97460
cmpq $0x28, %rax
je 0xb13f
andq $0x0, (%rax,%rcx)
addq $0x8, %rax
jmp 0xb12e
movl 0x131c7(%rip), %eax     # 0x1e30c
pushq $0x3c
popq %rcx
subl %eax, %ecx
movl %ecx, 0x60098(%rip)     # 0x6b1e8
leal (,%rax,4), %ecx
movl $0xa0, %edx
subl %ecx, %edx
movl %edx, 0x60088(%rip)     # 0x6b1ec
pushq $0x1e
popq %rcx
subl %eax, %ecx
movl %ecx, 0x60081(%rip)     # 0x6b1f0
leaq 0x10(%rsp), %rbx
pushq $0x3
popq %rsi
leaq 0xf(%rsp), %rdx
movq %rbx, %rdi
callq 0x11214
leaq 0x28(%rsp), %rdi
pushq $0x6
popq %rsi
leaq 0xe(%rsp), %rcx
movq %rbx, %rdx
callq 0x11266
leaq 0xb82a0(%rip), %rdi     # 0xc3440
leaq 0x28(%rsp), %rbx
movq %rbx, %rsi
callq 0x129de
movq %rbx, %rdi
callq 0x1107a
leaq 0x10(%rsp), %rdi
callq 0x112bc
pushq $0x5
popq %r14
pushq $-0x1
popq %rbx
pushq $0x1
popq %rbp
subl $0x1, %r14d
jb 0xb1e6
xorl %edi, %edi
movl %ebx, %esi
movl %ebx, %edx
movl %ebp, %ecx
callq 0xae33
movq %rax, %rdi
callq 0x967c
jmp 0xb1c9
pushq $0x3
popq %r14
pushq $-0x1
popq %rbx
pushq $0x1
popq %rbp
subl $0x1, %r14d
jb 0xb20d
movl %ebp, %edi
movl %ebx, %esi
movl %ebx, %edx
movl %ebp, %ecx
callq 0xae33
movq %rax, %rdi
callq 0x967c
jmp 0xb1f0
callq 0x5080
pushq $0x3
popq %rbx
cltd
idivl %ebx
movl %edx, %ebp
addl $-0x4, %ebp
pushq $0x2
popq %r14
pushq $-0x1
popq %r15
pushq $0x1
popq %r12
testl %ebp, %ebp
je 0xb24a
movl %r14d, %edi
movl %r15d, %esi
movl %r15d, %edx
movl %r12d, %ecx
callq 0xae33
movq %rax, %rdi
callq 0x967c
incl %ebp
jmp 0xb229
callq 0x5080
cltd
idivl %ebx
movl %edx, %ebp
addl $-0x4, %ebp
pushq $-0x1
popq %r14
pushq $0x1
popq %r15
testl %ebp, %ebp
je 0xb27f
movl %ebx, %edi
movl %r14d, %esi
movl %r14d, %edx
movl %r15d, %ecx
callq 0xae33
movq %rax, %rdi
callq 0x967c
incl %ebp
jmp 0xb25f
callq 0x5080
cltd
idivl %ebx
movl %edx, %ebp
addl $-0x4, %ebp
pushq $0x4
popq %r14
pushq $-0x1
popq %r15
pushq $0x1
popq %r12
testl %ebp, %ebp
je 0xb2b9
movl %r14d, %edi
movl %r15d, %esi
movl %r15d, %edx
movl %r12d, %ecx
callq 0xae33
movq %rax, %rdi
callq 0x967c
incl %ebp
jmp 0xb298
callq 0x5080
cltd
idivl %ebx
movl %edx, %ebx
addl $-0x4, %ebx
pushq $0x5
popq %rbp
pushq $-0x1
popq %r14
pushq $0x1
popq %r15
testl %ebx, %ebx
je 0xb2f1
movl %ebp, %edi
movl %r14d, %esi
movl %r14d, %edx
movl %r15d, %ecx
callq 0xae33
movq %rax, %rdi
callq 0x967c
incl %ebx
jmp 0xb2d1
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x112bc
movq %rbx, %rdi
callq 0x53c0