Jump to content

Modifying Combat Arts and understanding Flags - spells.txt


Recommended Posts

Posted
10 hours ago, Lindor said:

https://www.sacredwiki.org/index.php/Sacred_2:Tokens

 

45/(1+((500+100*15)/1000))=27.2727272....

So it's not 50% - 1% per CA as per the description, but some balancing equation that rewards higher CA lvl... sorta

Sorry I'm new to modding on this game, I'll bookmark the tokens page.

Thank you :)

 

  • Appreciation 1
Posted (edited)

Another easy method. 1000 is base cooldown.  Before any bonuses, it's 1000/1000 = 1 = 100% coldown.

 

The token adds a bonus to the 2nd number. So if you add this token:

entry6 = {"et_regThisCool", 500, 10, 2, 8 },

to the base cooldown calculation when CA level is 15, you get 1000/1000 + 500 + (15*10). So 1000/1650, which gets you 0.606, or 60.6% of the base cooldown.

Dust devil cooldown: 45 seconds * the cooldown modifier from the above formula is 45*.0606 = 27.27 seconds.

 

The description for the CA mods on the wiki can be misleading. I fixed most of the classes' CAs to reflect actual numbers instead of the token numbers, but as I've yet to play the Dryad and Dragon Mage extensively, haven't yet gotten to that. Might do it later this week. It just requires checking what token the mods use and some time.

Edited by idbeholdME
  • Thanks! 1
Posted
On 5/16/2024 at 1:19 PM, idbeholdME said:

1000/1000 + 500 + (15*10). So 1000/1650

Forgot some brackets, didn't you?

  • Appreciation 1
  • 3 months later...
Posted (edited)
On 5/15/2024 at 7:14 AM, Lindor said:

https://www.sacredwiki.org/index.php/Sacred_2:Tokens

 

45/(1+((500+100*15)/1000))=27.2727272....

Hello,

entry6 = {"et_regThisCool", 500, 10, 2, 8 },


You accidentally wrote +100*15, its +10*15

 

45/(1+((500+10*15)/1000))=27.2727272....

