[HELP] hello pls help in my code addflag

07/21/2011 01:06 djneo31#1
Hello friends, i use old trinity source, i have this 2 codes to addflags.

public void AddFlag(ulong flag)
{
if (!ContainsFlag(Network.GamePackets.Update.Flags.De ad) && !ContainsFlag(Network.GamePackets.Update.Flags.Gho st))
StatusFlag |= flag;
}


public void AddFlag2(ulong flag)
{
// if (!ContainsFlag(Network.GamePackets.Update.Flags.De ad) && !ContainsFlag(Network.GamePackets.Update.Flags.Gho st))
StatusFlag2 |= flag;
}

some flags, addflag2 only work with, but I'm having some problems.
first-> when I add the flag topmonk other flag that is in the char is invisible to me.

second-> when I use the skill soulshackle, to revive the button disappears and never comes back, I wonder why and where the error might be there. ok
thanks all! :D :handsdown: :handsdown:
07/21/2011 02:58 pro4never#2
Addflag2 is wrong at first glance. You commented out the checks and never check if flag2 exists.

Should be something more like...

public void AddFlag2(ulong flag)
{
if (!ContainsFlag2(flag))
StatusFlag2 |= flag;
}


Then obviously you need to use flag2's with the add/removeflag2 and flag2 with the add/removeflag codes as they write to different offsets.


Soulshackle sounds like you are never removing the effect properly or you are clearing the dead/ghost effect. When you remove the shackle effect make sure they are still flagged as dead/ghost so the revive button shows.
07/21/2011 04:18 djneo31#3
Quote:
Originally Posted by pro4never View Post
Addflag2 is wrong at first glance. You commented out the checks and never check if flag2 exists.

Should be something more like...

public void AddFlag2(ulong flag)
{
if (!ContainsFlag2(flag))
StatusFlag2 |= flag;
}


Then obviously you need to use flag2's with the add/removeflag2 and flag2 with the add/removeflag codes as they write to different offsets.


Soulshackle sounds like you are never removing the effect properly or you are clearing the dead/ghost effect. When you remove the shackle effect make sure they are still flagged as dead/ghost so the revive button shows.
Thank you for your attention, you're right, the problem I'm having here is that when added Flag2 flag1 seems to be replacing, but only on my screen when I'm in another character I can see the two flags. I used the option you give me but still did not work. :D :D :handsdown: