Difference between revisions of "Sacred 2:How is a character's natural Willpower calculated?"

From SacredWiki
Jump to navigation Jump to search
(Created page with "It all starts in '''blueprint.txt'''. There is a bonus called '''crbonus_attr_wil_pc'''. <pre> newBonus = { -- name = "crbonus_attr_wil_pc", rating = 0, basedonskill = "S...")
 
(Add references)
 
Line 78: Line 78:
  
 
The generic formula for blueprint bonuses is:
 
The generic formula for blueprint bonuses is:
<blockquote>ValueOfBonus = FLOOR((FLOOR(((ValueAt200 - ValueAt0) / 200) * CreatureOrItemLevel) + ValueAt0) * Intensity * 0.001)</blockquote>
+
<blockquote>ValueOfBonus = FLOOR((FLOOR((ValueAt200 - ValueAt0) * (1 / 200) * CreatureOrItemLevel) + ValueAt0) * Intensity * 0.001)</blockquote>
  
 
For Willpower (and attributes in general), there are no additional operations to perform:
 
For Willpower (and attributes in general), there are no additional operations to perform:
Line 84: Line 84:
  
 
We can adapt and simplify the formula like so:
 
We can adapt and simplify the formula like so:
<blockquote>Willpower = FLOOR((FLOOR(((ValueAt200 - ValueAt0) / 200) * CharacterLevel) + ValueAt0) * Intensity * 0.001)</blockquote>
+
<blockquote>Willpower = FLOOR((FLOOR((ValueAt200 - ValueAt0) * (1 / 200) * CharacterLevel) + ValueAt0) * Intensity * 0.001)</blockquote>
<blockquote>Willpower = FLOOR((FLOOR(((525 - 23) / 200) * CharacterLevel) + 23) * Intensity * 0.001)</blockquote>
+
<blockquote>Willpower = FLOOR((FLOOR((525 - 23) * (1 / 200) * CharacterLevel) + 23) * Intensity * 0.001)</blockquote>
<blockquote>Willpower = FLOOR((FLOOR((502 / 200) * CharacterLevel) + 23) * Intensity * 0.001)</blockquote>
+
<blockquote>Willpower = FLOOR((FLOOR(502 * (1 / 200) * CharacterLevel) + 23) * Intensity * 0.001)</blockquote>
 
<blockquote>Willpower = FLOOR((FLOOR(2.51 * CharacterLevel) + 23) * Intensity * 0.001)</blockquote>
 
<blockquote>Willpower = FLOOR((FLOOR(2.51 * CharacterLevel) + 23) * Intensity * 0.001)</blockquote>
  
Line 497: Line 497:
 
| 200 || 567 || 420 || 525 || 472 || 556 || 546 || 525
 
| 200 || 567 || 420 || 525 || 472 || 556 || 546 || 525
 
|}
 
|}
 +
 +
 +
 +
== References ==
 +
* https://darkmatters.org/forums/index.php?/topic/18511-how-is-sacred-2-weapon-damage-calculated/&do=findComment&comment=7146103
 +
* https://darkmatters.org/forums/index.php?/topic/18511-how-is-sacred-2-weapon-damage-calculated/&do=findComment&comment=7144874

Latest revision as of 17:57, 26 September 2024

It all starts in blueprint.txt. There is a bonus called crbonus_attr_wil_pc.

newBonus = {
--  name = "crbonus_attr_wil_pc",
  rating = 0,
  basedonskill = "SKILL_INVALID",
  type = "BONUS_STATS",
  spez = "STAT_WIL",
  spez2 = "",
  usagebits = 65535,
  minconstraints = {1,0,0},
  difficultyvaluerange0 = {0,23,525},
  difficultyvaluerange1 = {1,23,525},
  difficultyvaluerange2 = {2,23,525},
  difficultyvaluerange3 = {3,23,525},
  difficultyvaluerange4 = {4,23,525},
}
mgr.createBonus(35, newBonus);

In creatures.txt, each character receives this bonus at a different "intensity" value.

The Dragon Mage:

mgr.addCreatureBonus( 1949, {
	intensity = 1080,
	bonus = 35,
})

The Dryad:

mgr.addCreatureBonus( 94, {
	intensity = 800,
	bonus = 35,
})

The High Elf:

mgr.addCreatureBonus( 209, {
	intensity = 1000,
	bonus = 35,
})

The Inquisitor:

mgr.addCreatureBonus( 51, {
	intensity = 900,
	bonus = 35,
})

The Seraphim:

mgr.addCreatureBonus( 1, {
	intensity = 1060,
	bonus = 35,
})

The Shadow Warrior:

mgr.addCreatureBonus( 93, {
	intensity = 1040,
	bonus = 35,
})