45/(1+((500+100*15)/1000)=15

Edited by iskoeby
  • Appreciation 1
Posted

Hello,

et_physical_to_poison 1-1/(1+(x+y*calvl)/10) percent of physical damage converted to poison damage.

What is rpresented of 1-1?  is this a base physical damage figure of a weapon or combat art?

Thank you.

  • Like! 1
Posted
2 hours ago, iskoeby said:

Hello,

et_physical_to_poison 1-1/(1+(x+y*calvl)/10) percent of physical damage converted to poison damage.

What is rpresented of 1-1?  is this a base physical damage figure of a weapon or combat art?

Thank you.

 FIrst I admit I didn't bother to look up where the original came from to understand it, but the math makes sense on its own.

Assuming we're talking about a CA converting phys to poison I would guess x is a base value and y is the increase per level for that mod. Assuming those are positive values "(1+(x+y*calvl)/10)" would be ever growing with ca level.
so "1/(1+(x+y*calvl)/10)" would be ever shrinking. We do however want the conversion to grow therefore we subtract that shrinking portion from 1.

1-[1/(1+(x+y*calvl)/10)]
gives us for x and y =0 an exact 0 as result which means at a mod value of 0 nothing will be converted.
with and infinite mod value on the other hand 1/inf would be ~0 and you would get 1-0=1=100/100=100% as the converted amount.
Therefore I conclude the "percent" in the quoted sentence is a double up(the formula's result already is given in percent).
therwise the formula makes a lot of sense mechanically allowing for values from no conversion all the way to "almost" full conversion.

I hope that cleared it up for you.

Posted (edited)

Hello,

I understand, correct me if its wrong.

Postive scaling = (1+(x+y*calvl)/10)

Negative Scaling = -1(1+(x+y*calvl)/10)

 

Example: given the Combat Art level = 1, and the conversion is positive scaling.

 

entry5 = {"et_physical_to_poison", 500, 2, 2, 5 }

(1+(500+2*1)/10) = 51.2% of physical damage converted to poison damage.

 

If this is true then in what circumstances could negative scaling apply, and could it ever apply for damage conversion or will damage conversion always be a positive scaling?

Thank you.

Edited by iskoeby
Posted
8 hours ago, iskoeby said:

Hello,

entry6 = {"et_regThisCool", 500, 10, 2, 8 },


You accidentally wrote +100*15, its +10*15

 

45/(1+((500+10*15)/1000))=27.2727272....

45/(1+((500+100*15)/1000)=15

Hi, I just saw your first post here,  and saw you've been a member since more than five years. Thanks for sticking around these forums, and now posting to the community... we are delighted you're here with us

This is your free, and happy ...welcome to DarkMatters Iskoeby!

we now return you SLD (and invite others) who can take you further with your answer experience and journey for this (seemingly) never endng game...even 20 years later 

:l_diver:

gogo

Posted
1 hour ago, iskoeby said:

Hello,

I understand, correct me if its wrong.

Postive scaling = (1+(x+y*calvl)/10

Negative Scaling = -1(1+(x+y*calvl)/10

I have no clue where this is going but both your formulas have a missing ")". I guess it was supposed to be at the end.
The second formula creates negative values then (still assuming x and y remain positive). What do you want to accomplish here?
 

 

1 hour ago, iskoeby said:

entry5 = {"et_physical_to_poison", 500, 2, 2, 5 }

(1+(500+2*1)/10 = 51.2% of physical damage converted to poison damage.

 

If this is true

what you wrote there were "true" if you added the missing bracket from above and if "(1+(x+y*calvl)/10)" was actually the correct formula for the conversion and was supposed to give 51.2 as a result for 51.2% conversion.

The formula from your last post was
1-[1/(1+(x+y*calvl)/10)]         which for x=500 and y=2 and calvl=1 would be
1-[1/51.2]=~98%
certainly this result doesn't make much sense here either...

But I still don't know where the formulas are coming from, that you're bouncing around here. I also have no clue where x and y are actually coming from.
Hopefully someone who has read this thread will come along soon and can actually help you.
Both @Lindor and @idbeholdME are still sneaking around here sometimes and I guess they know more about the game modding stuff than I do.

  • Like! 1
Posted (edited)
8 minutes ago, SLD said:

But I still don't know where the formulas are coming from, that you're bouncing around here.

I guess the Sacred 2 Tokens Wiki page.
https://www.sacredwiki.org/index.php/Sacred_2:Tokens

Quote
  • et_physical_to_best: 1-1/(1+(x+y*calvl)/10) percent of physical damage converted to least resisted damage
  • et_physical_to_fire: 1-1/(1+(x+y*calvl)/10) percent of physical damage converted to fire damage
  • et_physical_to_magic: 1-1/(1+(x+y*calvl)/10) percent of physical damage converted to magic damage
  • et_physical_to_poison: 1-1/(1+(x+y*calvl)/10) percent of physical damage converted to poison damage

But I have too no idea what he means with those other formulae. Like what does 1-1 mean? Well it means 0 I guess? Or maybe he's not familiar with the "multiplication and division first, then addition and subtraction" rule?

Edited by Lindor
  • Appreciation 1
Posted
25 minutes ago, Lindor said:

I guess the Sacred 2 Tokens Wiki page.

makes sense.

there I also learned: "The values x and y are used in this list, where x is the second value and y the third from each entry."

So he used those wrong why the formula gave me such odd results...

So

"entry5 = {"et_physical_to_poison", 500, 2, 2, 5 }"

in formula 1-[1/(1+(x+y*calvl)/10)]   for a combat art level one would actually have x=2 and y=2...
and result in 1-[1/1.4]=0.28571428571 =~28.57% conversion which is reasonable

and at calvl 100 that would be 1-[1/21.2]=0.95283018867 =~95.28% conversion which seems a bit "high"

So either the token can have smaller than whole numbers for y or the formula still seems far to imprecise to make a reasonable scaling over 200 calvls possible...
 

38 minutes ago, Lindor said:

ike what does 1-1 mean? Well it means 0 I guess? Or maybe he's not familiar with the "multiplication and division first, then addition and subtraction" rule?

that's why I added extra [brackets] for him. I originally thought it was a brain fart wanting to add something like a damage range (not seeing the - as minus sign in the sense of the formula but basically "1 to 1").
Thanks for answering my call for help :)

  • Appreciation 1
Posted
28 minutes ago, Lindor said:

Well no.

The second entry is 500 and the third entry is 2.

The first entry is “et_physical_to_poison“.

Oh I should have read more lines than :)
Thanks again, you are of course correct.

That however would make the resulting numbers from his "entry5" just far more insane in value.
I guess "hope" blinded me here :)

  • Appreciation 1
Posted (edited)
6 hours ago, Lindor said:

I guess the Sacred 2 Tokens Wiki page.
https://www.sacredwiki.org/index.php/Sacred_2:Tokens

But I have too no idea what he means with those other formulae. Like what does 1-1 mean? Well it means 0 I guess? Or maybe he's not familiar with the "multiplication and division first, then addition and subtraction" rule?

Hello,

 

You're right SLD I forgot to close the brackets.

 

Lindor, allow me to clarify why I asked if "1-1" is represented by something other than it equalling "0".

With refernce to the Sacred 2 Tokens wiki page, the formula for cooldown reduction is written as follows:

et_regThisCool                      1-1/(1+(x+y*calvl)/1000) percent reduced cooldown time.

 

On a previous page you assisted somebody with resolving thier calculation for the cooldown time for Dyrad's "Dust Devil" spell.

entry6 = {"et_regThisCool", 500, 10, 2, 8 },

 

You responded with "45/(1+((500+100*15)/1000))=27.2727272...."

However the formula  according to the wiki starts with a "1-1", your response started with a "45".

That is why I asked if "1-1" was represented of something.

I hope that clarifys my reasoning for asking in the beginning.

 

Thank you.

 

 

 

Edited by iskoeby
Posted (edited)
8 hours ago, iskoeby said:

(1+(500+2*1)/10) = 51.2% of physical damage converted to poison damage.

Hello,

 

I would like to take a second to expand the equation and show how I arrived at 51.2%.

Correct me if I'm wrong.

 

As stated previously CAlvl = 1

(1+(500+2*1)/10)

(1+(500+2)/10)

(1+(502/10)

(1+50.2)

51.2%

 

I would also like to clarify that this specifically relates to the 2nd bronze modification for the combat art "Ravaged Impact", called "Envenmon".

Please find attached 2 images to support my calculation.

df8e8bace987a0abe43bdb4facc23081.thumb.png.e9565fdc122ba5f088a5e44e0499da3e.png

63885cd59386d88b4f916b4d8a615b28.png.acec459fbedc4c0e616d2d7e2688f6f0.png

 

Thank you.

Edited by iskoeby
  • Like! 1
Posted
7 hours ago, iskoeby said:

(1+(500+2*1)/10)

(1+(500+2)/10)

(1+(502/10)

(1+50.2)

51.2%

again, the math checks out except for the last line. That's obviously 51.2 not 51.2% but I get what you meant there.

This would however not result in anywhere near the 50% + 1% per level but rather 51% + 0.2% per level.

What I can't say anything about is wether any of those formulas are representative of what the game actually does.
I can say that the formula from the wiki token page seems really odd because in this instance it would result in 98%+ at calvl 1 and barely change at all with higher levels.

Posted
2 hours ago, SLD said:

This would however not result in anywhere near the 50% + 1% per level but rather 51% + 0.2% per level.

Hello,

I think the 51.2% conversion might be broken down as follows:

Correct me if I'm wrong.

 

Specific to this cirucmstance, I think the 50% of the 51,2% is the base conversion amount at CAlvl 1 and I suspect the remaining 1.2% is the addtional conversion amount per CAlvl.

If this is correct, then I think, of the 1.2% the figure is being rounded down to 1% in the description.

So my question is do you think Sacred 2 might round down figures to the nearest % within thier discriptions? - this is purely speculative of course.

 

Thank you.

 

Posted
12 minutes ago, iskoeby said:

Specific to this cirucmstance, I think the 50% of the 51,2% is the base conversion amount at CAlvl 1 and I suspect the remaining 1.2% is the addtional conversion amount per CAlvl.

Well that is not what your formula says... just calculate it for different calvls and you'll see.
 

13 minutes ago, iskoeby said:

So my question is do you think Sacred 2 might round down figures to the nearest % within thier discriptions? - this is purely speculative of course.

Those mod descriptions aren't calculated at all. They were handwritten. They are also not part of the base game as that usually doesn't list numbers there at all. Not sure what mod you're running but it's creator might be capable of telling you more about how he arrived at those numbers.

Posted
45 minutes ago, SLD said:

Well that is not what your formula says... just calculate it for different calvls and you'll see.

Hello,

You are correct when I factor in CAlvls above 1 it does not scale, something is incorrect.

I also opened the game and added the modification, the result was surprising.

 

 

2.png.16dd9e74478622b618ca44e9065086fc.png

(Unarmed) 28/112 = 0.25, it seems the figures only add up to a conversion of 25% and not the 50% stated in the description.

Visually 25% conversion looks accurate according to the Combat Art bar.

With that being said, how we arrive at 25% is yet to be explained.

 

 

entry5 = {"et_physical_to_poison", 500, 2, 2, 5 }

This means that the "500" represented in this information is meant to = 25%, not 50%, interesting.

 

Thank you.

 

 

Posted

Hello,

Update:

 

I was adjusting the figures in the spells txt.         "entry5 = {"et_physical_to_poison", 500, 2, 2, 5 }"

I changed the "500" to 1000 then 5000 then 50000 and finally to 500000 and failed to achive 100% complete conversion from physical to poison.

I suspect the formula for physical to poison conversion has been factored for diminishing returns in some capacity.

The highest rate of conversion I could achieve was about 60%.

 

Thank you.

Posted
59 minutes ago, iskoeby said:

I was adjusting the figures in the spells txt.         "entry5 = {"et_physical_to_poison", 500, 2, 2, 5 }"

I changed the "500" to 1000 then 5000 then 50000 and finally to 500000 and failed to achive 100% complete conversion from physical to poison.

I suspect the formula for physical to poison conversion has been factored for diminishing returns in some capacity.

The highest rate of conversion I could achieve was about 60%.

That sounds very interesting. How large was your "attribute bonus damage" ? That one would probably not be converted in the inventory screen as it is also not being effected by damage increase mods there. So if for whatever reason 40% of your entire damage was fixed to look physical it would of course appear to max out at 60% conversion.

Posted (edited)
1 hour ago, SLD said:

"attribute bonus damage"

Hello,

 

I'm not certain how to locate the "attribute bonus damage" value, but I will post a couple of screenshots to compare, perhaps your question will be answered there. I will try to include as much information as possible, it might spill into a 2nd post depending on the image sizes.

Please find attached 2 screenshots showing the outcome  when x = 500

A),

2178fdbb9767a41d3904036b9771b8b4.png.d0154fbcd1269403cae09bd774231d02.png

33d3cdb5abd594614606ec57e1d7f1b3.thumb.jpg.7f381583240f497440fc84e99931e4d7.jpg

 

Thank you.

Edited by iskoeby
Posted
13 hours ago, iskoeby said:

I'm not certain how to locate the "attribute bonus damage"

In your pictures you included the middle panel that says "Attributes" at the top. When you hover your mouse over the pictures/symbols up there like for instance the "heart" next to "Vitality" it shows you what the attribute currently does. In the case of vitality it shows an amount of maximum life added by vitality. One of the attributes should show a "weapon damage". In the case of empty fist I guess it's gonna be strength. For ranged weapons it's dexterity for staves its intelligence and in versions past the community patch it will be willpower for lightsabers.
That weapon damage shown there is an average and its actual min and max damage values are added to the tooltip on the left panel without further multipliers. The damage type of that bonus damage is based on the damage type on the original weapon meaning in your test case it will be pure physical and I guess the combat art's conversion can't touch this either which is why no matter the amount of conversion an amount of physical damage always remains in that tooltip. 

Also know that this is all only about the tooltip! It does not accurately reflect the attribute's effect at all!


Alternatively you could for your testing purposes set the value "attrWdam_fact" in "balance.txt" to "0". That should remove the effect the attributes have on damage entirely, which should make the tooltip accurately show the actual conversion values.

Posted

Hello,

 

Very interesting, my unarmed strength bonus at 157 strength = +30 weapon damage.

If I take away that bonus physical damage

130 - 30 = 100

Then the 51 poison damage is almost 51% of that, but that may just be a coincidence. I doubt its anything more than just that. I would have to investigate further.

 

979e970b2cff6951cd57028115bb8b1d.thumb.png.cf560464eb6c8d67fd2c8e0e11dd443f.png

 

e1793619f08b09c23eba65bb91a1fb71.thumb.png.78ee490972c89a9ef25a6d891aedef2f.png

 

Thank you.

  • Like! 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...
Please Sign In or Sign Up