I think this should work...
if b.isStateAffected(59) b.addState(61); a.mat*1.33-b.mdf*0.33
if b.isStateAffected(59) b.addState(61); a.mat*1.33-b.mdf*0.33
edit: Okay, now I got it to work. Thanks. :)
if(a.actorId() == 1){a.atk * 4 + 560 - b.def * 2;} else if( a.isEnemy()){a.atk * 4 - b.def * 2 ;}