LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_WeapPrev_f
void Cmd_WeapPrev_f (edict_t *ent)
{
	gclient_t	*cl;
	int			i, index;
	gitem_t		*it;
	int			selected_weapon;


	if(matchstate == MATCH_RAILGUN_INPLAY)
		return;


	cl = ent->client;

	if (!cl->pers.weapon)
		return;

	selected_weapon = ITEM_INDEX(cl->pers.weapon);

	// scan  for the next valid one
	for (i=1 ; i<=MAX_ITEMS ; i++)
	{
		index = (selected_weapon + i)%MAX_ITEMS;
		if (!cl->pers.inventory[index])
			continue;
		it = &itemlist[index];
		if (!it->use)
			continue;
		if (! (it->flags & IT_WEAPON) )
			continue;

		// LM_JORM -- Remove grapple from list if offhand is on
		if ((int)ctfflags->value & CTF_OFFHAND_HOOK &&
			it == FindItem("Grappling Hook"))
			continue;
		// END LM_JORM

		it->use (ent, it);
		if (cl->pers.weapon == it)
			return;	// successful
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq 0x41aab(%rip), %rax     # 0x697d8
cmpl $0x6, (%rax)
je 0x27dfa
movq %rdi, %rbx
movq 0x58(%rdi), %r12
movq 0x730(%r12), %rax
testq %rax, %rax
je 0x27dfa
subq 0x420eb(%rip), %rax     # 0x69e40
shrq $0x3, %rax
imull $0xf0f0f0f1, %eax, %r13d # imm = 0xF0F0F0F1
movl $0x1, %ebp
movq 0x420d4(%rip), %r14     # 0x69e40
movl %r13d, %eax
addl %ebp, %eax
leal 0xff(%r13,%rbp), %ecx
cmovnsl %eax, %ecx
andl $0xffffff00, %ecx       # imm = 0xFFFFFF00
subl %ecx, %eax
cltq
cmpl $0x0, 0x318(%r12,%rax,4)
je 0x27dae
movq %rax, %rcx
shlq $0x7, %rcx
leaq (%rcx,%rax,8), %r15
cmpq $0x0, 0x10(%r14,%r15)
je 0x27dae
addq %r14, %r15
testb $0x1, 0x68(%r15)
jne 0x27dba
cmpl $0xff, %ebp
ja 0x27dfa
incl %ebp
jmp 0x27d6c
movq 0x41d97(%rip), %rax     # 0x69b58
movq (%rax), %rax
cvttss2si 0x20(%rax), %eax
testb $0x10, %al
je 0x27dde
leaq 0x2c9f3(%rip), %rdi     # 0x547c7
callq 0x189e0
cmpq %rax, %r15
je 0x27dae
movq %rbx, %rdi
movq %r15, %rsi
callq *0x10(%r15)
cmpq %r15, 0x730(%r12)
je 0x27dfa
cmpl $0x100, %ebp            # imm = 0x100
jb 0x27db6
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_WeapLast_f
void Cmd_WeapLast_f (edict_t *ent)
{
	gclient_t	*cl;
	int			index;
	gitem_t		*it;


	if(matchstate == MATCH_RAILGUN_INPLAY)
		return;


	cl = ent->client;

	if (!cl->pers.weapon || !cl->pers.lastweapon)
		return;

	index = ITEM_INDEX(cl->pers.lastweapon);
	if (!cl->pers.inventory[index])
		return;
	it = &itemlist[index];
	if (!it->use)
		return;
	if (! (it->flags & IT_WEAPON) )
		return;
	it->use (ent, it);
}

// Assembly:
movq 0x418cf(%rip), %rax     # 0x697d8
cmpl $0x6, (%rax)
je 0x27f6b
movq 0x58(%rdi), %rax
cmpq $0x0, 0x730(%rax)
je 0x27f6b
movq 0x738(%rax), %rcx
testq %rcx, %rcx
je 0x27f6b
subq 0x41f11(%rip), %rcx     # 0x69e40
shrq $0x3, %rcx
imull $0xf0f0f0f1, %ecx, %ecx # imm = 0xF0F0F0F1
movslq %ecx, %rcx
cmpl $0x0, 0x318(%rax,%rcx,4)
je 0x27f6b
movq %rcx, %rax
shlq $0x7, %rax
leaq (%rax,%rcx,8), %rcx
movq 0x41ee8(%rip), %rsi     # 0x69e40
movq 0x10(%rsi,%rcx), %rax
testq %rax, %rax
je 0x27f6b
addq %rcx, %rsi
testb $0x1, 0x68(%rsi)
jne 0x27f6c
retq
jmpq *%rax
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_InvDrop_f
void Cmd_InvDrop_f (edict_t *ent)
{
	gitem_t		*it;

	ValidateSelectedItem (ent);

	if (ent->client->pers.selected_item == -1)
	{
		ctf_SafePrint(ent, PRINT_HIGH, "No item to drop.\n");
		return;
	}

	it = &itemlist[ent->client->pers.selected_item];
	if (!it->drop)
	{
		ctf_SafePrint(ent, PRINT_HIGH, "Item is not dropable.\n");
		return;
	}
	it->drop (ent, it);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq 0x58(%rdi), %rax
movslq 0x314(%rax), %rcx
cmpl $0x0, 0x318(%rax,%rcx,4)
jne 0x27f94
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x18940
movq 0x58(%rbx), %rax
movslq 0x314(%rax), %rax
cmpq $-0x1, %rax
je 0x27fca
movq %rax, %rcx
shlq $0x7, %rcx
leaq (%rcx,%rax,8), %rcx
movq 0x41e89(%rip), %rsi     # 0x69e40
movq 0x18(%rsi,%rcx), %rax
testq %rax, %rax
je 0x27fd3
addq %rcx, %rsi
movq %rbx, %rdi
popq %rbx
jmpq *%rax
leaq 0x2d7df(%rip), %rdx     # 0x557b0
jmp 0x27fda
leaq 0x2d7ae(%rip), %rdx     # 0x55788
movl $0x2, %esi
movq %rbx, %rdi
popq %rbx
jmp 0x18da0
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Kill_f
void Cmd_Kill_f (edict_t *ent)
{
	if((level.time - ent->client->respawn_time) < 5)
		return;
	ent->flags &= ~FL_GODMODE;
	ent->health = 0;
	meansOfDeath = MOD_SUICIDE;
	player_die (ent, ent, ent, 100000, vec3_origin);
#ifdef OLDOBSERVERCODE
	if (ent->client->ctf.teamnum == CTF_TEAM_OBSERVER) // An observer
		Observer_Start(ent);
#endif
}

// Assembly:
movq 0x41db1(%rip), %rax     # 0x69da0
movss 0x4(%rax), %xmm0
movq 0x58(%rdi), %rax
subss 0xf28(%rax), %xmm0
movss 0x2befc(%rip), %xmm1    # 0x53f04
ucomiss %xmm0, %xmm1
jbe 0x2800e
retq
andb $-0x11, 0x11c(%rdi)
movl $0x0, 0x254(%rdi)
movq 0x41b02(%rip), %rax     # 0x69b28
movl $0x17, (%rax)
movq 0x41735(%rip), %r8      # 0x69768
movq %rdi, %rsi
movq %rdi, %rdx
movl $0x186a0, %ecx          # imm = 0x186A0
jmp 0x19ab0
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_PutAway_f
void Cmd_PutAway_f (edict_t *ent)
{
	ent->client->showscores = false;
	ent->client->showhelp = false;
	ent->client->showinventory = false;
	ent->client->showctfhud = false;
	ent->client->showmod = false;
	ent->client->showmenu = false;
	ent->client->showsquadboard = false; // ADC
	//ent->client->awayframe = level.framenum;
	gi.WriteByte (svc_layout);
	gi.WriteString ("");
	gi.unicast (ent, false);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x58(%rdi), %rax
xorl %ecx, %ecx
movq %rcx, 0xe24(%rax)
movl %ecx, 0xe2c(%rax)
movq %rcx, 0xf74(%rax)
movl %ecx, 0xf80(%rax)
movl %ecx, 0xe34(%rax)
movq 0x41589(%rip), %r14     # 0x69600
movl $0x4, %edi
callq *0xc8(%r14)
leaq 0x2ce7b(%rip), %rdi     # 0x54f05
callq *0xe8(%r14)
movq 0xb8(%r14), %rax
movq %rbx, %rdi
xorl %esi, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
jmpq *%rax
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Team_Change
void Team_Change (edict_t *ent, int newnum)
{
	if (!newnum) {
		return;
	}

	if (game.teamslocked) {
		gi.cprintf(ent, PRINT_HIGH, "Teams are locked\n");
		return;
	}

	ent->health = 0;
	player_die (ent, ent, ent, 100000, vec3_origin);
	ent->client->resp.score++;
	stats_add(ent, STATS_SCORE, 1);
	stats_add(ent, STATS_DEATHS, -1);

	// don't even bother waiting for death frames
	ctf_SetEntTeam(ent, newnum); //switch teams after they die

	respawn (ent); //force them to respawn on the new team
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
testl %esi, %esi
je 0x280e4
movq %rdi, %rbx
movq 0x41c89(%rip), %rax     # 0x69d40
cmpl $0x0, 0x624(%rax)
je 0x280eb
movq 0x41539(%rip), %rax     # 0x69600
movq 0x10(%rax), %rcx
leaq 0x2d6f0(%rip), %rdx     # 0x557c2
movq %rbx, %rdi
movl $0x2, %esi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
jmpq *%rcx
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
movl %esi, %ebp
movl $0x0, 0x254(%rbx)
movq 0x4166a(%rip), %r8      # 0x69768
movq %rbx, %rdi
movq %rbx, %rsi
movq %rbx, %rdx
movl $0x186a0, %ecx          # imm = 0x186A0
callq 0x19ab0
movq 0x58(%rbx), %rax
incl 0xdf4(%rax)
movl $0x1, %edx
movq %rbx, %rdi
movl $0x3, %esi
callq 0x19330
movq %rbx, %rdi
movl $0x6, %esi
movq $-0x1, %rdx
callq 0x19330
movq %rbx, %rdi
movl %ebp, %esi
callq 0x18220
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x19610
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Drop_All
void Drop_All (edict_t *ent)
{
	edict_t *flag;
	flag = ClientHasFlag(ent);
	if (flag)
	{
		ctf_playerdropflag(ent, flag->item);
	}

	if (ent->client->hook)
	{
		G_FreeEdict (ent->client->hook);
		ent->client->hook = NULL;
	}

	if (ent->client->rune && ent->client->rune->item)
	{
		Drop_Rune(ent, ent->client->rune->item);
	}
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
callq 0x18150
testq %rax, %rax
je 0x28176
movq 0x330(%rax), %rsi
movq %rbx, %rdi
callq 0x19830
movq 0x58(%rbx), %rax
movq 0xf60(%rax), %rdi
testq %rdi, %rdi
je 0x2819a
callq 0x19a60
movq 0x58(%rbx), %rax
movq $0x0, 0xf60(%rax)
movq 0x58(%rbx), %rax
movq 0xf68(%rax), %rax
testq %rax, %rax
je 0x281bf
movq 0x330(%rax), %rsi
testq %rsi, %rsi
je 0x281bf
movq %rbx, %rdi
popq %rbx
jmp 0x19950
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Id_f
void Cmd_Id_f (edict_t *ent)
{
	vec3_t	forward, right, start, offset, mins, maxs, end;
	trace_t	tr;
	float	*v;

	v = tv(-32,-32,-32);
	VectorCopy (v, mins);
	v = tv(32,32,32);
	VectorCopy (v, maxs);

	// Set out ending point to our starting point
	AngleVectors (ent->client->v_angle, forward, right, NULL);
	VectorSet(offset, 8, 0, ent->viewheight-8);
	G_ProjectSource (ent->s.origin, offset, forward, right, start);

	VectorSet(offset, 10000, 0, 0);
	G_ProjectSource (start, offset, forward, right, end);

	tr = gi.trace (start, mins, maxs, end, ent, MASK_SHOT);
	if (tr.ent)
	{
		if (tr.ent->client)
			gi.centerprintf (ent, tr.ent->client->pers.netname);
		else if (tr.ent->item)
			gi.centerprintf (ent, tr.ent->item->pickup_name);
	}

}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rdi, %rbx
movss 0x2cff7(%rip), %xmm0    # 0x55408
movaps %xmm0, %xmm1
movaps %xmm0, %xmm2
callq 0x19510
movss (%rax), %xmm0
leaq 0x18(%rsp), %rcx
movss %xmm0, (%rcx)
movss 0x4(%rax), %xmm0
movss %xmm0, 0x4(%rcx)
movss 0x8(%rax), %xmm0
movss %xmm0, 0x8(%rcx)
movss 0x2bff7(%rip), %xmm0    # 0x5443c
movaps %xmm0, %xmm1
movaps %xmm0, %xmm2
callq 0x19510
movss (%rax), %xmm0
leaq 0xc(%rsp), %rcx
movss %xmm0, (%rcx)
movss 0x4(%rax), %xmm0
movss %xmm0, 0x4(%rcx)
movss 0x8(%rax), %xmm0
movss %xmm0, 0x8(%rcx)
movl $0xebc, %edi            # imm = 0xEBC
addq 0x58(%rbx), %rdi
leaq 0x54(%rsp), %r12
leaq 0x48(%rsp), %r13
movq %r12, %rsi
movq %r13, %rdx
xorl %ecx, %ecx
callq 0x183a0
leaq 0x30(%rsp), %rbp
movq $0x41000000, (%rbp)     # imm = 0x41000000
movl 0x278(%rbx), %eax
addl $-0x8, %eax
xorps %xmm0, %xmm0
cvtsi2ss %eax, %xmm0
movss %xmm0, 0x8(%rbp)
leaq 0x4(%rbx), %rdi
leaq 0x3c(%rsp), %r14
movq %rbp, %rsi
movq %r12, %rdx
movq %r13, %rcx
movq %r14, %r8
callq 0x18fa0
movq $0x461c4000, (%rbp)     # imm = 0x461C4000
movl $0x0, 0x8(%rbp)
leaq 0x24(%rsp), %r15
movq %r14, %rdi
movq %rbp, %rsi
movq %r12, %rdx
movq %r13, %rcx
movq %r15, %r8
callq 0x18fa0
movq 0x41104(%rip), %r13     # 0x69600
movl $0x6000003, (%rsp)      # imm = 0x6000003
leaq 0x60(%rsp), %r12
movq %r12, %rdi
movq %r14, %rsi
leaq 0x18(%rsp), %rdx
leaq 0xc(%rsp), %rcx
movq %r15, %r8
movq %rbx, %r9
callq *0x60(%r13)
movq 0x40(%r12), %rax
testq %rax, %rax
je 0x28557
movq 0x58(%rax), %rsi
testq %rsi, %rsi
je 0x2853e
addq $0x2c0, %rsi            # imm = 0x2C0
jmp 0x2854e
movq 0x330(%rax), %rax
testq %rax, %rax
je 0x28557
movq 0x50(%rax), %rsi
movq %rbx, %rdi
xorl %eax, %eax
callq *0x18(%r13)
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Position_f
void Cmd_Position_f(edict_t* ent)
{
	char temp[MAX_INFO_STRING];
	double f1, f2, f3, a1, a2, a3;
	char message[MAX_INFO_STRING];

	f1 = ent->s.origin[0];
	f2 = ent->s.origin[1];
	f3 = ent->s.origin[2];

	a1 = ent->s.angles[0];
	a2 = ent->s.angles[1];
	a3 = ent->s.angles[2];

	string_replace(ent, "%p", temp, sizeof temp);

	Com_sprintf(message, sizeof message, "LOC: { %.0f, %.0f, %.0f }\nANGLE: { %.0f, %.0f, %.0f }\n"
		"You are %s\n",
		f1, f2, f3, a1, a2, a3, temp);

	ctf_SafePrint(ent, PRINT_HIGH, message);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x430, %rsp            # imm = 0x430
movq %rdi, %rbx
cvtss2sd 0x4(%rdi), %xmm0
movsd %xmm0, 0x28(%rsp)
xorps %xmm0, %xmm0
cvtss2sd 0x8(%rdi), %xmm0
movsd %xmm0, 0x20(%rsp)
xorps %xmm0, %xmm0
cvtss2sd 0xc(%rdi), %xmm0
movsd %xmm0, 0x18(%rsp)
xorps %xmm0, %xmm0
cvtss2sd 0x10(%rdi), %xmm0
movsd %xmm0, 0x10(%rsp)
xorps %xmm0, %xmm0
cvtss2sd 0x14(%rdi), %xmm0
movsd %xmm0, 0x8(%rsp)
xorps %xmm0, %xmm0
cvtss2sd 0x18(%rdi), %xmm0
movsd %xmm0, (%rsp)
leaq 0x2c5e5(%rip), %rsi     # 0x54bb4
leaq 0x230(%rsp), %r14
movq %r14, %rdx
movl $0x200, %ecx            # imm = 0x200
callq 0x18050
leaq 0x2d2e4(%rip), %rdx     # 0x558cf
leaq 0x30(%rsp), %r15
movq %r15, %rdi
movl $0x200, %esi            # imm = 0x200
movsd 0x28(%rsp), %xmm0
movsd 0x20(%rsp), %xmm1
movsd 0x18(%rsp), %xmm2
movsd 0x10(%rsp), %xmm3
movsd 0x8(%rsp), %xmm4
movsd (%rsp), %xmm5
movq %r14, %rcx
movb $0x6, %al
callq 0x18e10
movl $0x2, %esi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x18da0
addq $0x430, %rsp            # imm = 0x430
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_AngleInfo_f
void Cmd_AngleInfo_f (edict_t *ent)
{
	double a1, a2, a3;
	double t1, t2, t3;
	vec3_t tempvec;
	char message[MAX_INFO_STRING];

	a1 = ent->client->v_angle[0];
	a2 = ent->client->v_angle[1];
	a3 = ent->client->v_angle[2];

	VectorCopy(ent->s.origin, tempvec);
	vectoangles(tempvec,tempvec);
	t1 = tempvec[0];
	t2 = tempvec[1];
	t3 = tempvec[2];

	sprintf (message, "VIEWANGLE: { %.0f, %.0f, %.0f }\tFACEANGLE: { %.0f, %.0f, %.0f }\n",
		a1,a2,a3,t1,t2,t3);
	ctf_SafePrint(ent, PRINT_HIGH, message);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x238, %rsp            # imm = 0x238
movq %rdi, %rbx
movq 0x58(%rdi), %rax
cvtss2sd 0xebc(%rax), %xmm0
movsd %xmm0, 0x18(%rsp)
xorps %xmm0, %xmm0
cvtss2sd 0xec0(%rax), %xmm0
movsd %xmm0, 0x10(%rsp)
xorps %xmm0, %xmm0
cvtss2sd 0xec4(%rax), %xmm0
movsd %xmm0, 0x8(%rsp)
movss 0x4(%rdi), %xmm0
leaq 0x24(%rsp), %r14
movss %xmm0, (%r14)
movss 0x8(%rdi), %xmm0
movss %xmm0, 0x4(%r14)
movss 0xc(%rdi), %xmm0
movss %xmm0, 0x8(%r14)
movq %r14, %rdi
movq %r14, %rsi
callq 0x190d0
cvtss2sd (%r14), %xmm3
cvtss2sd 0x4(%r14), %xmm4
cvtss2sd 0x8(%r14), %xmm5
leaq 0x2d246(%rip), %rsi     # 0x55911
leaq 0x30(%rsp), %r14
movq %r14, %rdi
movsd 0x18(%rsp), %xmm0
movsd 0x10(%rsp), %xmm1
movsd 0x8(%rsp), %xmm2
movb $0x6, %al
callq 0x19700
movl $0x2, %esi
movq %rbx, %rdi
movq %r14, %rdx
callq 0x18da0
addq $0x238, %rsp            # imm = 0x238
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Hook_f
void Cmd_Hook_f (edict_t *ent)
{
	gitem_t		*it;

	// Observers can't hook
	if (ent->movetype == MOVETYPE_NOCLIP)
		return;

	if ((int)ctfflags->value & CTF_OFFHAND_HOOK)
	{
		if (!ent->client->hook)
		{

			it = FindItem("Grappling Hook");

			// Can't offhand your hook if it is your current weapon
			if (ent->client->pers.weapon == it)
			{
				ForceCommand(ent, "+attack\n");
				return;
			}

			if (it && (ent->client->pers.inventory[ITEM_INDEX(it)]))  // We are carrying a rune
			{
 				if (ent->client->quad_framenum > level.framenum)
 					gi.sound(ent, CHAN_ITEM, gi.soundindex("items/damage3.wav"), 1, ATTN_NORM, 0);

 				Weapon_Hook_Fire(ent);
			}
			else
				ctf_SafePrint(ent, PRINT_HIGH, "You have no hook.\n");
		}
	}
	else // Use the hook
	{
		it = FindItem ("grappling hook");
		if (!ent->client->pers.inventory[ITEM_INDEX(it)])
		{
			ctf_SafePrint(ent, PRINT_HIGH, "Out of item: grappling hook\n");
			return;
		}
		if (it->use)
			it->use (ent, it);
	}
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
cmpl $0x1, 0x118(%rdi)
je 0x288ee
movq %rdi, %rbx
movq 0x412d2(%rip), %rax     # 0x69b58
movq (%rax), %rax
cvttss2si 0x20(%rax), %eax
testb $0x10, %al
jne 0x288e0
leaq 0x32712(%rip), %rdi     # 0x5afab
callq 0x189e0
movq 0x58(%rbx), %rcx
movq %rax, %rdx
subq 0x41594(%rip), %rdx     # 0x69e40
sarq $0x3, %rdx
movabsq $-0x3c3c3c3c3c3c3c3c, %rsi # imm = 0xC3C3C3C3C3C3C3C4
imulq %rdx, %rsi
cmpl $0x0, 0x318(%rcx,%rsi)
je 0x288f6
movq 0x10(%rax), %rcx
testq %rcx, %rcx
je 0x288ee
movq %rbx, %rdi
movq %rax, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmpq *%rcx
movq 0x58(%rbx), %rax
cmpq $0x0, 0xf60(%rax)
je 0x28902
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x2d42c(%rip), %rdx     # 0x55d29
jmp 0x289a5
leaq 0x2bebe(%rip), %rdi     # 0x547c7
callq 0x189e0
movq 0x58(%rbx), %rcx
cmpq %rax, 0x730(%rcx)
je 0x289b9
testq %rax, %rax
je 0x2899e
subq 0x41515(%rip), %rax     # 0x69e40
sarq $0x3, %rax
movabsq $-0x3c3c3c3c3c3c3c3c, %rdx # imm = 0xC3C3C3C3C3C3C3C4
imulq %rax, %rdx
cmpl $0x0, 0x318(%rcx,%rdx)
je 0x2899e
movq 0x41452(%rip), %rax     # 0x69da0
cvtsi2ssl (%rax), %xmm0
movss 0xf04(%rcx), %xmm1
ucomiss %xmm0, %xmm1
jbe 0x2898f
movq 0x40c9a(%rip), %rax     # 0x69600
movq 0x20(%rax), %r14
leaq 0x2f16c(%rip), %rdi     # 0x57add
callq *0x48(%rax)
movss 0x2b5ac(%rip), %xmm0    # 0x53f28
xorps %xmm2, %xmm2
movq %rbx, %rdi
movl $0x3, %esi
movl %eax, %edx
movaps %xmm0, %xmm1
callq *%r14
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x19b10
leaq 0x2d371(%rip), %rdx     # 0x55d16
movl $0x2, %esi
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x18da0
leaq 0x2d34d(%rip), %rsi     # 0x55d0d
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x18c40
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Unhook_f
void Cmd_Unhook_f (edict_t *ent)
{
	gitem_t		*it;

	if ((int)ctfflags->value & CTF_OFFHAND_HOOK)
	{
		it = FindItem("Grappling Hook");

		// Can't offhand your hook if it is your current weapon
		if (ent->client->pers.weapon == it)
		{
			ForceCommand(ent, "-attack\n");
			return;
		}
		else
		{
			ctf_hook_abort(ent);
		}
	}
}

// Assembly:
pushq %rbx
movq 0x41181(%rip), %rax     # 0x69b58
movq (%rax), %rax
cvttss2si 0x20(%rax), %eax
testb $0x10, %al
jne 0x289e5
popq %rbx
retq
movq %rdi, %rbx
leaq 0x2bdd8(%rip), %rdi     # 0x547c7
callq 0x189e0
movq 0x58(%rbx), %rcx
cmpq %rax, 0x730(%rcx)
je 0x28a0a
movq %rbx, %rdi
popq %rbx
jmp 0x18630
leaq 0x2d335(%rip), %rsi     # 0x55d46
movq %rbx, %rdi
popq %rbx
jmp 0x18c40
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Radio_f
void Cmd_Radio_f (edict_t *ent)
{
	char *p;

	p = gi.args();

	if (p[0]=='0' || !strcmp(p, "off"))
	{
		ent->client->ctf.extra_flags  &= ~(CTF_EXTRAFLAGS_RADIO_TEXT | CTF_EXTRAFLAGS_RADIO_SOUND);
		ctf_SafePrint(ent, PRINT_HIGH, "Your radio is now off.\n");
	}
	else if (p[0]=='1' || !strcmp(p, "on"))
	{
		ent->client->ctf.extra_flags  &= ~(CTF_EXTRAFLAGS_RADIO_TEXT | CTF_EXTRAFLAGS_RADIO_SOUND);
		ent->client->ctf.extra_flags  |= CTF_EXTRAFLAGS_RADIO_SOUND;
		ctf_SafePrint(ent, PRINT_HIGH, "Your radio is now on for sound.\n");
	}
	else if (p[0]=='2' || !strcmp(p, "text"))
	{
		ent->client->ctf.extra_flags  &= ~(CTF_EXTRAFLAGS_RADIO_TEXT | CTF_EXTRAFLAGS_RADIO_SOUND);
		ent->client->ctf.extra_flags  |= CTF_EXTRAFLAGS_RADIO_TEXT;
		ctf_SafePrint(ent, PRINT_HIGH, "Your radio is now text.\n");
	}
	else if (p[0]=='3' || !strcmp(p, "both"))
	{
		ent->client->ctf.extra_flags  &= ~(CTF_EXTRAFLAGS_RADIO_TEXT | CTF_EXTRAFLAGS_RADIO_SOUND);
		ent->client->ctf.extra_flags  |= CTF_EXTRAFLAGS_RADIO_TEXT | CTF_EXTRAFLAGS_RADIO_SOUND;
		ctf_SafePrint(ent, PRINT_HIGH, "Your radio is now on for text and sound.\n");
	}
	else
		ctf_SafePrint(ent, PRINT_HIGH, "Format: radio <off/text/on/both>\n");
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq 0x4026a(%rip), %rax     # 0x69600
callq *0x148(%rax)
movb (%rax), %bpl
cmpb $0x30, %bpl
je 0x2940f
movq %rax, %r14
leaq 0x2cc56(%rip), %rsi     # 0x56005
movq %rax, %rdi
callq 0x18b20
testl %eax, %eax
je 0x2940f
cmpb $0x31, %bpl
je 0x29423
leaq 0x3175b(%rip), %rsi     # 0x5ab23
movq %r14, %rdi
callq 0x18b20
testl %eax, %eax
je 0x29423
cmpb $0x32, %bpl
je 0x29442
leaq 0x2cc61(%rip), %rsi     # 0x56042
movq %r14, %rdi
callq 0x18b20
testl %eax, %eax
je 0x29442
cmpb $0x33, %bpl
je 0x29461
leaq 0x2cc66(%rip), %rsi     # 0x56060
movq %r14, %rdi
callq 0x18b20
testl %eax, %eax
je 0x29461
leaq 0x2cc82(%rip), %rdx     # 0x5608f
jmp 0x29473
movq 0x58(%rbx), %rax
andl $-0x31, 0x1108(%rax)
leaq 0x2cbe8(%rip), %rdx     # 0x56009
jmp 0x29473
movq 0x58(%rbx), %rax
movl 0x1108(%rax), %ecx
andl $-0x31, %ecx
orl $0x20, %ecx
movl %ecx, 0x1108(%rax)
leaq 0x2cbe1(%rip), %rdx     # 0x56021
jmp 0x29473
movq 0x58(%rbx), %rax
movl 0x1108(%rax), %ecx
andl $-0x31, %ecx
orl $0x10, %ecx
movl %ecx, 0x1108(%rax)
leaq 0x2cbe8(%rip), %rdx     # 0x56047
jmp 0x29473
movq 0x58(%rbx), %rax
orl $0x30, 0x1108(%rax)
leaq 0x2cbf2(%rip), %rdx     # 0x56065
movl $0x2, %esi
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x18da0
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Compass_f
void Cmd_Compass_f (edict_t *ent)
{
	char *p;

	p = gi.args();

	if (p[0]=='0' || !strcmp(p, "off"))
	{
		ent->client->ctf.compass = 0;
		ctf_SafePrint(ent, PRINT_HIGH, "Your compass is now off.\n");
	}
	else if (p[0]=='1' || !strcmp(p, "facing"))
	{
		ent->client->ctf.compass = 1;
		ctf_SafePrint(ent, PRINT_HIGH, "Your compass is now in facing mode.\n");
	}
	else if (p[0]=='2' || !strcmp(p, "on"))
	{
		ent->client->ctf.compass = 2;
		ctf_SafePrint(ent, PRINT_HIGH, "Your compass is now on.\n");
	}
	else if (p[0]=='3' || !strcmp(p, "flag"))
	{
		ent->client->ctf.compass = 3;
		ctf_SafePrint(ent, PRINT_HIGH, "Your compass is now pointing to the enemy flag.\n");
	}
	else
		ctf_SafePrint(ent, PRINT_HIGH, "Format: compass <on/off/facing/flag>\n");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq 0x4016a(%rip), %rax     # 0x69600
callq *0x148(%rax)
movb (%rax), %r12b
leaq 0x2cc0b(%rip), %r14     # 0x560b1
xorl %ebp, %ebp
cmpb $0x30, %r12b
je 0x29540
movq %rax, %r15
leaq 0x2cb49(%rip), %rsi     # 0x56005
movq %rax, %rdi
callq 0x18b20
testl %eax, %eax
je 0x29540
leaq 0x2cc03(%rip), %r14     # 0x560d2
movl $0x1, %ebp
cmpb $0x31, %r12b
je 0x29540
leaq 0x2cbea(%rip), %rsi     # 0x560cb
movq %r15, %rdi
callq 0x18b20
testl %eax, %eax
je 0x29540
leaq 0x2cc03(%rip), %r14     # 0x560f7
movl $0x2, %ebp
cmpb $0x32, %r12b
je 0x29540
leaq 0x3161d(%rip), %rsi     # 0x5ab23
movq %r15, %rdi
callq 0x18b20
testl %eax, %eax
je 0x29540
leaq 0x2cbf7(%rip), %r14     # 0x56110
movl $0x3, %ebp
cmpb $0x33, %r12b
je 0x29540
leaq 0x326c0(%rip), %rsi     # 0x5bbeb
movq %r15, %rdi
callq 0x18b20
testl %eax, %eax
je 0x29540
leaq 0x2cc03(%rip), %r14     # 0x56141
jmp 0x2954a
movq 0x58(%rbx), %rax
movl %ebp, 0x1118(%rax)
movl $0x2, %esi
movq %rbx, %rdi
movq %r14, %rdx
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x18da0
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Referee_f
void Cmd_Referee_f (edict_t *ent)
{
	char *p;

	p = gi.args();

	// check for a password
	//surt adjusted this so that a blank ref password doesn't deny access to rcon,
	//and created rcon access mode
	if (strcmp(rconpassword->string, p) == 0)
	{
		//deny access if password is blank on server
		if (!strlen(rconpassword->string))
		{
			ctf_SafePrint(ent, PRINT_HIGH, "Rcon Mode is off\n");
			return;
		}

		ctf_SafePrint(ent, PRINT_HIGH, "You are now an Rcon\n");
		ent->client->ctf.extra_flags |= CTF_EXTRAFLAGS_REFEREE;
		ent->client->ctf.extra_flags |= CTF_EXTRAFLAGS_RCON;
		Ctf_Menu(ent);
	}

	else if (strcmp(refpassword->string, p) == 0)
	{
		//deny access if password is blank on server
		if (!strlen(refpassword->string))
		{
			ctf_SafePrint(ent, PRINT_HIGH, "Referee Mode is off\n");
			return;
		}
		ctf_SafePrint(ent, PRINT_HIGH, "You are now a Referee\n");
		ent->client->ctf.extra_flags |= CTF_EXTRAFLAGS_REFEREE;
		ent->client->ctf.extra_flags &= ~CTF_EXTRAFLAGS_RCON;
		Ctf_Menu(ent);
	}
	else
	{
		ctf_SafePrint(ent, PRINT_HIGH, "Incorrect Referee Password\n");
		ent->client->ctf.extra_flags &= ~CTF_EXTRAFLAGS_REFEREE;
		ent->client->ctf.extra_flags &= ~CTF_EXTRAFLAGS_RCON;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq 0x4008f(%rip), %rax     # 0x69600
callq *0x148(%rax)
movq %rax, %r14
movq 0x404d7(%rip), %rax     # 0x69a58
movq (%rax), %rax
movq 0x8(%rax), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x18b20
testl %eax, %eax
je 0x295d9
movq 0x40072(%rip), %rax     # 0x69610
movq (%rax), %rax
movq 0x8(%rax), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x18b20
testl %eax, %eax
je 0x29600
leaq 0x2cbff(%rip), %rdx     # 0x561ba
movl $0x2, %esi
movq %rbx, %rdi
callq 0x18da0
movq 0x58(%rbx), %rax
andl $-0x7, 0x1108(%rax)
popq %rbx
popq %r14
popq %r15
retq
cmpb $0x0, (%r15)
je 0x2963d
leaq 0x2cb93(%rip), %rdx     # 0x56179
movl $0x2, %esi
movq %rbx, %rdi
callq 0x18da0
movq 0x58(%rbx), %rax
orl $0x6, 0x1108(%rax)
jmp 0x29630
cmpb $0x0, (%r15)
je 0x29646
leaq 0x2cb96(%rip), %rdx     # 0x561a3
movl $0x2, %esi
movq %rbx, %rdi
callq 0x18da0
movq 0x58(%rbx), %rax
movl 0x1108(%rax), %ecx
andl $-0x7, %ecx
orl $0x2, %ecx
movl %ecx, 0x1108(%rax)
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x197e0
leaq 0x2cb23(%rip), %rdx     # 0x56167
jmp 0x2964d
leaq 0x2cb41(%rip), %rdx     # 0x5618e
movl $0x2, %esi
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x18da0
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_GotoMap_f
void Cmd_GotoMap_f (edict_t *ent)
{
	char *p;
	int i;
	char message[MAX_INFO_STRING];

	if (!(ent->client->ctf.extra_flags & CTF_EXTRAFLAGS_REFEREE))
	{
		ctf_SafePrint(ent, PRINT_HIGH, "You are not a Referee.\n");
		return;
	}


	p = gi.args();

	if (strlen(p))
	{
		// convert to lower case for comparison
		for (i = 0; i < (int)strlen(p); i++)
			p[i] = tolower(p[i]);

		for (i=0; maplist[i].mapname; i++)
		{
			if (!strcmp(maplist[i].mapname, p))
			{
				ctf_ChangeMap(p, false);
				return;
			}
		}
		sprintf(message, "%s is not a map from the maplist.\n", p);
		ctf_SafePrint(ent, PRINT_HIGH, message);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x208, %rsp            # imm = 0x208
movq %rdi, %rbx
movq 0x58(%rdi), %rax
testb $0x2, 0x1108(%rax)
jne 0x2969f
leaq 0x2cb52(%rip), %rdx     # 0x561d6
movl $0x2, %esi
movq %rbx, %rdi
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x18da0
movq 0x3ff5a(%rip), %rax     # 0x69600
callq *0x148(%rax)
cmpb $0x0, (%rax)
je 0x29742
movq %rax, %r14
movq %rax, %rdi
callq 0x18680
testl %eax, %eax
jle 0x296f0
xorl %r12d, %r12d
callq 0x19a30
movq %rax, %r15
movq (%r15), %rax
movsbq (%r14,%r12), %rcx
movb (%rax,%rcx,4), %al
movb %al, (%r14,%r12)
incq %r12
movq %r14, %rdi
callq 0x18680
cltq
cmpq %rax, %r12
jl 0x296cf
movq 0x400d1(%rip), %r15     # 0x697c8
movq (%r15), %rdi
testq %rdi, %rdi
je 0x2971b
addq $0x18, %r15
movq %r14, %rsi
callq 0x18b20
testl %eax, %eax
je 0x29751
movq (%r15), %rdi
addq $0x18, %r15
testq %rdi, %rdi
jne 0x29703
leaq 0x2cacc(%rip), %rsi     # 0x561ee
movq %rsp, %r15
movq %r15, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0x19700
movl $0x2, %esi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x18da0
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %r14, %rdi
xorl %esi, %esi
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x19750
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Users_f
void Cmd_Users_f (edict_t *ent)
{
//	int		i;
//	int		count=0;
//	char	small[64];
//	char	large[1280];

	char message[MAX_INFO_STRING];
	char status[MAX_INFO_STRING];

	// print information
	edict_t * player = NULL;
	player = ctf_findplayer(NULL, NULL, CTF_TEAM_IGNORETEAM);
	while (player)
	{
		strcpy(status, "");
		if (player->client->ctf.extra_flags & CTF_EXTRAFLAGS_RCON)
			strcat(status, "[RCON] ");
		else if (player->client->ctf.extra_flags & CTF_EXTRAFLAGS_REFEREE)
			strcat(status, "(REF)  ");
		else
			strcat(status, "PLAYER ");
		sprintf(message, " id: %lu %s frags: %d\n",
			player->client->ctf.ctfid,
			player->client->pers.netname,
			player->client->ps.stats[STAT_FRAGS]);
		strcat(status, message);
		ctf_SafePrint(ent, PRINT_HIGH, status);

		player = ctf_findplayer(player, NULL, CTF_TEAM_IGNORETEAM);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x408, %rsp            # imm = 0x408
movq %rdi, %rbx
xorl %edi, %edi
xorl %esi, %esi
movl $0xfffffffc, %edx       # imm = 0xFFFFFFFC
callq 0x19170
testq %rax, %rax
je 0x29853
movq %rax, %r14
movq %rsp, %r15
leaq 0x2ca70(%rip), %r12     # 0x56211
leaq 0x200(%rsp), %r13
movb $0x0, (%rsp)
movq 0x58(%r14), %rax
movl 0x1108(%rax), %ebp
movq %r15, %rdi
testb $0x4, %bpl
jne 0x297d7
callq 0x18680
testb $0x2, %bpl
jne 0x297e8
movabsq $0x20524559414c50, %rcx # imm = 0x20524559414C50
jmp 0x297f2
callq 0x18680
movabsq $0x205d4e4f43525b, %rcx # imm = 0x205D4E4F43525B
jmp 0x297f2
movabsq $0x20202946455228, %rcx # imm = 0x20202946455228
movq %rcx, (%rsp,%rax)
movq 0x58(%r14), %rcx
movq 0x9120(%rcx), %rdx
movswl 0x94(%rcx), %r8d
addq $0x2c0, %rcx            # imm = 0x2C0
movq %r13, %rdi
movq %r12, %rsi
xorl %eax, %eax
callq 0x19700
movq %r15, %rdi
movq %r13, %rsi
callq 0x19640
movl $0x2, %esi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x18da0
movq %r14, %rdi
xorl %esi, %esi
movl $0xfffffffc, %edx       # imm = 0xFFFFFFFC
callq 0x19170
movq %rax, %r14
testq %rax, %rax
jne 0x297a9
addq $0x408, %rsp            # imm = 0x408
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_QuadTime_f
void Cmd_QuadTime_f (edict_t *ent) {
        unsigned long i=0;
        char *p;
        gitem_t * target = NULL;

        if (!(ent->client->ctf.extra_flags & (CTF_EXTRAFLAGS_REFEREE | CTF_EXTRAFLAGS_RCON)))
        {
                ctf_SafePrint(ent, PRINT_HIGH, "You are not a Referee or Rcon\n");
                return;
        }

        p = gi.args();
        if (!sscanf(p, "%lu", &i))
        {
                ctf_SafePrint(ent, PRINT_HIGH, "Usage: quadtime <seconds>\n");
                return;
        }

	target = FindItem("Quad Damage");
	if (target && i > 0 && i < 1200) {
		target->quantity = i;
                ctf_SafePrint(ent, PRINT_HIGH, "Quad respawn updated\n");
	}
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq $0x0, 0x8(%rsp)
movq 0x58(%rdi), %rax
testb $0x6, 0x1108(%rax)
je 0x29a5d
movq 0x3fbfe(%rip), %rax     # 0x69600
callq *0x148(%rax)
leaq 0x2a3b0(%rip), %rsi     # 0x53dbf
leaq 0x8(%rsp), %rdx
movq %rax, %rdi
xorl %eax, %eax
callq 0x18fe0
testl %eax, %eax
je 0x29a66
leaq 0x29d6e(%rip), %rdi     # 0x53797
callq 0x189e0
testq %rax, %rax
setne %dl
movq 0x8(%rsp), %rcx
leaq -0x1(%rcx), %rsi
cmpq $0x4af, %rsi            # imm = 0x4AF
setb %sil
andb %dl, %sil
cmpb $0x1, %sil
jne 0x29a7a
movl %ecx, 0x5c(%rax)
leaq 0x2c8ff(%rip), %rdx     # 0x5635a
jmp 0x29a6d
leaq 0x2c8bc(%rip), %rdx     # 0x56320
jmp 0x29a6d
leaq 0x2c8d2(%rip), %rdx     # 0x5633f
movl $0x2, %esi
movq %rbx, %rdi
callq 0x18da0
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Match_f
void Cmd_Match_f (edict_t *ent)
{
	char *p;
	int i;
	char message[MAX_INFO_STRING];

	if (!(ent->client->ctf.extra_flags & CTF_EXTRAFLAGS_REFEREE))
	{
		ctf_SafePrint(ent, PRINT_HIGH, "You are not a Referee\n");
		return;
	}

	p = gi.args();

	if (!p || !strlen(p))
	{
		ctf_SafePrint(ent, PRINT_HIGH, "USAGE: match <mapname>\n");
		return;
	}
	else
	{
		for (i=0; maplist[i].mapname; i++)
		{
			if (!strcmp(maplist[i].mapname, p))
			{
				ctf_SafePrint(ent, PRINT_HIGH, "Match countdown beginning.\n");
				StartMatch (p);
				return;
			}
		}
		sprintf(message, "%s is not a map from the maplist.\n", p);
		ctf_SafePrint(ent, PRINT_HIGH, message);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x200, %rsp            # imm = 0x200
movq %rdi, %rbx
movq 0x58(%rdi), %rax
testb $0x2, 0x1108(%rax)
jne 0x29c59
leaq 0x2c0fb(%rip), %rdx     # 0x55d4f
jmp 0x29cd9
movq 0x3f9a0(%rip), %rax     # 0x69600
callq *0x148(%rax)
testq %rax, %rax
je 0x29cd2
movq %rax, %r14
cmpb $0x0, (%rax)
je 0x29cd2
movq 0x3fb4e(%rip), %r15     # 0x697c8
movq (%r15), %rdi
testq %rdi, %rdi
je 0x29c9e
addq $0x18, %r15
movq %r14, %rsi
callq 0x18b20
testl %eax, %eax
je 0x29cf2
movq (%r15), %rdi
addq $0x18, %r15
testq %rdi, %rdi
jne 0x29c86
leaq 0x2c549(%rip), %rsi     # 0x561ee
movq %rsp, %r15
movq %r15, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0x19700
movl $0x2, %esi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x18da0
addq $0x200, %rsp            # imm = 0x200
popq %rbx
popq %r14
popq %r15
retq
leaq 0x2c746(%rip), %rdx     # 0x5641f
movl $0x2, %esi
movq %rbx, %rdi
addq $0x200, %rsp            # imm = 0x200
popq %rbx
popq %r14
popq %r15
jmp 0x18da0
leaq 0x2c73e(%rip), %rdx     # 0x56437
movl $0x2, %esi
movq %rbx, %rdi
callq 0x18da0
movq %r14, %rdi
addq $0x200, %rsp            # imm = 0x200
popq %rbx
popq %r14
popq %r15
jmp 0x18320
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_PingAlert_f
void Cmd_PingAlert_f (edict_t *ent)
{
	char *p;
	int i, j;

	i = j = 0;

	p = gi.args();
	if (sscanf(p, "%d %d", &i, &j) < 1)
	{
		ctf_SafePrint(ent, PRINT_HIGH, "Usage: pingalert <floor> <ceiling>\nUse zero to set no alert for that value.\n");
		return;
	}
	ent->client->ctf.pingalertfloor = i;
	ent->client->ctf.pingalertceiling = j;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
xorl %eax, %eax
leaq 0x8(%rsp), %r14
movl %eax, (%r14)
leaq 0xc(%rsp), %r15
movl %eax, (%r15)
movq 0x3f8c1(%rip), %rax     # 0x69600
callq *0x148(%rax)
leaq 0x29fd3(%rip), %rsi     # 0x53d1f
movq %rax, %rdi
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x18fe0
testl %eax, %eax
jle 0x29d7a
movl 0xc(%rsp), %eax
movq 0x58(%rbx), %rcx
movl %eax, 0x1110(%rcx)
movl 0x8(%rsp), %eax
movl %eax, 0x1114(%rcx)
jmp 0x29d8e
leaq 0x2c6d2(%rip), %rdx     # 0x56453
movl $0x2, %esi
movq %rbx, %rdi
callq 0x18da0
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_PlayerList_f
void Cmd_PlayerList_f(edict_t *ent)
{
	int i;
	char st[80];
	char text[MAX_MSGLEN];
	edict_t *e2;

	// connect time, ping, score, name
	*text = 0;
	for (i = 0, e2 = g_edicts + 1; i < maxclients->value; i++, e2++) {
		if (!e2->inuse)
			continue;

		Com_sprintf(st, sizeof(st), "%02d:%02d %4d %3d %s%s id: %i\n",
			(level.framenum - e2->client->resp.enterframe) / 600,
			((level.framenum - e2->client->resp.enterframe) % 600)/10,
			e2->client->ping,
			e2->client->resp.score,
			e2->client->pers.netname,
			e2->client->resp.spectator ? " (spectator)" : "",
			e2->client->ctf.ctfid);
		if (strlen(text) + strlen(st) > sizeof(text) - 50) {
			sprintf(text+strlen(text), "And more...\n");
			gi.cprintf(ent, PRINT_HIGH, "%s", text);
			return;
		}
		strcat(text, st);
	}
	gi.cprintf(ent, PRINT_HIGH, "%s", text);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x5d8, %rsp            # imm = 0x5D8
movq %rdi, 0x8(%rsp)
movb $0x0, 0x60(%rsp)
movq 0x3f480(%rip), %rax     # 0x69530
movq (%rax), %rax
movss 0x20(%rax), %xmm0
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jbe 0x2a1fd
movq 0x3f48d(%rip), %rax     # 0x69558
movl $0x508, %ebx            # imm = 0x508
addq (%rax), %rbx
movl $0x1, %r14d
leaq 0x10(%rsp), %r15
leaq 0x60(%rsp), %r12
cmpl $0x0, (%rbx)
je 0x2a1b3
movq 0x3fcad(%rip), %rax     # 0x69da0
movl (%rax), %eax
movq -0x8(%rbx), %r10
subl 0xdf0(%r10), %eax
cltq
imulq $0x1b4e81b5, %rax, %rcx # imm = 0x1B4E81B5
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x26, %rcx
addl %edx, %ecx
imull $0x258, %ecx, %edx      # imm = 0x258
subl %edx, %eax
cltq
imulq $0x66666667, %rax, %r8  # imm = 0x66666667
movq %r8, %rax
shrq $0x3f, %rax
sarq $0x22, %r8
addl %eax, %r8d
movl 0xb8(%r10), %r9d
movl 0xdf4(%r10), %r11d
cmpl $0x0, 0xe04(%r10)
leaq 0x2c0(%r10), %r13
leaq 0x2c397(%rip), %rbp     # 0x564f0
leaq 0x2ada5(%rip), %rax     # 0x54f05
cmoveq %rax, %rbp
movq %r15, %rdi
movl $0x50, %esi
leaq 0x2c35e(%rip), %rdx     # 0x564d1
xorl %eax, %eax
pushq 0x9120(%r10)
pushq %rbp
pushq %r13
pushq %r11
callq 0x18e10
addq $0x20, %rsp
movq %r12, %rdi
callq 0x18680
movq %rax, %r13
movq %r15, %rdi
callq 0x18680
addq %r13, %rax
cmpq $0x547, %rax            # imm = 0x547
jae 0x2a1df
movq %r12, %rdi
movq %r15, %rsi
callq 0x19640
xorps %xmm0, %xmm0
cvtsi2ss %r14d, %xmm0
movq 0x3f36e(%rip), %rax     # 0x69530
movq (%rax), %rax
movss 0x20(%rax), %xmm1
addq $0x4a8, %rbx            # imm = 0x4A8
incl %r14d
ucomiss %xmm0, %xmm1
ja 0x2a0e3
jmp 0x2a1fd
movabsq $0xa2e2e2e65726f, %rax  # imm = 0xA2E2E2E65726F
movq %rax, 0x65(%rsp,%r13)
movabsq $0x65726f6d20646e41, %rax # imm = 0x65726F6D20646E41
movq %rax, 0x60(%rsp,%r13)
movq 0x3f3fc(%rip), %r8      # 0x69600
leaq 0x297a2(%rip), %rdx     # 0x539ad
leaq 0x60(%rsp), %rcx
movq 0x8(%rsp), %rdi
movl $0x2, %esi
xorl %eax, %eax
callq *0x10(%r8)
addq $0x5d8, %rsp            # imm = 0x5D8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_Observe_f
void Cmd_Observe_f(edict_t *ent, int Observer_Type)
{
int i;
int numspec;

	//first check to see if the maxspectator var is set.
	for(i = 1, numspec = 0; i <= maxclients->value; i++)
		if(g_edicts[i].inuse && g_edicts[i].client->pers.spectator)
			numspec++;

	if (numspec >= maxspectators->value)
	{
		gi.cprintf(ent, PRINT_HIGH, "Server spectator limit is full.");
		return;
	}



	if(Observer_Type == CTF_TEAM_OBSERVER_BLUE)
	{
		if(!Team_Observer_OK(CTF_TEAM_BLUE, ent))
			return;

		//gi.bprintf (PRINT_HIGH, "%s is watching the blue team\n", ent->client->pers.netname);
	}
	else if(Observer_Type == CTF_TEAM_OBSERVER_RED)
	{
		if(!Team_Observer_OK(CTF_TEAM_RED, ent))
			return;

		//gi.bprintf (PRINT_HIGH, "%s is watching the red team\n", ent->client->pers.netname);
	}
	//else
		//gi.bprintf (PRINT_HIGH, "%s has moved to the sidelines\n", ent->client->pers.netname);


	Drop_All(ent);
	ent->client->ctf.teamnum = Observer_Type;
	ent->client->chase_target = NULL;
	//ent->client->pers.spectator = 1;
	//ent->client->resp.spectator = 1;
	ForceCommand(ent, "spectator 1");
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
movq 0x3f2ef(%rip), %rax     # 0x69530
movq (%rax), %rax
movss 0x20(%rax), %xmm0
xorps %xmm1, %xmm1
ucomiss 0x29cd5(%rip), %xmm0    # 0x53f28
jb 0x2a299
movq 0x3f2fc(%rip), %rcx     # 0x69558
movl $0x508, %eax            # imm = 0x508
addq (%rcx), %rax
xorl %ecx, %ecx
movl $0x2, %edx
cmpl $0x0, (%rax)
je 0x2a27e
movq -0x8(%rax), %rsi
cmpl $0x1, 0x750(%rsi)
sbbl $-0x1, %ecx
xorps %xmm1, %xmm1
cvtsi2ss %edx, %xmm1
addq $0x4a8, %rax            # imm = 0x4A8
incl %edx
ucomiss %xmm1, %xmm0
jae 0x2a26b
xorps %xmm1, %xmm1
cvtsi2ss %ecx, %xmm1
movq 0x3fc98(%rip), %rax     # 0x69f38
movq (%rax), %rax
ucomiss 0x20(%rax), %xmm1
jae 0x2a2ba
cmpl $-0x3, %ebp
je 0x2a2de
cmpl $-0x2, %ebp
jne 0x2a2ef
movl $0x2, %edi
jmp 0x2a2e3
movq 0x3f33f(%rip), %rax     # 0x69600
movq 0x10(%rax), %rcx
leaq 0x2c23e(%rip), %rdx     # 0x5650a
movq %rbx, %rdi
movl $0x2, %esi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
jmpq *%rcx
movl $0x1, %edi
movq %rbx, %rsi
callq 0x19730
testl %eax, %eax
je 0x2a321
movq %rbx, %rdi
callq 0x195d0
movq 0x58(%rbx), %rax
movl %ebp, 0x1100(%rax)
movq $0x0, 0xf30(%rax)
leaq 0x2c217(%rip), %rsi     # 0x5652a
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x18c40
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_ToggleFastSwitch_f
void Cmd_ToggleFastSwitch_f(edict_t *ent)
{
	if (!ISREF(ent)) {
		gi.cprintf(ent, PRINT_HIGH, "Referee-only command\n");
		return;
	}

	char *newval = (((int)fastswitch->value) == 1) ? "0" : "1";
	gi.cvar_set("fastswitch", newval);
	gi.bprintf(PRINT_HIGH, "Fast weapon switching now %sabled\n", (fastswitch->value) ? "en" : "dis");
}

// Assembly:
movq 0x58(%rdi), %rax
testb $0x2, 0x1108(%rax)
jne 0x2a350
movq 0x3f2c4(%rip), %rax     # 0x69600
movq 0x10(%rax), %rcx
leaq 0x2b1ff(%rip), %rdx     # 0x55546
movl $0x2, %esi
xorl %eax, %eax
jmpq *%rcx
pushq %r14
pushq %rbx
pushq %rax
movq 0x3f845(%rip), %rbx     # 0x69ba0
movq (%rbx), %rax
cvttss2si 0x20(%rax), %eax
cmpl $0x1, %eax
leaq 0x31a0f(%rip), %rax     # 0x5bd7c
leaq 0x28cf0(%rip), %rsi     # 0x53064
cmoveq %rax, %rsi
movq 0x3f281(%rip), %r14     # 0x69600
leaq 0x2c65a(%rip), %rdi     # 0x569e0
callq *0x128(%r14)
movq (%rbx), %rax
xorps %xmm0, %xmm0
ucomiss 0x20(%rax), %xmm0
leaq 0x2cdc6(%rip), %rax     # 0x57164
leaq 0x2c1b4(%rip), %rdx     # 0x56559
cmovneq %rax, %rdx
movq (%r14), %rcx
cmovpq %rax, %rdx
leaq 0x2c17f(%rip), %rsi     # 0x56536
movl $0x2, %edi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmpq *%rcx
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_ChangeMap_f
void Cmd_ChangeMap_f(edict_t *ent)
{
	if (!ISREF(ent)) {
		gi.cprintf(ent, PRINT_HIGH, "Referee-only command\n");
		return;
	}

	if (gi.argc() < 2) {
		gi.cprintf(ent, PRINT_HIGH, "Usage: changemap <mapname>\n");
		return;
	}

	char *map = gi.argv(1);
	ctf_ChangeMap(map, false);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x58(%rdi), %rax
testb $0x2, 0x1108(%rax)
jne 0x2a6ab
movq 0x3ef62(%rip), %rax     # 0x69600
movq 0x10(%rax), %rcx
leaq 0x2ae9d(%rip), %rdx     # 0x55546
jmp 0x2a6c9
movq 0x3ef4e(%rip), %r14     # 0x69600
callq *0x138(%r14)
cmpl $0x1, %eax
jg 0x2a6dc
movq 0x10(%r14), %rcx
leaq 0x2c1f8(%rip), %rdx     # 0x568c1
movq %rbx, %rdi
movl $0x2, %esi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmpq *%rcx
movl $0x1, %edi
callq *0x140(%r14)
movq %rax, %rdi
xorl %esi, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x19750
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_cmds.c
// Function: Cmd_SetTimelimit_f
void Cmd_SetTimelimit_f(edict_t *ent)
{
    if (!ISREF(ent)) {
        gi.cprintf(ent, PRINT_HIGH, "Referee-only command\n");
        return;
    }

    if (gi.argc() < 2) {
        gi.cprintf(ent, PRINT_HIGH, "Usage: settimelimit <minutes>\n");
        return;
    }

    char *minutes = gi.argv(1);
    gi.cvar_set("timelimit", minutes);

    gi.cprintf(ent, PRINT_HIGH, "Timelimit set to %d minutes\n", (int)timelimit->value);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x58(%rdi), %rax
testb $0x2, 0x1108(%rax)
jne 0x2a721
movq 0x3eeec(%rip), %rax     # 0x69600
movq 0x10(%rax), %rcx
leaq 0x2ae27(%rip), %rdx     # 0x55546
jmp 0x2a73f
movq 0x3eed8(%rip), %r14     # 0x69600
callq *0x138(%r14)
cmpl $0x1, %eax
jg 0x2a752
movq 0x10(%r14), %rcx
leaq 0x2c19e(%rip), %rdx     # 0x568dd
movq %rbx, %rdi
movl $0x2, %esi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmpq *%rcx
movl $0x1, %edi
callq *0x140(%r14)
leaq 0x28dcb(%rip), %rdi     # 0x53530
movq %rax, %rsi
callq *0x128(%r14)
movq 0x3ef3a(%rip), %rax     # 0x696b0
movq (%rax), %rax
cvttss2si 0x20(%rax), %ecx
movq 0x10(%r14), %r8
leaq 0x2c173(%rip), %rdx     # 0x568fc
movq %rbx, %rdi
movl $0x2, %esi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmpq *%r8
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_combat.c
// Function: SpawnDamage
void SpawnDamage (int type, vec3_t origin, vec3_t normal, int damage)
{
	if (damage > 255)
		damage = 255;
	gi.WriteByte (svc_temp_entity);
	gi.WriteByte (type);
//	gi.WriteByte (damage);
	gi.WritePosition (origin);
	gi.WriteDir (normal);
	gi.multicast (origin, MULTICAST_PVS);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movl %edi, %ebp
movq 0x3df1a(%rip), %r15     # 0x69600
movl $0x3, %edi
callq *0xc8(%r15)
movl %ebp, %edi
callq *0xc8(%r15)
movq %r14, %rdi
callq *0xf0(%r15)
movq %rbx, %rdi
callq *0xf8(%r15)
movq 0xb0(%r15), %rax
movq %r14, %rdi
movl $0x2, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmpq *%rax
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_combat.c
// Function: CheckTeamDamage
qboolean CheckTeamDamage (edict_t *targ, edict_t *attacker)
{
		//FIXME make the next line real and uncomment this block
		// if ((ability to damage a teammate == OFF) && (targ's team == attacker's team))
	// TEAM CODE - LM_JORM
	if (targ == attacker || matchstate == MATCH_RAILGUN_INPLAY)
		return false;
	if (attacker->client && targ->client && (OnSameTeam(attacker, targ)))
		return true;
	return false;
}

// Assembly:
xorl %eax, %eax
cmpq %rsi, %rdi
je 0x2b76a
movq 0x3e0a0(%rip), %rdx     # 0x697d8
cmpl $0x6, (%rdx)
je 0x2b76a
cmpq $0x0, 0x58(%rsi)
je 0x2b76b
movq %rdi, %rcx
cmpq $0x0, 0x58(%rdi)
je 0x2b76b
pushq %rax
movq %rsi, %rdi
movq %rcx, %rsi
callq 0x18700
movl %eax, %ecx
movl $0x1, %eax
testl %ecx, %ecx
leaq 0x8(%rsp), %rsp
je 0x2b76b
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_func.c
// Function: Move_Final
void Move_Final (edict_t *ent)
{
	if (ent->moveinfo.remaining_distance == 0)
	{
		Move_Done (ent);
		return;
	}

	VectorScale (ent->moveinfo.dir, ent->moveinfo.remaining_distance / FRAMETIME, ent->velocity);

	ent->think = Move_Done;
	ent->nextthink = level.time + FRAMETIME;
}

// Assembly:
movq %rdi, %rax
movss 0x3a4(%rdi), %xmm0
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jne 0x2c3de
jp 0x2c3de
movl $0x0, 0x1c8(%rax)
movq $0x0, 0x1c0(%rax)
movq %rax, %rdi
jmpq *0x3b0(%rax)
pushq %rbx
leaq 0x38c(%rax), %rdi
divss 0x27ea2(%rip), %xmm0    # 0x54290
leaq 0x1c0(%rax), %rsi
movq %rax, %rbx
callq 0x189d0
movq 0x3d46c(%rip), %rax     # 0x69870
movq %rax, 0x210(%rbx)
movq 0x3d98e(%rip), %rax     # 0x69da0
movss 0x27e76(%rip), %xmm0    # 0x54290
addss 0x4(%rax), %xmm0
movss %xmm0, 0x200(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/QwazyWabbitWOS[P]lmctf60/g_func.c
// Function: Move_Begin
void Move_Begin (edict_t *ent)
{
	float	frames;

	if ((ent->moveinfo.speed * FRAMETIME) >= ent->moveinfo.remaining_distance)
	{
		Move_Final (ent);
		return;
	}
	VectorScale (ent->moveinfo.dir, ent->moveinfo.speed, ent->velocity);
	frames = floor((ent->moveinfo.remaining_distance / ent->moveinfo.speed) / FRAMETIME);
	ent->moveinfo.remaining_distance -= frames * ent->moveinfo.speed * FRAMETIME;
	ent->nextthink = level.time + (frames * FRAMETIME);
	ent->think = Move_Final;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movss 0x378(%rdi), %xmm0
movss 0x27e4f(%rip), %xmm1    # 0x54290
mulss %xmm0, %xmm1
ucomiss 0x3a4(%rdi), %xmm1
jae 0x2c4e6
leaq 0x38c(%rbx), %rdi
leaq 0x1c0(%rbx), %rsi
callq 0x189d0
movss 0x378(%rbx), %xmm1
movss %xmm1, 0x8(%rsp)
movss 0x3a4(%rbx), %xmm0
movss %xmm0, 0xc(%rsp)
divss %xmm1, %xmm0
divss 0x27e03(%rip), %xmm0    # 0x54290
callq 0x19540
movss 0x8(%rsp), %xmm1
mulss %xmm0, %xmm1
movss 0x27dec(%rip), %xmm3    # 0x54290
mulss %xmm3, %xmm1
movss 0xc(%rsp), %xmm2
subss %xmm1, %xmm2
movss %xmm2, 0x3a4(%rbx)
movq 0x3d8df(%rip), %rax     # 0x69da0
mulss %xmm3, %xmm0
addss 0x4(%rax), %xmm0
movss %xmm0, 0x200(%rbx)
movq 0x3d787(%rip), %rax     # 0x69c60
movq %rax, 0x210(%rbx)
addq $0x10, %rsp
popq %rbx
retq
movq %rbx, %rdi
addq $0x10, %rsp
popq %rbx
jmp 0x19b30