AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Suggestions / Requests (https://forums.alliedmods.net/forumdisplay.php?f=12)
-   -   Solved Kill Log that shows on console for CS 1.6 (https://forums.alliedmods.net/showthread.php?t=313028)

NOTORIOUS7302 12-25-2018 16:37

Kill Log that shows on console for CS 1.6
 
I just want my server to look special so I just want someone to make a kill log similar to the one shown in this video: https://www.youtube.com/watch?v=vn6d9mtc14U

iceeedr 12-26-2018 09:17

Re: Kill Log that shows on console for CS 1.6
 
PHP Code:

public client_death(killer,victim,wpnindex,hitplace,TK)
{
    new 
KillName[32], VicName[32]
    
get_user_name(killer,KillName,charsmax(KillName))
    
get_user_name(victim,VicName,charsmax(VicName))
    
    
client_print(0,print_chat,"%s killed %s with %s!",KillNameVicNamewpnindex)



NOTORIOUS7302 12-26-2018 16:38

Re: Kill Log that shows on console for CS 1.6
 
So I just paste that to console or what?

iceeedr 12-26-2018 18:34

Re: Kill Log that shows on console for CS 1.6
 
Sorry, I just posted the function, it's there, just compile.

PHP Code:

#include <amxmodx>

public plugin_init()
{
    
register_plugin("Killer's name""0.1""alliedmodders")
}

public 
client_death(killer,victim,wpnindex,hitplace,TK)
{
    new 
KillName[32], VicName[32]
    
get_user_name(killer,KillName,charsmax(KillName))
    
get_user_name(victim,VicName,charsmax(VicName))

    
client_print(0,print_chat,"%s killed %s with %s!",KillNameVicNamewpnindex)



NOTORIOUS7302 12-27-2018 16:27

Re: Kill Log that shows on console for CS 1.6
 
So that's .sma I guess? Also, it doesn't work because on wpnindex, it only says !

NOTORIOUS7302 09-03-2019 19:27

Re: Kill Log that shows on console for CS 1.6
 
Quote:

Originally Posted by iceeedr (Post 2631162)
Sorry, I just posted the function, it's there, just compile.

PHP Code:

#include <amxmodx>

public plugin_init()
{
    
register_plugin("Killer's name""0.1""alliedmodders")
}

public 
client_death(killer,victim,wpnindex,hitplace,TK)
{
    new 
KillName[32], VicName[32]
    
get_user_name(killer,KillName,charsmax(KillName))
    
get_user_name(victim,VicName,charsmax(VicName))

    
client_print(0,print_chat,"%s killed %s with %s!",KillNameVicNamewpnindex)




Unfortunately, this hasn't been answered in almost a year. The problem is that it says that the "killer" killed "victim" but doesn't show the name or model of the weapon that was used.

NOTORIOUS7302 09-03-2019 19:33

Re: Kill Log that shows on console for CS 1.6
 
Proof

https://prnt.sc/p1gaa1

AmXDusT 09-03-2019 19:35

Re: Kill Log that shows on console for CS 1.6
 
PHP Code:

#include <amxmodx> 

public plugin_init() 

    
register_plugin("Killer's name""0.1""alliedmodders"
    
register_event("DeathMsg""ev_DeathMsg""a""2>0")


public 
ev_DeathMsg() 

    new 
killer read_data(1)
    new 
victim read_data(2)
    if(
killer == victim || !killer || !victim) return
    new 
weaponName[15]
    
read_data(4weaponNamecharsmax(weaponName))
    new 
KillName[32], VicName[32]
    
get_user_name(killer,KillName,charsmax(KillName)) 
    
get_user_name(victim,VicName,charsmax(VicName)) 
    
client_print(0,print_chat,"%s killed %s with %s!",KillNameVicNameweaponName



NOTORIOUS7302 09-05-2019 21:03

Re: Kill Log that shows on console for CS 1.6
 
Quote:

Originally Posted by AmXDusT (Post 2665769)
PHP Code:

#include <amxmodx> 

public plugin_init() 

    
register_plugin("Killer's name""0.1""alliedmodders"
    
register_event("DeathMsg""ev_DeathMsg""a""2>0")


public 
ev_DeathMsg() 

    new 
killer read_data(1)
    new 
victim read_data(2)
    if(
killer == victim || !killer || !victim) return
    new 
weaponName[15]
    
read_data(4weaponNamecharsmax(weaponName))
    new 
KillName[32], VicName[32]
    
get_user_name(killer,KillName,charsmax(KillName)) 
    
get_user_name(victim,VicName,charsmax(VicName)) 
    
client_print(0,print_chat,"%s killed %s with %s!",KillNameVicNameweaponName



thanks I'll see if it works!

NOTORIOUS7302 09-05-2019 21:09

Re: Kill Log that shows on console for CS 1.6
 
Thank you! The Kill Log works perfectly!


All times are GMT -4. The time now is 18:55.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.