Kick that head!

Discuss anything you'd like that doesn't belong in the other forums.
User avatar
Joao Lucas
Level 6
Posts: 399
Joined: Mon Jun 26, 2006 3:38 pm
Favorite FvF Class: Laser Android

Kick that head!

Post by Joao Lucas »

Gunter, I found a cool coding that allows you to kick heads! Look:

Code: Select all

Step 1
1) Open player.qc.
2) Find the function ThrowHead()
3) Replace this:

self.solid = SOLID_NOT;

With:

self.solid = SOLID_TRIGGER;
self.touch = kick_touch;

4) Find the function ThrowGib()
5) Replace:

new.solid = SOLID_NOT;

With:

new.solid = SOLID_TRIGGER;   // Set it up for a trigger event
new.touch = kick_touch;      // Call kick_touch when touched

6) Open up world.qc
7) Find the line (188) that says:

// sounds used from C physics code

8) Below it, add:

precache_sound ("zombie/z_miss.wav");
precache_sound ("zombie/z_hit.wav");

9) Now, find the fuction CopyToBodyQue().
10) At the beginning of the function, add this:

bodyque_head.touch = ent.touch;
bodyque_head.solid = ent.solid;

11)Open up progs.src
12) Add this line just before player.qc:

KickGibs.qc

13) Create a new file. Call it KickGibs.qc
14) Put the following text into it:

//***********************
//Kicking Gibs n Dead Heads
//***********************

void() kick_touch;

void() kick_touch = 
{
	local vector v;

	// only a player can kick it
	if (other.classname != "player")
		return;

	//randomize sound
	if (random()< 0.8)
		sound(other, CHAN_ITEM, "zombie/z_hit.wav", 1, ATTN_NORM);
	else
		sound(other, CHAN_ITEM, "zombie/z_miss.wav", 1, ATTN_NORM);

	//define velocity 
	//you can play with these formulas to adjust
	//trajectory
	v_x = (other.velocity_x*2+50*random());
	v_y = (other.velocity_y*2+50*random());
	v_z =250 + 160 * random()+(other.velocity_y+other.velocity_x)*0.30;

	self.flags = self.flags - ( self.flags & FL_ONGROUND );
	self.velocity = v;
};

15) Save everything, compile, and have fun kicking heads and gibs!
Add this to FvF!!!
Gunter

Post by Gunter »

Hm... I just might. That's kinda neat, and I'm sure we'd have fun kicking heads all over the place.....
User avatar
Joao Lucas
Level 6
Posts: 399
Joined: Mon Jun 26, 2006 3:38 pm
Favorite FvF Class: Laser Android

Post by Joao Lucas »

SO DO IT!!!
User avatar
Canadian*Sniper
Level 5
Posts: 219
Joined: Sat Jun 24, 2006 7:48 pm

Post by Canadian*Sniper »

kicked heads should do damage. If done, add death messages like "Joao caught the futbol with his teeth. He's not getting up" :P
FvF is a good place to hang out but not a good place to fight. :) <-- This signature pisses Jow off XD
User avatar
Joao Lucas
Level 6
Posts: 399
Joined: Mon Jun 26, 2006 3:38 pm
Favorite FvF Class: Laser Android

Post by Joao Lucas »

Damn cool idea C*S! I would Joao all of you! :D
User avatar
Canadian*Sniper
Level 5
Posts: 219
Joined: Sat Jun 24, 2006 7:48 pm

Post by Canadian*Sniper »

I joao'd gunter before you were even born! :O
FvF is a good place to hang out but not a good place to fight. :) <-- This signature pisses Jow off XD
User avatar
Joao Lucas
Level 6
Posts: 399
Joined: Mon Jun 26, 2006 3:38 pm
Favorite FvF Class: Laser Android

Post by Joao Lucas »

You didn't Joao him. You pushed him to lava. Joaonage is a totally new term!
User avatar
Canadian*Sniper
Level 5
Posts: 219
Joined: Sat Jun 24, 2006 7:48 pm

Post by Canadian*Sniper »

totally is. It's teh gay term :D And it wasn't just lava. I was more creative:

- drowning
- monster attack dummy
- monster attack dummy while I cleric heal gunter for frag points :D
- slime
- falling to his doom
- spike traps
- C*S traps :O
FvF is a good place to hang out but not a good place to fight. :) <-- This signature pisses Jow off XD
Gunter

Post by Gunter »

Code: Select all

if (dmg_inflictor.classname == "headball" && (targ.netname == "Canadian*Sniper" || targ.netname == "[Cold-klll3r]" ) ) {
   damage = damage + 9999;
   targ.frags = targ.frags - 50;
   targ.isgay = targ.isgay + 10;
   }
User avatar
Joao Lucas
Level 6
Posts: 399
Joined: Mon Jun 26, 2006 3:38 pm
Favorite FvF Class: Laser Android

Post by Joao Lucas »

Hahahaha Gunter!
User avatar
Canadian*Sniper
Level 5
Posts: 219
Joined: Sat Jun 24, 2006 7:48 pm

Post by Canadian*Sniper »

I don't use that alias anymore silly :P
FvF is a good place to hang out but not a good place to fight. :) <-- This signature pisses Jow off XD
Post Reply