// File: lotuskip[P]yuxtapa/server/players.cpp
// Function: output_stats()
void output_stats()
{
	// General stuff:
	cout << "Players: " << known_players.size() << endl << endl;

	struct tm *timeinfo;
	unsigned long l;
	short sh;
	for(list<PlayerStats>::const_iterator it = known_players.begin();
		it != known_players.end(); ++it)
	{
		cout << it->last_known_as << endl;
		cout << "AL " << short(it->ad_lvl) << endl;
 		timeinfo = localtime(&(it->last_seen));
		cout << "seen " << asctime(timeinfo); // asctime includes '\n'
		l = it->total_time;
		cout << "tot_time: " << l/(60*60) << ':';
		if((l%(60*60))/60 < 10)
			cout << '0';
		cout << (l%(60*60))/60 << ':';
		if(l%60 < 10)
			cout << '0';
		cout << l%60 << endl;
		if(l)
		{
			cout << "as_spec: " << 100*it->time_specced/l << '%' << endl;
			for(sh = 0; sh < NO_CLASS; ++sh)
			{
				if(100*it->time_played[sh]/l) // only print non-zeros here
					cout << "as_" << classes[sh].abbr << ": "
						<< 100*it->time_played[sh]/l << '%' << endl;
			}
		}
		l = 0;
		cout << "kills: ";
		for(sh = 0; sh < MAX_WAY_TO_KILL; ++sh)
		{
			if(it->kills[sh])
			{
				cout << it->kills[sh]  << ' ' << kill_way_name[sh] << ", ";
				l += it->kills[sh];
			}
		}
		cout << "TOTAL: " << l << endl;
		cout << "t-kills: " << it->tks << endl;
		cout << "deaths: " << it->deaths << endl;
		cout << "healing: " << it->healing_recvd << endl;
		cout << "arch: ";
		if(it->arch_shots)
			cout  << 100*it->arch_hits/(it->arch_shots) << '%';
		else
			cout << '-';
		cout << endl << "zaps: ";
		if(it->cm_shots)
			cout << 100*it->cm_hits/(it->cm_shots) << '%';
		else
			cout << '-';
		cout << endl << endl;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq 0x68eae(%rip), %rdi     # 0x8cfc0
leaq 0x3d84c(%rip), %rsi     # 0x61965
callq 0x5510
movq %rax, -0x40(%rbp)
leaq 0x6c0ef(%rip), %rdi     # 0x90218
callq 0x24d70
movq -0x40(%rbp), %rdi
movq %rax, %rsi
callq 0x5140
movq %rax, %rdi
movq 0x68e64(%rip), %rsi     # 0x8cfa8
callq 0x5560
movq %rax, %rdi
movq 0x68e55(%rip), %rsi     # 0x8cfa8
callq 0x5560
leaq 0x6c0b9(%rip), %rdi     # 0x90218
callq 0x24e30
movq %rax, -0x28(%rbp)
leaq -0x20(%rbp), %rdi
leaq -0x28(%rbp), %rsi
callq 0x24e10
leaq 0x6c09c(%rip), %rdi     # 0x90218
callq 0x24e90
movq %rax, -0x38(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x24e10
leaq -0x20(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x25340
testb $0x1, %al
jne 0x241a8
jmp 0x2479a
leaq -0x20(%rbp), %rdi
callq 0x25370
movq %rax, %rsi
addq $0x10, %rsi
movq 0x68e01(%rip), %rdi     # 0x8cfc0
callq 0x5470
movq %rax, %rdi
movq 0x68dda(%rip), %rsi     # 0x8cfa8
callq 0x5560
movq 0x68de6(%rip), %rdi     # 0x8cfc0
leaq 0x3d78e(%rip), %rsi     # 0x6196f
callq 0x5510
movq %rax, -0x50(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x25370
movq -0x50(%rbp), %rdi
movl 0x130(%rax), %eax
movswl %ax, %esi
callq 0x54b0
movq %rax, %rdi
movq 0x68d99(%rip), %rsi     # 0x8cfa8
callq 0x5560
leaq -0x20(%rbp), %rdi
callq 0x25370
movq %rax, %rdi
addq $0x128, %rdi            # imm = 0x128
callq 0x5380
movq %rax, -0x8(%rbp)
movq 0x68d89(%rip), %rdi     # 0x8cfc0
leaq 0x3d735(%rip), %rsi     # 0x61973
callq 0x5510
movq %rax, -0x48(%rbp)
movq -0x8(%rbp), %rdi
callq 0x5210
movq -0x48(%rbp), %rdi
movq %rax, %rsi
callq 0x5510
leaq -0x20(%rbp), %rdi
callq 0x25370
movq 0xa0(%rax), %rax
movq %rax, -0x10(%rbp)
movq 0x68d49(%rip), %rdi     # 0x8cfc0
leaq 0x3d6fb(%rip), %rsi     # 0x61979
callq 0x5510
movq %rax, %rdi
movq -0x10(%rbp), %rax
movl $0xe10, %ecx            # imm = 0xE10
xorl %edx, %edx
divq %rcx
movq %rax, %rsi
callq 0x5140
movq %rax, %rdi
movl $0x3a, %esi
callq 0x5600
movq -0x10(%rbp), %rax
movl $0xe10, %ecx            # imm = 0xE10
xorl %edx, %edx
divq %rcx
movq %rdx, %rax
movl $0x3c, %ecx
xorl %edx, %edx
divq %rcx
cmpq $0xa, %rax
jae 0x242db
movq 0x68cef(%rip), %rdi     # 0x8cfc0
movl $0x30, %esi
callq 0x5600
movq -0x10(%rbp), %rax
movl $0xe10, %ecx            # imm = 0xE10
xorl %edx, %edx
divq %rcx
movq %rdx, %rax
movl $0x3c, %ecx
xorl %edx, %edx
divq %rcx
movq %rax, %rsi
movq 0x68cc0(%rip), %rdi     # 0x8cfc0
callq 0x5140
movq %rax, %rdi
movl $0x3a, %esi
callq 0x5600
movq -0x10(%rbp), %rax
movl $0x3c, %ecx
xorl %edx, %edx
divq %rcx
cmpq $0xa, %rdx
jae 0x24337
movq 0x68c93(%rip), %rdi     # 0x8cfc0
movl $0x30, %esi
callq 0x5600
movq -0x10(%rbp), %rax
movl $0x3c, %ecx
xorl %edx, %edx
divq %rcx
movq %rdx, %rsi
movq 0x68c71(%rip), %rdi     # 0x8cfc0
callq 0x5140
movq %rax, %rdi
movq 0x68c4a(%rip), %rsi     # 0x8cfa8
callq 0x5560
cmpq $0x0, -0x10(%rbp)
je 0x2449f
movq 0x68c4b(%rip), %rdi     # 0x8cfc0
leaq 0x3d608(%rip), %rsi     # 0x61984
callq 0x5510
movq %rax, -0x58(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x25370
movq -0x58(%rbp), %rdi
imulq $0x64, 0xa8(%rax), %rax
xorl %ecx, %ecx
movl %ecx, %edx
divq -0x10(%rbp)
movq %rax, %rsi
callq 0x5140
movq %rax, %rdi
movl $0x25, %esi
callq 0x5600
movq %rax, %rdi
movq 0x68be7(%rip), %rsi     # 0x8cfa8
callq 0x5560
movw $0x0, -0x12(%rbp)
movswl -0x12(%rbp), %eax
cmpl $0xb, %eax
jge 0x2449d
leaq -0x20(%rbp), %rdi
callq 0x25370
movswq -0x12(%rbp), %rcx
imulq $0x64, 0xb0(%rax,%rcx,8), %rax
xorl %ecx, %ecx
movl %ecx, %edx
divq -0x10(%rbp)
cmpq $0x0, %rax
je 0x2448a
movq 0x68bb7(%rip), %rdi     # 0x8cfc0
leaq 0x3d57e(%rip), %rsi     # 0x6198e
callq 0x5510
movq %rax, %rdi
movswq -0x12(%rbp), %rax
leaq 0x3d5ac(%rip), %rsi     # 0x619d0
imulq $0xd, %rax, %rax
addq %rax, %rsi
callq 0x5510
movq %rax, %rdi
leaq 0x3fe94(%rip), %rsi     # 0x642ce
callq 0x5510
movq %rax, -0x60(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x25370
movq -0x60(%rbp), %rdi
movswq -0x12(%rbp), %rcx
imulq $0x64, 0xb0(%rax,%rcx,8), %rax
xorl %ecx, %ecx
movl %ecx, %edx
divq -0x10(%rbp)
movq %rax, %rsi
callq 0x5140
movq %rax, %rdi
movl $0x25, %esi
callq 0x5600
movq %rax, %rdi
movq 0x68b23(%rip), %rsi     # 0x8cfa8
callq 0x5560
jmp 0x2448c
movw -0x12(%rbp), %ax
addw $0x1, %ax
movw %ax, -0x12(%rbp)
jmp 0x243cc
jmp 0x2449f
movq $0x0, -0x10(%rbp)
movq 0x68b12(%rip), %rdi     # 0x8cfc0
leaq 0x3d4e7(%rip), %rsi     # 0x6199c
callq 0x5510
movw $0x0, -0x12(%rbp)
movswl -0x12(%rbp), %eax
cmpl $0xb, %eax
jge 0x24567
leaq -0x20(%rbp), %rdi
callq 0x25370
movswq -0x12(%rbp), %rcx
cmpq $0x0, 0x38(%rax,%rcx,8)
je 0x24554
leaq -0x20(%rbp), %rdi
callq 0x25370
movswq -0x12(%rbp), %rcx
movq 0x38(%rax,%rcx,8), %rsi
movq 0x68ac3(%rip), %rdi     # 0x8cfc0
callq 0x5140
movq %rax, %rdi
movl $0x20, %esi
callq 0x5600
movq %rax, %rdi
movswq -0x12(%rbp), %rax
leaq 0x6bb62(%rip), %rsi     # 0x90080
shlq $0x5, %rax
addq %rax, %rsi
callq 0x5470
movq %rax, %rdi
leaq 0x48288(%rip), %rsi     # 0x6c7bc
callq 0x5510
leaq -0x20(%rbp), %rdi
callq 0x25370
movswq -0x12(%rbp), %rcx
movq 0x38(%rax,%rcx,8), %rax
addq -0x10(%rbp), %rax
movq %rax, -0x10(%rbp)
jmp 0x24556
movw -0x12(%rbp), %ax
addw $0x1, %ax
movw %ax, -0x12(%rbp)
jmp 0x244c0
movq 0x68a52(%rip), %rdi     # 0x8cfc0
leaq 0x3d41d(%rip), %rsi     # 0x61992
callq 0x5510
movq %rax, %rdi
movq -0x10(%rbp), %rsi
callq 0x5140
movq %rax, %rdi
movq 0x68a18(%rip), %rsi     # 0x8cfa8
callq 0x5560
movq 0x68a24(%rip), %rdi     # 0x8cfc0
leaq 0x3d3f7(%rip), %rsi     # 0x6199a
callq 0x5510
movq %rax, -0x78(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x25370
movq -0x78(%rbp), %rdi
movq 0x90(%rax), %rsi
callq 0x5140
movq %rax, %rdi
movq 0x689d9(%rip), %rsi     # 0x8cfa8
callq 0x5560
movq 0x689e5(%rip), %rdi     # 0x8cfc0
leaq 0x3d3c2(%rip), %rsi     # 0x619a4
callq 0x5510
movq %rax, -0x70(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x25370
movq -0x70(%rbp), %rdi
movq 0x30(%rax), %rsi
callq 0x5140
movq %rax, %rdi
movq 0x6899d(%rip), %rsi     # 0x8cfa8
callq 0x5560
movq 0x689a9(%rip), %rdi     # 0x8cfc0
leaq 0x3d38f(%rip), %rsi     # 0x619ad
callq 0x5510
movq %rax, -0x68(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x25370
movq -0x68(%rbp), %rdi
movq 0x98(%rax), %rsi
callq 0x5140
movq %rax, %rdi
movq 0x6895e(%rip), %rsi     # 0x8cfa8
callq 0x5560
movq 0x6896a(%rip), %rdi     # 0x8cfc0
leaq 0x3d35a(%rip), %rsi     # 0x619b7
callq 0x5510
leaq -0x20(%rbp), %rdi
callq 0x25370
cmpq $0x0, 0x110(%rax)
je 0x246c1
leaq -0x20(%rbp), %rdi
callq 0x25370
imulq $0x64, 0x108(%rax), %rax
movq %rax, -0x80(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x25370
movq %rax, %rcx
movq -0x80(%rbp), %rax
xorl %edx, %edx
divq 0x110(%rcx)
movq %rax, %rsi
movq 0x68913(%rip), %rdi     # 0x8cfc0
callq 0x5140
movq %rax, %rdi
movl $0x25, %esi
callq 0x5600
jmp 0x246d2
movq 0x688f8(%rip), %rdi     # 0x8cfc0
movl $0x2d, %esi
callq 0x5600
movq 0x688e7(%rip), %rdi     # 0x8cfc0
movq 0x688c8(%rip), %rsi     # 0x8cfa8
callq 0x5560
movq %rax, %rdi
leaq 0x3d2cf(%rip), %rsi     # 0x619be
callq 0x5510
leaq -0x20(%rbp), %rdi
callq 0x25370
cmpq $0x0, 0x120(%rax)
je 0x24759
leaq -0x20(%rbp), %rdi
callq 0x25370
imulq $0x64, 0x118(%rax), %rax
movq %rax, -0x88(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x25370
movq %rax, %rcx
movq -0x88(%rbp), %rax
xorl %edx, %edx
divq 0x120(%rcx)
movq %rax, %rsi
movq 0x6887b(%rip), %rdi     # 0x8cfc0
callq 0x5140
movq %rax, %rdi
movl $0x25, %esi
callq 0x5600
jmp 0x2476a
movq 0x68860(%rip), %rdi     # 0x8cfc0
movl $0x2d, %esi
callq 0x5600
movq 0x6884f(%rip), %rdi     # 0x8cfc0
movq 0x68830(%rip), %rsi     # 0x8cfa8
callq 0x5560
movq %rax, %rdi
movq 0x68821(%rip), %rsi     # 0x8cfa8
callq 0x5560
leaq -0x20(%rbp), %rdi
callq 0x253a0
jmp 0x24175
addq $0x90, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)