July 27, 201312 yr Is there any way to make it so it stops clicking the NPC while it's already attacking it? I know I could just make it sleep for a while after it attacks.. but you could obviously kill it in different amounts of time every time, and I know there are better ways. So, I've tried to make it so if it will only click attack if I'm not animating (attack animation), but after every hit it just attacks it again, and the problem with that is there are several NPCs of that type and it attacks a different one each time. So is there something like: if (!client.getMyPlayer().isAttacking) { ? It would be really useful.. thanks EDIT: I don't think isUnderAttack() would work because it's ranging something from a safespot. I'll try though. Edited July 27, 201312 yr by DJay
July 27, 201312 yr Author What kind of script are you making Just something that ranges monsters from a safespot. It will be free for everyone.
July 27, 201312 yr I believe you'd use !this.client.getMyPlayer().isUnderAttack() as a condition for initiating combat.
July 27, 201312 yr something like this NPC chicken = closestAttackableNPCForName("Chicken"); if (myPlayer().isUnderAttack() && myPlayer().isAnimating() && myPlayer().isFacing(chicken)) { sleep(200); } else { chicken.interact("Attack"); sleep(random(700, 900)); }