SetMaxHP(Target, (GetMaxHP(Target) + 50))
Moderator: Team Members
Forum rules
READ THE STICKY ON PROPER BUG SUBMISSION FORMAT BEFORE POSTING.
READ THE STICKY ON PROPER BUG SUBMISSION FORMAT BEFORE POSTING.
- Gangrenous
- Posts: 812
- Joined: Sun Apr 24, 2016 6:54 am
- Characters: Dinsmoor
Re: SetMaxHP(Target, (GetMaxHP(Target) + 50))
Well damn why is my duration going crazy.
Resident Dirty Hippy
- Gangrenous
- Posts: 812
- Joined: Sun Apr 24, 2016 6:54 am
- Characters: Dinsmoor
Re: SetMaxHP(Target, (GetMaxHP(Target) + 50))
Could you explain this fix a little better for me, the more I know then the more I can help other people in the future.
Code: Select all
bonus->tier = spell ? spell->spell->GetSpellTier() : 0;Resident Dirty Hippy
-
Jabantiz
- Lead Developer
- Posts: 2912
- Joined: Wed Jul 25, 2007 2:52 pm
- Location: California
Re: SetMaxHP(Target, (GetMaxHP(Target) + 50))
SetMaxHP used add spell bonus with no spell, however the code assumed spell was always valid and therefor when it hit the line spell->spell->GetSpellTier() it crashed as spell was null, the line of code you posted is the exact same thing as
it is just nice and neat on a single line instead of 4 lines of code.
Code: Select all
if (spell)
bonus->tier = spell->spell->GetSpellTier();
else
bonus->tier = 0;
-
Jabantiz
- Lead Developer
- Posts: 2912
- Joined: Wed Jul 25, 2007 2:52 pm
- Location: California
Re: SetMaxHP(Target, (GetMaxHP(Target) + 50))
I tried to tackle the buff issue mentioned in this thread again and it seems to have revealed a deeper issue with timed buffs, if left alone they seems to work fine but if a buff is reapplied early it seems to break that buff where the icon will never disappear from the spell effects window but it only lasts in the maintained window for about half a sec then vanishes taking the actual spell effect with it.
So this is going to take longer to find and fix then I originally thought, just wanted to give an update to let you know I am still working on it when I get the time.
So this is going to take longer to find and fix then I originally thought, just wanted to give an update to let you know I am still working on it when I get the time.
- Gangrenous
- Posts: 812
- Joined: Sun Apr 24, 2016 6:54 am
- Characters: Dinsmoor
Re: SetMaxHP(Target, (GetMaxHP(Target) + 50))
Oh now worry, and I did figure out the problem I mentioned before on the buffs have random timers. If I do not put the buff duration in BuffDuration and BuffDuration2 it does act randomly. If I put the value in both the problem appears okay. I am in no super rush, there are so many things that have to be done I can skip certain aspects and move on to other things.
Resident Dirty Hippy
- Cynnar
- Project Leader
- Posts: 738
- Joined: Sat Sep 27, 2014 1:22 am
- EQ2Emu Server: Eq2emulator
- Characters: Vlash
Veinlash
Taragak
Cynnar
Re: SetMaxHP(Target, (GetMaxHP(Target) + 50))
Moving to archives this week.
[ 01000011 01111001 01101110 01101110 01100001 01110010 ]
Follow on:
Twitter Facebook
Contact me:
PM Discord chat email
Hardware: the parts of a computer that can be kicked
Follow on:
Twitter Facebook
Contact me:
PM Discord chat email
Hardware: the parts of a computer that can be kicked
Who is online
Users browsing this forum: No registered users and 0 guests