I do feel that I should know this but missed out on something
I'm using conquer client v5065, this is redux source
The original code for Redux source will have magic monsters (messengers, AZ spawns, snake king, fiend bats etc) and guards using physical attacks and magic spells/skills are non-existent in the AI.
I went to look at Monster.cs and made my attempt under the
case MonsterMode.Attack
then under
else if (Common.Clock - LastAttack > BaseMonster.AttackSpeed)
I have changed to this code
Problem is whenever the monster using magic spell/skill reduces their target's HP to 0, it's still not considered dead. As a player you're not dead. When the guard kills a monster that monster HP is 0 but not dead it sits there idle with 0 HP and doesn't respawn.
Anyone know what to do?
I'm using conquer client v5065, this is redux source
The original code for Redux source will have magic monsters (messengers, AZ spawns, snake king, fiend bats etc) and guards using physical attacks and magic spells/skills are non-existent in the AI.
I went to look at Monster.cs and made my attempt under the
case MonsterMode.Attack
then under
else if (Common.Clock - LastAttack > BaseMonster.AttackSpeed)
I have changed to this code
Code:
if (BaseMonster.SkillType == 8036 && (target is Player) && !target.HasEffect(ClientEffect.BlueName))
{
Mode = MonsterMode.Idle;
}
else if(BaseMonster.SkillType > 0)
{
LastAttack = Common.Clock;
var skill = Database.ServerDatabase.Context.MagicType.GetById(BaseMonster.SkillType);
uint dmg = CalculateSkillDamage(target, skill, skill.Percent < 100);
var packet = SkillEffectPacket.Create(UID, target.UID, BaseMonster.SkillType, 0);
packet.AddTarget(target.UID, dmg);
SendToScreen(packet);
var pack = InteractPacket.Create(UID, target.UID, target.X, target.Y, InteractAction.MagicAttack, 0);
pack.MagicType = BaseMonster.SkillType;
pack.MagicLevel = 0;
pack.Target = target.UID;
CombatEngine.ProcessInteractionPacket(pack);
if (dmg > 0)
{
target.ReceiveDamage(dmg, UID);
}
}
else
{
LastAttack = Common.Clock;
CombatEngine.ProcessInteractionPacket(InteractPacket.Create(UID, TargetID, target.X, target.Y, InteractAction.Attack, 0));
}
Anyone know what to do?