The Temple Guardian:

mgr.addCreatureBonus( 210, {
	intensity = 1000,
	bonus = 35,
})


TODO Guide on how to interpret blueprint bonuses.


The generic formula for blueprint bonuses is:

ValueOfBonus = FLOOR((FLOOR((ValueAt200 - ValueAt0) * (1 / 200) * CreatureOrItemLevel) + ValueAt0) * Intensity * 0.001)

For Willpower (and attributes in general), there are no additional operations to perform:

Willpower = ValueOfBonus

We can adapt and simplify the formula like so:

Willpower = FLOOR((FLOOR((ValueAt200 - ValueAt0) * (1 / 200) * CharacterLevel) + ValueAt0) * Intensity * 0.001)

Willpower = FLOOR((FLOOR((525 - 23) * (1 / 200) * CharacterLevel) + 23) * Intensity * 0.001)

Willpower = FLOOR((FLOOR(502 * (1 / 200) * CharacterLevel) + 23) * Intensity * 0.001)

Willpower = FLOOR((FLOOR(2.51 * CharacterLevel) + 23) * Intensity * 0.001)

By using the formula, we can fill in the following table:

Character level Willpower
Dragon Mage Dryad High Elf Inquisitor Seraphim Shadow Warrior Temple Guardian
1 27 20 25 22 26 26 25
2 30 22 28 25 29 29 28
3 32 24 30 27 31 31 30
4 35 26 33 29 34 34 33
5 37 28 35 31 37 36 35
6 41 30 38 34 40 39 38
7 43 32 40 36 42 41 40
8 46 34 43 38 45 44 43
9 48 36 45 40 47 46 45
10 51 38 48 43 50 49 48
11 54 40 50 45 53 52 50
12 57 42 53 47 56 55 53
13 59 44 55 49 58 57 55
14 62 46 58 52 61 60 58
15 64 48 60 54 63 62 60
16 68 50 63 56 66 65 63
17 70 52 65 58 68 67 65
18 73 54 68 61 72 70 68
19 75 56 70 63 74 72 70
20 78 58 73 65 77 75 73
21 81 60 75 67 79 78 75
22 84 62 78 70 82 81 78
23 86 64 80 72 84 83 80
24 89 66 83 74 87 86 83
25 91 68 85 76 90 88 85
26 95 70 88 79 93 91 88
27 97 72 90 81 95 93 90
28 100 74 93 83 98 96 93
29 102 76 95 85 100 98 95
30 105 78 98 88 103 101 98
31 108 80 100 90 106 104 100
32 111 82 103 92 109 107 103
33 113 84 105 94 111 109 105
34 116 86 108 97 114 112 108
35 118 88 110 99 116 114 110
36 122 90 113 101 119 117 113
37 124 92 115 103 121 119 115
38 127 94 118 106 125 122 118
39 129 96 120 108 127 124 120
40 132 98 123 110 130 127 123
41 135 100 125 112 132 130 125
42 138 102 128 115 135 133 128
43 140 104 130 117 137 135 130
44 143 106 133 119 140 138 133
45 145 108 135 121 143 140 135
46 149 110 138 124 146 143 138
47 151 112 140 126 148 145 140
48 154 114 143 128 151 148 143
49 156 116 145 130 153 150 145
50 159 118 148 133 156 153 148
51 163 120 151 135 160 157 151
52 165 122 153 137 162 159 153
53 168 124 156 140 165 162 156
54 170 126 158 142 167 164 158
55 173 128 161 144 170 167 161
56 176 130 163 146 172 169 163
57 179 132 166 149 175 172 166
58 181 134 168 151 178 174 168
59 184 136 171 153 181 177 171
60 186 138 173 155 183 179 173
61 190 140 176 158 186 183 176
62 192 142 178 160 188 185 178
63 195 144 181 162 191 188 181
64 197 146 183 164 193 190 183
65 200 148 186 167 197 193 186
66 203 150 188 169 199 195 188
67 206 152 191 171 202 198 191
68 208 154 193 173 204 200 193
69 211 156 196 176 207 203 196
70 213 158 198 178 209 205 198
71 217 160 201 180 213 209 201
72 219 162 203 182 215 211 203
73 222 164 206 185 218 214 206
74 224 166 208 187 220 216 208
75 227 168 211 189 223 219 211
76 230 170 213 191 225 221 213
77 233 172 216 194 228 224 216
78 235 174 218 196 231 226 218
79 238 176 221 198 234 229 221
80 240 178 223 200 236 231 223
81 244 180 226 203 239 235 226
82 246 182 228 205 241 237 228
83 249 184 231 207 244 240 231
84 251 186 233 209 246 242 233
85 254 188 236 212 250 245 236
86 257 190 238 214 252 247 238
87 260 192 241 216 255 250 241
88 262 194 243 218 257 252 243
89 265 196 246 221 260 255 246
90 267 198 248 223 262 257 248
91 271 200 251 225 266 261 251
92 273 202 253 227 268 263 253
93 276 204 256 230 271 266 256
94 278 206 258 232 273 268 258
95 281 208 261 234 276 271 261
96 284 210 263 236 278 273 263
97 287 212 266 239 281 276 266
98 289 214 268 241 284 278 268
99 292 216 271 243 287 281 271
100 295 219 274 246 290 284 274
101 298 220 276 248 292 287 276
102 301 223 279 251 295 290 279
103 303 224 281 252 297 292 281
104 306 227 284 255 301 295 284
105 308 228 286 257 303 297 286
106 312 231 289 260 306 300 289
107 314 232 291 261 308 302 291
108 317 235 294 264 311 305 294
109 319 236 296 266 313 307 296
110 322 239 299 269 316 310 299
111 325 240 301 270 319 313 301
112 328 243 304 273 322 316 304
113 330 244 306 275 324 318 306
114 333 247 309 278 327 321 309
115 335 248 311 279 329 323 311
116 339 251 314 282 332 326 314
117 341 252 316 284 334 328 316
118 344 255 319 287 338 331 319
119 346 256 321 288 340 333 321
120 349 259 324 291 343 336 324
121 352 260 326 293 345 339 326
122 355 263 329 296 348 342 329
123 357 264 331 297 350 344 331
124 360 267 334 300 354 347 334
125 362 268 336 302 356 349 336
126 366 271 339 305 359 352 339
127 368 272 341 306 361 354 341
128 371 275 344 309 364 357 344
129 373 276 346 311 366 359 346
130 376 279 349 314 369 362 349
131 379 280 351 315 372 365 351
132 382 283 354 318 375 368 354
133 384 284 356 320 377 370 356
134 387 287 359 323 380 373 359
135 389 288 361 324 382 375 361
136 393 291 364 327 385 378 364
137 395 292 366 329 387 380 366
138 398 295 369 332 391 383 369
139 400 296 371 333 393 385 371
140 403 299 374 336 396 388 374
141 406 300 376 338 398 391 376
142 409 303 379 341 401 394 379
143 411 304 381 342 403 396 381
144 414 307 384 345 407 399 384
145 416 308 386 347 409 401 386
146 420 311 389 350 412 404 389
147 422 312 391 351 414 406 391
148 425 315 394 354 417 409 394
149 427 316 396 356 419 411 396
150 430 319 399 359 422 414 399
151 434 321 402 361 426 418 402
152 436 323 404 363 428 420 404
153 439 325 407 366 431 423 407
154 441 327 409 368 433 425 409
155 444 329 412 370 436 428 412
156 447 331 414 372 438 430 414
157 450 333 417 375 442 433 417
158 452 335 419 377 444 435 419
159 455 337 422 379 447 438 422
160 457 339 424 381 449 440 424
161 461 341 427 384 452 444 427
162 463 343 429 386 454 446 429
163 466 345 432 388 457 449 432
164 468 347 434 390 460 451 434
165 471 349 437 393 463 454 437
166 474 351 439 395 465 456 439
167 477 353 442 397 468 459 442
168 479 355 444 399 470 461 444
169 482 357 447 402 473 464 447
170 484 359 449 404 475 466 449
171 488 361 452 406 479 470 452
172 490 363 454 408 481 472 454
173 493 365 457 411 484 475 457
174 495 367 459 413 486 477 459
175 498 369 462 415 489 480 462
176 501 371 464 417 491 482 464
177 504 373 467 420 495 485 467
178 506 375 469 422 497 487 469
179 509 377 472 424 500 490 472
180 511 379 474 426 502 492 474
181 515 381 477 429 505 496 477
182 517 383 479 431 507 498 479
183 520 385 482 433 510 501 482
184 522 387 484 435 513 503 484
185 525 389 487 438 516 506 487
186 528 391 489 440 518 508 489
187 531 393 492 442 521 511 492
188 533 395 494 444 523 513 494
189 536 397 497 447 526 516 497
190 538 399 499 449 528 518 499
191 542 401 502 451 532 522 502
192 544 403 504 453 534 524 504
193 547 405 507 456 537 527 507
194 549 407 509 458 539 529 509
195 552 409 512 460 542 532 512
196 555 411 514 462 544 534 514
197 558 413 517 465 548 537 517
198 560 415 519 467 550 539 519
199 563 417 522 469 553 542 522
200 567 420 525 472 556 546 525


References