View Single Post
didoWEE
Senior Member
Join Date: Oct 2012
Location: Bulgaria
Old 04-20-2016 , 08:53   Re: Pro Become V.I.P. [re1.0.2]
Reply With Quote #8

Quote:
Originally Posted by crnova View Post
Why not? less lines, but same functionality
Functionality is not the same!

My way
PHP Code:
    if(!is_user_connected(killer))
        return 
HAM_IGNORED// if true - function stops --> 1 if
    
if(killer == victim)
        return 
HAM_IGNORED// if true - function stops --> 2 ifs
    
if(!is_real_player(killer))
        return 
HAM_IGNORED// if true - function stops --> 3 ifs
    
if(g_bFlagged[killer])
        return 
HAM_IGNORED// if true - function stops --> 4 ifs 
Your way
PHP Code:
if(!is_user_connected(killer) || killer == victim || !is_real_player(killer) || g_bFlagged[killer])
      return 
HAM_IGNORED// if true - function stops -> Always 4 ifs 
I am not sure about client_infochanged()
I have to check


Stop spamming my thread, please!
didoWEE is offline