and so far it works fine the health/mesh/spawning player/We
but the only problem i had is spawning the transformed char to other players if i had a player that is already in range the transforming packet is being sent to that player and he will be able to see the effect.
but lets say another player has logged in.
it dosent matter if the new player was in range or not cus he want be able to see the effect on the transformed player any way.
the reason is I dont have the effect value to add it to the spawnentity Packet .
when i spawn the transformed char i dont need the value cus im doing it depending on the packet that is being sent to the Player+the in range players .and that packet contains the transforming mesh + the transforming time but no values .
so how can i fix that or how can i figure the effects values out of the client so i can add it to the spawnEntity Packet .
IE.This is the spawnEffect Packet that im using .
lets take the Stigged Status its = 0x0;Quote:
public static byte[] SpawnEffect(uint UID, CharStatusStruct.Status Type, ulong Value, Character C)
{
ulong Status = C.Effects;
byte[] Packet = new byte[8 + 36];
COPacket P = new COPacket(Packet);
P.WriteUshortAddPos2((ushort)(Packet.Length - 8));
P.WriteUshortAddPos2((ushort)10017);
P.WriteUintAddPos4(UID);
P.WriteUintAddPos4(0x01);
P.WriteUintAddPos4((uint)Type);
if (!C.Shadow)
{
if (C.RedName)
Status += 0x4000;
if (C.BlackName)
Status += 0x8000;
if (C.Hostile)
Status += 0x1;
if (C.Poisoned)
Status += 0x2;
if (C.TeamLeader)
Status += 0x40;
if (C.Accuracy)
Status += 0x80;
if (C.Stigged)
Status += 0x0;
if (C.Invisible)
Status += 0x400000;
if (C.Shield)
Status += 0x100;
if (C.Flying)
Status += 0x8000000;
if (C.Praying)
Status += 0x80000000;
if (C.CastingPray)
Status += 0x40000000;
if (C.Vortex)
Status += 70368744177664;
if (C.FatalStrike)
Status += 140737488355328;
if (C.RidingHours)
Status += 1125899906842624;
if (C.CurseStart)
Status += 0x100000000;
if (C.SuperMan)
Status += 0x40000;
if (C.Cyclone)
Status += 0x800000;
if (C.XPSkillList)
Status += 0x10;
}
else
{
if (C.Shadow)
Status += 0x420;
if (C.RedName)
Status += 0x4000;
if (C.BlackName)
Status += 0x8000;
}
P.WriteUlongAddPos8((ulong)Status);
P.WriteUlongAddPos8(0);
P.WriteUintAddPos4(0);
return P.AddTQServer8Byte();
}
but that value well spawn the player as Stigged with a level 4 stigma skill even if he was been stigged with a level 1 stigma skill which is wrong
so i really need to figure that out an i need some help
thanks everyone .