// File: /workspace/github_c_makefile_star2_O0/QwazyWabbitWOS[P]lmctf60/plasma.c
// Function: fire_plasma_spread
void
fire_plasma_spread
(edict_t *goop_c, vec3_t start, vec3_t dir) {
	edict_t	*goop_l = Spawn_Goop(goop_c->owner, start);
	edict_t	*goop_r = Spawn_Goop(goop_c->owner, start);
	vec3_t	angles;
	
	goop_l->movetype = MOVETYPE_FLYMISSILE;
	goop_c->movetype = MOVETYPE_FLYMISSILE;
	goop_r->movetype = MOVETYPE_FLYMISSILE;

	VectorClear (goop_l->mins);
	VectorClear (goop_l->maxs);
	VectorClear (goop_c->mins);
	VectorClear (goop_c->maxs);
	VectorClear (goop_r->mins);
	VectorClear (goop_r->maxs);

	goop_l->dmg= 1;
	goop_c->dmg= 1;
	goop_r->dmg= 1;

	//bat  this really shouldn't even matter???
	//if(is_quad)
	//{
	//	goop_l->dmg=	7 + 9 * PLASMA_SPREAD_DAMAGE * 4;
	//	goop_c->dmg=	7 + 9 * PLASMA_SPREAD_DAMAGE * 4;
	//	goop_r->dmg=	7 + 9 * PLASMA_SPREAD_DAMAGE * 4;
	//}
	//else
	//{
	//	goop_l->dmg=	7 + 9 * PLASMA_SPREAD_DAMAGE;
	//	goop_c->dmg=	7 + 9 * PLASMA_SPREAD_DAMAGE;
	//	goop_r->dmg=	7 + 9 * PLASMA_SPREAD_DAMAGE;
	//}



	// center spread, line of sight
	VectorScale(dir, PLASMA_SPREAD_SPEED, goop_c->velocity);
	vectoangles(dir,angles);

	// right spread, has 10+ in yaw
	angles[YAW] -= 10;
	AngleVectors( angles, dir, NULL, NULL );
	VectorScale(dir, PLASMA_SPREAD_SPEED, goop_r->velocity);

	// left spread, has 10- in yaw
	angles[YAW] += 20;
	AngleVectors( angles, dir, NULL, NULL );
	VectorScale(dir, PLASMA_SPREAD_SPEED, goop_l->velocity);

	goop_l->touch = plasma_spread_touch;
	goop_c->touch = plasma_spread_touch;
	goop_r->touch = plasma_spread_touch;
	
	goop_l->think = G_FreeEdict;
	goop_c->think = G_FreeEdict;
	goop_r->think = G_FreeEdict;
	goop_l->nextthink = level.time + 3.0;
	goop_c->nextthink = level.time + 3.0;
	goop_r->nextthink = level.time + 3.0;

	gi.linkentity(goop_l);
	gi.linkentity(goop_c);
	gi.linkentity(goop_r);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq 0x110(%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x188e0
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq 0x110(%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x188e0
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movl $0x8, 0x118(%rax)
movq -0x8(%rbp), %rax
movl $0x8, 0x118(%rax)
movq -0x28(%rbp), %rax
movl $0x8, 0x118(%rax)
movq -0x20(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd4(%rax)
movq -0x20(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd0(%rax)
movq -0x20(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xcc(%rax)
movq -0x20(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xe0(%rax)
movq -0x20(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xdc(%rax)
movq -0x20(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd8(%rax)
movq -0x8(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd4(%rax)
movq -0x8(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd0(%rax)
movq -0x8(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xcc(%rax)
movq -0x8(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xe0(%rax)
movq -0x8(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xdc(%rax)
movq -0x8(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd8(%rax)
movq -0x28(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd4(%rax)
movq -0x28(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd0(%rax)
movq -0x28(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xcc(%rax)
movq -0x28(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xe0(%rax)
movq -0x28(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xdc(%rax)
movq -0x28(%rbp), %rax
xorps %xmm0, %xmm0
movss %xmm0, 0xd8(%rax)
movq -0x20(%rbp), %rax
movl $0x1, 0x280(%rax)
movq -0x8(%rbp), %rax
movl $0x1, 0x280(%rax)
movq -0x28(%rbp), %rax
movl $0x1, 0x280(%rax)
movq -0x18(%rbp), %rdi
movq -0x8(%rbp), %rsi
addq $0x1c0, %rsi            # imm = 0x1C0
movss 0x48e9f(%rip), %xmm0    # 0x70c0c
callq 0x18a80
movq -0x18(%rbp), %rdi
leaq -0x34(%rbp), %rsi
callq 0x192a0
movss -0x30(%rbp), %xmm0
movss 0x48164(%rip), %xmm1    # 0x6fef0
subss %xmm1, %xmm0
movss %xmm0, -0x30(%rbp)
leaq -0x34(%rbp), %rdi
movq -0x18(%rbp), %rsi
xorl %eax, %eax
movl %eax, %ecx
movq %rcx, %rdx
callq 0x183e0
movq -0x18(%rbp), %rdi
movq -0x28(%rbp), %rsi
addq $0x1c0, %rsi            # imm = 0x1C0
movss 0x48e4c(%rip), %xmm0    # 0x70c0c
callq 0x18a80
movss 0x48e43(%rip), %xmm0    # 0x70c10
addss -0x30(%rbp), %xmm0
movss %xmm0, -0x30(%rbp)
leaq -0x34(%rbp), %rdi
movq -0x18(%rbp), %rsi
xorl %eax, %eax
movl %eax, %ecx
movq %rcx, %rdx
callq 0x183e0
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rsi
addq $0x1c0, %rsi            # imm = 0x1C0
movss 0x48e0a(%rip), %xmm0    # 0x70c0c
callq 0x18a80
movq -0x20(%rbp), %rax
movq 0x5aeb6(%rip), %rcx     # 0x82cc8
movq %rcx, 0x220(%rax)
movq -0x8(%rbp), %rax
movq 0x5aea4(%rip), %rcx     # 0x82cc8
movq %rcx, 0x220(%rax)
movq -0x28(%rbp), %rax
movq 0x5ae92(%rip), %rcx     # 0x82cc8
movq %rcx, 0x220(%rax)
movq -0x20(%rbp), %rax
movq 0x5a5e8(%rip), %rcx     # 0x82430
movq %rcx, 0x210(%rax)
movq -0x8(%rbp), %rax
movq 0x5a5d6(%rip), %rcx     # 0x82430
movq %rcx, 0x210(%rax)
movq -0x28(%rbp), %rax
movq 0x5a5c4(%rip), %rcx     # 0x82430
movq %rcx, 0x210(%rax)
movq 0x5af26(%rip), %rax     # 0x82da0
movss 0x4(%rax), %xmm0
cvtss2sd %xmm0, %xmm0
movsd 0x48d9d(%rip), %xmm1    # 0x70c28
addsd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm0
movq -0x20(%rbp), %rax
movss %xmm0, 0x200(%rax)
movq 0x5aefa(%rip), %rax     # 0x82da0
movss 0x4(%rax), %xmm0
cvtss2sd %xmm0, %xmm0
movsd 0x48d71(%rip), %xmm1    # 0x70c28
addsd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm0
movq -0x8(%rbp), %rax
movss %xmm0, 0x200(%rax)
movq 0x5aece(%rip), %rax     # 0x82da0
movss 0x4(%rax), %xmm0
cvtss2sd %xmm0, %xmm0
movsd 0x48d45(%rip), %xmm1    # 0x70c28
addsd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm0
movq -0x28(%rbp), %rax
movss %xmm0, 0x200(%rax)
movq 0x5a702(%rip), %rax     # 0x82600
movq 0x90(%rax), %rax
movq -0x20(%rbp), %rdi
callq *%rax
movq 0x5a6ee(%rip), %rax     # 0x82600
movq 0x90(%rax), %rax
movq -0x8(%rbp), %rdi
callq *%rax
movq 0x5a6da(%rip), %rax     # 0x82600
movq 0x90(%rax), %rax
movq -0x28(%rbp), %rdi
callq *%rax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)