1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 |
----------------------
-- Dropdown Feature --
----------------------
return object
end
end
end
end
local FIRST_CHOICE = 1
end
if selectedChoiceIndex then
end
end
end
end
end
end
end
return nil
end
if choiceIndex then
else
end
end
return object
end
end
end
end
end
end
end
function ZO_TradingHouseDropDownFeature_Params : SetGetValueFromItemCallback ( getValueFromItemCallback )
end
return i
end
end
end
end
return nil
end
end
end
end
end
-------------------------
-- Level Range Feature --
-------------------------
return object
end
end
end
end
local NO_MIN_LEVEL , NO_MAX_LEVEL , NOT_CHAMPION_RANK = nil , nil , false
end
-- different types of items interpret the level range provided differently
end
end
end
end
end
if minLevel or maxLevel then
minLevel = minLevel or 0
maxLevel = maxLevel or ( isChampionRank and GetChampionPointsPlayerProgressionCap ( ) or GetMaxLevel ( ) )
local ICON_SIZE = "100%"
if minLevel == maxLevel then
local exactLevel , exactChampionPoints = 0 , 0
if isChampionRank then
exactChampionPoints = minLevel
else
exactLevel = minLevel
end
else
end
end
end
return nil
end
--This feature will not be set from an item link
end
-------------------------
-- Price Range Feature --
-------------------------
return object
end
-- Can be overriden
end
end
end
local NO_MIN_PRICE , NO_MAX_PRICE = nil , nil
end
if minPrice or maxPrice then
end
end
searchTable [ "PriceRange" ] = { minPrice , maxPrice }
end
local savedPriceRange = searchTable [ "PriceRange" ]
end
end
end
local savedPriceRange = searchTable [ "PriceRange" ]
if minPrice or maxPrice then
minPrice = minPrice or MIN_TRADING_HOUSE_POST_PRICE
maxPrice = maxPrice or MAX_PLAYER_CURRENCY
local minPriceString = ZO_Currency_FormatPlatform ( CURT_MONEY , minPrice , ZO_CURRENCY_FORMAT_AMOUNT_ICON )
local maxPriceString = ZO_Currency_FormatPlatform ( CURT_MONEY , maxPrice , ZO_CURRENCY_FORMAT_AMOUNT_ICON )
if minPrice == maxPrice then
return minPriceString
else
-- delay using zo_strformat until this is combined with other descriptions
end
end
end
return nil
end
--This feature will not be set from an item link
end
------------------
-- Feature Data --
------------------
ZO_TRADING_HOUSE_FEATURE_TYPE_DROPDOWN = 1
ZO_TRADING_HOUSE_FEATURE_TYPE_LEVELRANGE = 2
ZO_TRADING_HOUSE_FEATURE_TYPE_SEARCHCATEGORY = 3
ZO_TRADING_HOUSE_FEATURE_TYPE_PRICERANGE = 4
ZO_TRADING_HOUSE_FEATURE_TYPE_NAMESEARCH = 5
ZO_TRADING_HOUSE_FEATURE_TYPES = { }
ZO_TRADING_HOUSE_DROPDOWN_FEATURE_PARAMS = { }
ZO_TRADING_HOUSE_FEATURE_TYPES [ key ] = ZO_TRADING_HOUSE_FEATURE_TYPE_DROPDOWN
ZO_TRADING_HOUSE_DROPDOWN_FEATURE_PARAMS [ key ] = params
return params
end
ZO_TRADING_HOUSE_LEVELRANGE_FEATURE_CALLBACKS = { }
ZO_TRADING_HOUSE_FEATURE_TYPES [ key ] = ZO_TRADING_HOUSE_FEATURE_TYPE_LEVELRANGE
end
ZO_TRADING_HOUSE_FEATURE_TYPES [ "SearchCategory" ] = ZO_TRADING_HOUSE_FEATURE_TYPE_SEARCHCATEGORY
ZO_TRADING_HOUSE_FEATURE_TYPES [ "PriceRange" ] = ZO_TRADING_HOUSE_FEATURE_TYPE_PRICERANGE
ZO_TRADING_HOUSE_FEATURE_TYPES [ "NameSearch" ] = ZO_TRADING_HOUSE_FEATURE_TYPE_NAMESEARCH
end )
end
local NO_VALUE = nil
local choiceText = ""
else
end
end
end
-- Traits
do
weaponTraitParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_TRAIT ) )
ITEM_TRAIT_TYPE_WEAPON_ORNATE ,
ITEM_TRAIT_TYPE_WEAPON_INTRICATE ,
ITEM_TRAIT_TYPE_WEAPON_POWERED ,
ITEM_TRAIT_TYPE_WEAPON_CHARGED ,
ITEM_TRAIT_TYPE_WEAPON_PRECISE ,
ITEM_TRAIT_TYPE_WEAPON_INFUSED ,
ITEM_TRAIT_TYPE_WEAPON_DEFENDING ,
ITEM_TRAIT_TYPE_WEAPON_TRAINING ,
ITEM_TRAIT_TYPE_WEAPON_SHARPENED ,
ITEM_TRAIT_TYPE_WEAPON_DECISIVE ,
ITEM_TRAIT_TYPE_WEAPON_NIRNHONED ,
ITEM_TRAIT_TYPE_NONE ,
} )
companionWeaponTraitParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_TRAIT ) )
ITEM_TRAIT_TYPE_WEAPON_QUICKENED ,
ITEM_TRAIT_TYPE_WEAPON_PROLIFIC ,
ITEM_TRAIT_TYPE_WEAPON_FOCUSED ,
ITEM_TRAIT_TYPE_WEAPON_SHATTERING ,
ITEM_TRAIT_TYPE_WEAPON_AGGRESSIVE ,
ITEM_TRAIT_TYPE_WEAPON_SOOTHING ,
ITEM_TRAIT_TYPE_WEAPON_AUGMENTED ,
ITEM_TRAIT_TYPE_WEAPON_BOLSTERED ,
ITEM_TRAIT_TYPE_WEAPON_VIGOROUS ,
ITEM_TRAIT_TYPE_NONE ,
} )
armorTraitParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_TRAIT ) )
ITEM_TRAIT_TYPE_ARMOR_ORNATE ,
ITEM_TRAIT_TYPE_ARMOR_INTRICATE ,
ITEM_TRAIT_TYPE_ARMOR_STURDY ,
ITEM_TRAIT_TYPE_ARMOR_IMPENETRABLE ,
ITEM_TRAIT_TYPE_ARMOR_REINFORCED ,
ITEM_TRAIT_TYPE_ARMOR_WELL_FITTED ,
ITEM_TRAIT_TYPE_ARMOR_TRAINING ,
ITEM_TRAIT_TYPE_ARMOR_INFUSED ,
ITEM_TRAIT_TYPE_ARMOR_PROSPEROUS ,
ITEM_TRAIT_TYPE_ARMOR_DIVINES ,
ITEM_TRAIT_TYPE_ARMOR_NIRNHONED ,
ITEM_TRAIT_TYPE_NONE ,
} )
companionArmorTraitParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_TRAIT ) )
ITEM_TRAIT_TYPE_ARMOR_QUICKENED ,
ITEM_TRAIT_TYPE_ARMOR_PROLIFIC ,
ITEM_TRAIT_TYPE_ARMOR_FOCUSED ,
ITEM_TRAIT_TYPE_ARMOR_SHATTERING ,
ITEM_TRAIT_TYPE_ARMOR_AGGRESSIVE ,
ITEM_TRAIT_TYPE_ARMOR_SOOTHING ,
ITEM_TRAIT_TYPE_ARMOR_AUGMENTED ,
ITEM_TRAIT_TYPE_ARMOR_BOLSTERED ,
ITEM_TRAIT_TYPE_ARMOR_VIGOROUS ,
ITEM_TRAIT_TYPE_NONE ,
} )
jewelryTraitParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_TRAIT ) )
ITEM_TRAIT_TYPE_JEWELRY_ORNATE ,
ITEM_TRAIT_TYPE_JEWELRY_INTRICATE ,
ITEM_TRAIT_TYPE_JEWELRY_ARCANE ,
ITEM_TRAIT_TYPE_JEWELRY_HEALTHY ,
ITEM_TRAIT_TYPE_JEWELRY_ROBUST ,
ITEM_TRAIT_TYPE_JEWELRY_TRIUNE ,
ITEM_TRAIT_TYPE_JEWELRY_INFUSED ,
ITEM_TRAIT_TYPE_JEWELRY_PROTECTIVE ,
ITEM_TRAIT_TYPE_JEWELRY_SWIFT ,
ITEM_TRAIT_TYPE_JEWELRY_HARMONY ,
ITEM_TRAIT_TYPE_JEWELRY_BLOODTHIRSTY ,
ITEM_TRAIT_TYPE_NONE ,
} )
companionJewelryTraitParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_TRAIT ) )
ITEM_TRAIT_TYPE_JEWELRY_QUICKENED ,
ITEM_TRAIT_TYPE_JEWELRY_PROLIFIC ,
ITEM_TRAIT_TYPE_JEWELRY_FOCUSED ,
ITEM_TRAIT_TYPE_JEWELRY_SHATTERING ,
ITEM_TRAIT_TYPE_JEWELRY_AGGRESSIVE ,
ITEM_TRAIT_TYPE_JEWELRY_SOOTHING ,
ITEM_TRAIT_TYPE_JEWELRY_AUGMENTED ,
ITEM_TRAIT_TYPE_JEWELRY_BOLSTERED ,
ITEM_TRAIT_TYPE_JEWELRY_VIGOROUS ,
ITEM_TRAIT_TYPE_NONE ,
} )
companionAllTraitParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_TRAIT ) )
{ ITEM_TRAIT_TYPE_WEAPON_QUICKENED , ITEM_TRAIT_TYPE_ARMOR_QUICKENED , ITEM_TRAIT_TYPE_JEWELRY_QUICKENED } ,
{ ITEM_TRAIT_TYPE_WEAPON_PROLIFIC , ITEM_TRAIT_TYPE_ARMOR_PROLIFIC , ITEM_TRAIT_TYPE_JEWELRY_PROLIFIC } ,
{ ITEM_TRAIT_TYPE_WEAPON_FOCUSED , ITEM_TRAIT_TYPE_ARMOR_FOCUSED , ITEM_TRAIT_TYPE_JEWELRY_FOCUSED } ,
{ ITEM_TRAIT_TYPE_WEAPON_SHATTERING , ITEM_TRAIT_TYPE_ARMOR_SHATTERING , ITEM_TRAIT_TYPE_JEWELRY_SHATTERING } ,
{ ITEM_TRAIT_TYPE_WEAPON_AGGRESSIVE , ITEM_TRAIT_TYPE_ARMOR_AGGRESSIVE , ITEM_TRAIT_TYPE_JEWELRY_AGGRESSIVE } ,
{ ITEM_TRAIT_TYPE_WEAPON_SOOTHING , ITEM_TRAIT_TYPE_ARMOR_SOOTHING , ITEM_TRAIT_TYPE_JEWELRY_SOOTHING } ,
{ ITEM_TRAIT_TYPE_WEAPON_AUGMENTED , ITEM_TRAIT_TYPE_ARMOR_AUGMENTED , ITEM_TRAIT_TYPE_JEWELRY_AUGMENTED } ,
{ ITEM_TRAIT_TYPE_WEAPON_BOLSTERED , ITEM_TRAIT_TYPE_ARMOR_BOLSTERED , ITEM_TRAIT_TYPE_JEWELRY_BOLSTERED } ,
{ ITEM_TRAIT_TYPE_WEAPON_VIGOROUS , ITEM_TRAIT_TYPE_ARMOR_VIGOROUS , ITEM_TRAIT_TYPE_JEWELRY_VIGOROUS } ,
ITEM_TRAIT_TYPE_NONE ,
} )
end
-- Enchantments
do
-- none should be last
if left . value == ENCHANTMENT_SEARCH_CATEGORY_NONE or right . value == ENCHANTMENT_SEARCH_CATEGORY_NONE then
end
end
local NO_FILTER = nil
local enchantmentChoices = { }
table . insert ( enchantmentChoices , { name = GetString ( "SI_ENCHANTMENTSEARCHCATEGORYTYPE" , enchantmentSearchCategory ) , value = enchantmentSearchCategory } )
end
end
end
end
weaponEnchantmentParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_ENCHANTMENT ) )
AddEnumSearcher ( weaponEnchantmentParams , TRADING_HOUSE_FILTER_TYPE_ENCHANTMENT , GetItemLinkEnchantSearchCategory )
armorEnchantmentParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_ENCHANTMENT ) )
AddEnumSearcher ( armorEnchantmentParams , TRADING_HOUSE_FILTER_TYPE_ENCHANTMENT , GetItemLinkEnchantSearchCategory )
jewelryEnchantmentParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_ENCHANTMENT ) )
AddEnumSearcher ( jewelryEnchantmentParams , TRADING_HOUSE_FILTER_TYPE_ENCHANTMENT , GetItemLinkEnchantSearchCategory )
end
-- Quality
do
local QUALITY_VALUES =
{
ITEM_DISPLAY_QUALITY_NORMAL ,
ITEM_DISPLAY_QUALITY_MAGIC ,
ITEM_DISPLAY_QUALITY_ARCANE ,
ITEM_DISPLAY_QUALITY_ARTIFACT ,
ITEM_DISPLAY_QUALITY_LEGENDARY ,
}
local ANY_VALUE = nil
end
end
qualityParams : SetDisplayName ( GetString ( "SI_TRADINGHOUSEFEATURECATEGORY" , TRADING_HOUSE_FEATURE_CATEGORY_QUALITY ) )
end
-- Level Range
do
if minLevel or maxLevel then
local filterType = isChampionRank and TRADING_HOUSE_FILTER_TYPE_CHAMPION_POINTS or TRADING_HOUSE_FILTER_TYPE_LEVEL
end
end
if minLevel or maxLevel then
minLevel , maxLevel = ConvertItemGlyphTierRangeToRequiredLevelRange ( isChampionRank , minLevel , maxLevel )
local filterType = isChampionRank and TRADING_HOUSE_FILTER_TYPE_CHAMPION_POINTS or TRADING_HOUSE_FILTER_TYPE_LEVEL
end
end
end |