Page 1 of 3

Enhancing Sword Latent Effects and Enspell day/weather bonus

Posted: Sat Dec 07, 2013 1:08 pm
by maxtherabbit
ok I've added the ensword latents, the sql records are in a separate file because my tortoisesvn was shitting the bed trying to make a patch of the item_latents.sql

I've also removed the +5 damage ensword bonus from the magic.lua and moved it into the CalculateEnspellDamage function inside battleutils

this way it will effect both tier 1 and 2 enspells like its meant to (+5 dmg bonus added after normal damage calc)

ALSO added day(10%) and weather (10%/25%) bonuses to the same function

bonus info sourced: http://wiki.ffxiclopedia.org/wiki/Red_M ... lculations

someone please test my battleutils ! I don't have a compiler installed lol

ETA a couple of changes - after some extensive testing I determined that the current calculations for enhancing skill were doubling up on enhancing gear bonuses (i.e. it was calling GetSkill() from the battleentity class which already takes into account the gear bonuses AND adding the enhancing modifier to it again. this resulted in every piece of gear that adds +15 enhancing skill actually adding +30 for purposes of damage calculation. both the calcs for the enspell2 in the battleutils and the enspell1 in the magic.lua were making this error)

also, in the battleutils the calcs for enspell2 are using integer division, which always results in the remainder being discarded, whereas in the magic.lua, the remainders were being rounded up or down accordingly. I'm not 100% sure what retail behavior is for rounding, but I'm assuming it always discards the remainder, as other calcs in DS seem to indicate this. so, in any case, I've changed the magic.lua to add math.floor() to the calcs to make them consistent with the battleutils.

If retail does in fact use rounding, I will change the lua back and adjust the cpp, but I think it's better that they are consistent.

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Sat Dec 07, 2013 8:49 pm
by kjLotus
tortoiseSVN wont let me apply the patches, can you make them one patch from the root directory? (right click onetimexi folder -> create patch)

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Sat Dec 07, 2013 9:30 pm
by maxtherabbit
here's the unified patch

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Sun Dec 08, 2013 4:37 pm
by maxtherabbit
ok apparently someone had already added the ensword latents so now they're in there twice >.<

duuur - they had always been in there since I started playing, but they weren't working until r4110 because status effect latent wasn't implemented and I just hadn't tested my ensword since then or been paying enough attention to changelog OOPS :roll:

took the dupes back out

also fixed the non-working weekday bonus, everything else is working great

btw I think the JA melee delay needs to be increased to 2sec, the 1sec still doesn't feel like retail, b/c you're still swinging as soon as the ja animation is done

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Sun Dec 08, 2013 8:27 pm
by kjLotus
maxtherabbit wrote:btw I think the JA melee delay needs to be increased to 2sec, the 1sec still doesn't feel like retail, b/c you're still swinging as soon as the ja animation is done
maybe, i think i'll test it on retail while levelling drg

edit: and maybe i'll put a pkey on item_latents so we don't get duplicates :D

edit2: putting in a pkey made me find another item that had duplicates! hurray!

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Tue Dec 10, 2013 8:07 pm
by maxtherabbit
today added opposing day/weather penalties and target resistance adjustment to enspell damage

also made it subject to dmgtaken, magicdmgtaken, and phalanx

still need to randomise the day/weather penalties/bonuses and add the elemental obi

also added the Sirocco Kukri additional effect (damage ranging from 0-10, subject to elemental resists, dmgtaken, magicdmgtaken, phalanx, and SS)

also need to add day/weather for that, maybe create a function for the day/weather stuff...

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Tue Dec 10, 2013 9:28 pm
by kjLotus
maxtherabbit wrote:maybe create a function for the day/weather stuff...
don't bother, there already is functions for all of that in the scripts, which is where additional effects are going to end up eventually

just doing enspells as a temp thing for now

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Tue Dec 10, 2013 9:32 pm
by maxtherabbit
don't additional effects that are calculated per swing have to be in the core?

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Tue Dec 10, 2013 10:05 pm
by kjLotus
maxtherabbit wrote:don't additional effects that are calculated per swing have to be in the core?
nope, they just are right now because that's where the original author of them decided to put them

Re: Enhancing Sword Latent Effects and Enspell day/weather b

Posted: Tue Dec 10, 2013 10:08 pm
by maxtherabbit
damn oh well, so much for that lol

not a total waste of time I guess, at least they are workin better than they were before

can you commit my latest plz?