View Single Post
  #10  
Old 03-31-2007, 09:42 PM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
Quote:
Originally Posted by Chompy View Post
Someone (Well, a couple) told me to change my styling so...

PHP Code:
public function Hurt(damageattackerhurtani) {
  
temp.conditionsok = ((this.clientr.hp && this.clientr.dead == false && level.nopk == false && this.client.nopk == false) ? true false);
  if (
temp.conditionsok) {

    if (
temp.damage => this.clientr.hp) {
      
this.clientr.hp 0;
      
this.Kill(temp.attacker); 
      
this.showHp(7);
      return 
NULL;
    }
    if (
temp.hurtani)
      
this.setani("hurt"NULL);

    
this.clientr.lastattacker temp.attacker;
    
this.clientr.hp -= abs(temp.damage);
    
this.showHp(7);
    return 
NULL;
  }

(Based of RW's script)
I've never seen of return NULL. Any different from return false;?

--

There's more to scripting than you reading it. It needs to be legible for others too.
__________________
Reply With Quote