Sacred 2:How is a character's natural Dexterity calculated?

From SacredWiki
Revision as of 17:51, 26 September 2024 by Maneus (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

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

newBonus = {
--  name = "crbonus_attr_dex_pc",
  rating = 0,
  basedonskill = "SKILL_INVALID",
  type = "BONUS_STATS",
  spez = "STAT_DEX",
  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(31, newBonus);

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

The Dragon Mage:

mgr.addCreatureBonus( 1949, {
	intensity = 840,
	bonus = 31,
})

The Dryad:

mgr.addCreatureBonus( 94, {
	intensity = 1200,
	bonus = 31,
})

The High Elf:

mgr.addCreatureBonus( 209, {
	intensity = 800,
	bonus = 31,
})

The Inquisitor:

mgr.addCreatureBonus( 51, {
	intensity = 1100,
	bonus = 31,
})

The Seraphim:

mgr.addCreatureBonus( 1, {
	intensity = 1040,
	bonus = 31,
})

The Shadow Warrior:

mgr.addCreatureBonus( 93, {
	intensity = 840,
	bonus = 31,
})

The Temple Guardian:

mgr.addCreatureBonus( 210, {
	intensity = 960,
	bonus = 31,
})


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 Dexterity (and attributes in general), there are no additional operations to perform:

Dexterity = ValueOfBonus

We can adapt and simplify the formula like so:

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

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

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

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

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

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


References