Make custom kills & deaths count towards rank stats.
Let's say I've turned the flashbang into an instant kill grenade.
How can I make the kills and deaths caused by this nade count towards the stats in amx rank? I've tried: PHP Code:
|
Re: Make custom kills & deaths count towards rank stats.
You must block DeathMsg after user_kill, and then send your death msg.
|
Re: Make custom kills & deaths count towards rank stats.
user_silentkill() blocks deathmsg.
About stats... try using ham: ExecuteHamB(Ham_Killed, victim, attacker, gib) to fake the kill. "gib" you can set to 1 if you want the victim to explode in gibs, if not, just set 0. |
Re: Make custom kills & deaths count towards rank stats.
Quote:
Is there anyway to do that? |
Re: Make custom kills & deaths count towards rank stats.
You could just look at csx module's source and see what it's reading to count kills.
|
Re: Make custom kills & deaths count towards rank stats.
I found this:
https://forums.alliedmods.net/showthread.php?t=47286 So it looks like it's a bug that was never fixed. Quote:
|
Re: Make custom kills & deaths count towards rank stats.
Show more code, where you deal damage for example.
|
Re: Make custom kills & deaths count towards rank stats.
Quote:
The kills and deaths are just not being counted. And now I've got a new idea... To kill a player with a flashbang, I'm gonna set the users health to 1hp and then spawn a hegrenade on the player and detonate it. Hopefully CSX will pick that up as a grenade death and count the kills/deaths. Think it will work? |
Re: Make custom kills & deaths count towards rank stats.
Send Ham_TakeDamage with nade entity index as inflictor, attacker index as attacker, (1<<24) as damagebit.
I think that's the only thing you have to do, DeathMsg, Damage events gonna be sent by the game. |
Re: Make custom kills & deaths count towards rank stats.
Quote:
PHP Code:
|
| All times are GMT -4. The time now is 04:28. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.