This has full timing, (You don't cast instantly, you wait about .2 seconds per step)
It calculates the hit from a real bonus.
You cannot keep somebody frozen forever. (Impossible to refreeze somebody while in frozen, if they are frozen for 20 seconds then you have to wait 22 seconds to refreeze. (Still damages)
This is just a sample, I will release full 100% both ancients and normal magic
.
Post if anything is missing, thanks.
Open up client.java
First, declare these methods,
Code:
public int IceBarrageC = playerLevel[6] * playerBonus[4] / 400;
public int IceBarrage(){
if (IceBarrageC > 30){
IceBarrageC = 30;}
return misc.random(IceBarrageC);}
Under boolean process(), add:
Code:
if(IceTimer > 0){
IceTimer -= 1;}
Replace your Ice Barrage spell with this:
Code:
if(spellID == 12891) // ice barrage (lvl 94 spell)
{
int timerb = misc.random(40);
int hitD = 0;
if(IceTimer < 1){
castOnPlayer.LogoutDelay = timerb;
IceTimer = timerb += 4;
castOnPlayer.sendMessage("You have been frozen!");
sendMessage("You freeze the enemy!"); }
try{
if(playerLevel[6] > 93)
{
Thread.sleep(200L);
startAnimation(1979);
Thread.sleep(200L);
hitD = IceBarrage();
attackPlayersWithin(369, hitD, 4);
castOnPlayer.inCombat();
inCombat();
PkingDelay = 15;
teleportToX = absX;
teleportToY = absY;
}
else if(playerLevel[6] <= 93)
{
sendMessage("You need a magic level of 94 to cast this spell.");
}
}catch(InterruptedException){}
}
Post any errors (shouldn't get any, I am 99% sure I used all the methods that are in the common servers.)'
EDIT: changed the way that the damage shows up, should be more accurate.
Enjoy