No categories assigned

Database:Items

Revision as of 14:37, 10 October 2009 by Bolly (talk | contribs)

About

The items tables offer an extremely flexible system for generating new armour, tradeskill items, food and much more!

NOTE: Due to the current status, some of this information may not be correct in the future. Please be sure to check each item before adding lots of them. For example at the moment due to Feedback testing a slashing weapon may sometimes respond as crushing, this doesn't mean you have got anything wrong. It just means it's not completed coded yet. If you want to keep an eye on the status please see this thread

If your making custom items this is the normal database will be using these fields for their items at the moment. So if you wanna work on custom items for your server I would use 1-999 for them, then they should be erased of course unless they decide to change things. emoticon

  • 1000 - 13714 - Normal
  • 20000 - 58949 - Armor
  • 75000 - 96520 - Spell
  • 100000 - 117764 - Weapon
  • 130000 - 134455 - Shield
  • 140000 - 143649 - Bauble
  • 150000 - 153465 - House
  • 160000 - 162309 - Food
  • 170000 - 172236 - Ranged
  • 180000 - 181958 - Recipe
  • 200000 - 200979 - Adornment
  • 210000 - 210431 - Book
  • 220000 - 220312 - Bag
  • 230000 - 230138 - Pattern
  • 240000 - 240126 - Thrown
  • 250000 - 250055 - House Container
  • 260000 - 260008 - Armor Set

Table Breakdown

The following lists how fields function in the database

Generic Item Fields

Generic item information like name, slots, nodrop, broker value etc

  • name = Name of item
  • slots = 32-bit value for slots ie 11 = Primary & Head
  • stack_count = determines how this item will store in inventories (ie may stack 20)
  • description - the description directly under the item name.
  • attuneable - 1 Adds the Attuneable tag to the weapon, but doesnt make the weapon attune when equipped
  • artifact - 1 Adds the Artifact tag to the weapon.
  • lore - 1 Adds the Lore tag to the weapon
  • temporary - 1 adds the Temporary tag to the weapon
  • no_trade - 1 adds the No Trade tag to the weapon
  • no_value - 1 adds the No Value tag and makes merchants unable to buy the item from you
  • no_zone - 1 makes you unable to zone when the weapon is equipped (dont ask me the point of this)
  • no_destroy - 1 Adds No Destroy tag, you are still able to destroy
  • crafted 1 adds Crafted tag
  • good_only - see below
  • evil_only - adds good or evil tag, can still equip with either type of race
  • sell_price - sets the sell price EG: 1 = 1cp, 100 = 1sp, 10000 = 1gp, 1000000 = 1pp
  • stack_count - 2+ Makes the item stackable and determines the maximum number of items per stack.
  • collectable - adds This Item Is Collectable to the description, will probably influence weather or not the item can be added to collections once the functionality is implemented
  • max_charges - sets the maximum number of charges on the item, used for clicky spells
  • adventure_default_level - Sets the level of the item, also the color of the name, for example if the item is level 10 and you are one the name will appear red
  • adventure_classes -
  • tradeskill_classes -
  • soe_id - the soe item id (not necessary)
  • lua_script - a way to attach a script to an item

Examples

  • Step 1: Create the item in the items table

INSERT INTO items (name,item_type,icon,skill_id_req,slots) VALUES ('A dagger','Weapon',47,418532101,1); Find a skill_id_req by SELECT id,name FROM skills WHERE name LIKE '%Slashing%';

  • Step 2: Assign an appearance in the appearance table

INSERT INTO item_appearances (item_id,equip_type) VALUES (7,7415); Find an appearance (equip_type) by SELECT appearance_id, name FROM appearances WHERE name LIKE '%dagger%'

  • Step 3: Assign weapon information in the weapons table

INSERT INTO item_details_weapon (item_id, wield_style,damage_type,damage_low1, damage_high1,delay, damage_rating) VALUES (7,2,0,10,30,30,1);

  • Reload your items

/reload items

Damage Types

  • SLASH 0
  • CRUSH 1
  • PIERCE 2
  • HEAT 3
  • COLD 4
  • MAGIC 5
  • MENTAL 6
  • DIVINE 7
  • DISEASE 8
  • POISON 9
  • DROWN 10
  • FALLING 11
  • PAIN 12

Wield Styles

  • Dual 1
  • Single 2
  • Two Handed 3

Slots

  • PRIMARY_SLOT 1
  • SECONDARY_SLOT 2
  • HEAD_SLOT 4
  • CHEST_SLOT 8
  • SHOULDERS_SLOT 16
  • FOREARMS_SLOT 32
  • HANDS_SLOT 64
  • LEGS_SLOT 128
  • FEET_SLOT 256
  • LRING_SLOT 512
  • RRING_SLOT 1024
  • EARS_SLOT_1 2048
  • EARS_SLOT_2 4096
  • NECK_SLOT 8192
  • LWRIST_SLOT 16384
  • RWRIST_SLOT 32768
  • RANGE_SLOT 65536
  • AMMO_SLOT 131072
  • WAIST_SLOT 262144
  • CLOAK_SLOT 524288
  • CHARM_SLOT_1 1048576
  • CHARM_SLOT_2 2097152
  • FOOD_SLOT 4194304
  • DRINK_SLOT 8388608
  • TEXTURES_SLOT 16777216

Damage High/Low:item_details_weapon

The only thing ive come up with so far is to set each of these to the damage range you want.

  • Damage_low1: 10, Damage_low2: 10, Damage_low3: 10
  • Damage_high1: 30, Damage_high2: 30, Damage_high3: 30

This will give you a weapon with 10-30 damage

Delay:item_details_weapon

The delay your weapon will have 1 = 0.01, 10 = 1.0, 100 = 10.0 ect..

Damage Rating:item_details_weapon

The damage rating your weapon will have, I do not believe this has any affect on the actual damage dealt, its just a number to help judge the effectiveness of a weapon vs a weapon of similar damage.

Tier

  • 1, 2 - None
  • 3 - Uncommon
  • 4, 5, 6 - Treasured
  • 7, 8 - Legendary
  • 9, 10, 11 - Fabled
  • 12 - Mythical

Item Stats

Item stats allow you to set a value against a stat type (see below).

Note that stat types work with two fields:

  • subtype - the most significant field, relates to the right two digits
  • type - used for values 100 and above

For example:

VS Disease = 208 So: subtype = 8 type = 2

Str = 0 So: subtype = 0 type = 0

Attackspeed = 612 So: subtype = 12 type = 6

  • Current as of 10/10/09
  1. define ITEM_STAT_STR 0
  2. define ITEM_STAT_STA 1
  3. define ITEM_STAT_AGI 2
  4. define ITEM_STAT_WIS 3
  5. define ITEM_STAT_INT 4
  6. define ITEM_STAT_VS_SLASH 200
  7. define ITEM_STAT_VS_CRUSH 201
  8. define ITEM_STAT_VS_PIERCE 202
  9. define ITEM_STAT_VS_HEAT 203
  10. define ITEM_STAT_VS_COLD 204
  11. define ITEM_STAT_VS_MAGIC 205
  12. define ITEM_STAT_VS_MENTAL 206
  13. define ITEM_STAT_VS_DIVINE 207
  14. define ITEM_STAT_VS_DISEASE 208
  15. define ITEM_STAT_VS_POISON 209
  16. define ITEM_STAT_VS_DROWNING 210
  17. define ITEM_STAT_VS_FALLING 211
  18. define ITEM_STAT_VS_PAIN 212
  19. define ITEM_STAT_VS_MELEE 213
  20. define ITEM_STAT_DMG_SLASH 300
  21. define ITEM_STAT_DMG_CRUSH 301
  22. define ITEM_STAT_DMG_PIERCE 302
  23. define ITEM_STAT_DMG_HEAT 303
  24. define ITEM_STAT_DMG_COLD 304
  25. define ITEM_STAT_DMG_MAGIC 305
  26. define ITEM_STAT_DMG_MENTAL 306
  27. define ITEM_STAT_DMG_DIVINE 307
  28. define ITEM_STAT_DMG_DISEASE 308
  29. define ITEM_STAT_DMG_POISON 309
  30. define ITEM_STAT_DMG_DROWNING 310
  31. define ITEM_STAT_DMG_FALLING 311
  32. define ITEM_STAT_DMG_PAIN 312
  33. define ITEM_STAT_DMG_MELEE 313
  34. define ITEM_STAT_HEALTH 500
  35. define ITEM_STAT_POWER 501
  36. define ITEM_STAT_CONCENTRATION 502
  37. define ITEM_STAT_HPREGEN 600
  38. define ITEM_STAT_MANAREGEN 601
  39. define ITEM_STAT_HPREGENPPT 602
  40. define ITEM_STAT_MPREGENPPT 603
  41. define ITEM_STAT_COMBATHPREGENPPT 604
  42. define ITEM_STAT_COMBATMPREGENPPT 605
  43. define ITEM_STAT_MAXHP 606
  44. define ITEM_STAT_MAXHPPERC 607
  45. define ITEM_STAT_SPEED 608
  46. define ITEM_STAT_SLOW 609
  47. define ITEM_STAT_MOUNTSPEED 610
  48. define ITEM_STAT_OFFENSIVESPEED 611
  49. define ITEM_STAT_ATTACKSPEED 612
  50. define ITEM_STAT_MAXMANA 613
  51. define ITEM_STAT_MAXMANAPERC 614
  52. define ITEM_STAT_MAXATTPERC 615
  53. define ITEM_STAT_BLURVISION 616
  54. define ITEM_STAT_MAGICLEVELIMMUNITY 617
  55. define ITEM_STAT_HATEGAINMOD 618
  56. define ITEM_STAT_COMBATEXPMOD 619
  57. define ITEM_STAT_TRADESKILLEXPMOD 620
  58. define ITEM_STAT_ACHIEVEMENTEXPMOD 621
  59. define ITEM_STAT_SIZEMOD 622
  60. define ITEM_STAT_UNKNOWN 623
  61. define ITEM_STAT_STEALTH 624
  62. define ITEM_STAT_INVIS 625
  63. define ITEM_STAT_SEESTEALTH 626
  64. define ITEM_STAT_SEEINVIS 627
  65. define ITEM_STAT_EFFECTIVELEVELMOD 628
  66. define ITEM_STAT_RIPOSTECHANCE 629
  67. define ITEM_STAT_PARRYCHANCE 630
  68. define ITEM_STAT_DODGECHANCE 631
  69. define ITEM_STAT_AEAUTOATTACKCHANCE 632
  70. define ITEM_STAT_DOUBLEATTACKCHANCE 633
  71. define ITEM_STAT_RANGEDDOUBLEATTACKCHANCE 634
  72. define ITEM_STAT_SPELLDOUBLEATTACKCHANCE 635
  73. define ITEM_STAT_FLURRY 636
  74. define ITEM_STAT_EXTRAHARVESTCHANCE 637
  75. define ITEM_STAT_EXTRASHIELDBLOCKCHANCE 638
  76. define ITEM_STAT_DEFLECTIONCHANCE 639
  77. define ITEM_STAT_ITEMHPREGENPPT 640
  78. define ITEM_STAT_ITEMPPREGENPPT 641
  79. define ITEM_STAT_MELEECRITCHANCE 642
  80. define ITEM_STAT_RANGEDCRITCHANCE 643
  81. define ITEM_STAT_DMGSPELLCRITCHANCE 644
  82. define ITEM_STAT_HEALSPELLCRITCHANCE 645
  83. define ITEM_STAT_MELEECRITBONUS 646
  84. define ITEM_STAT_RANGEDCRITBONUS 647
  85. define ITEM_STAT_DMGSPELLCRITBONUS 648
  86. define ITEM_STAT_HEALSPELLCRITBONUS 649
  87. define ITEM_STAT_UNCONSCIOUSHPMOD 650
  88. define ITEM_STAT_SPELLTIMEREUSEPCT 651
  89. define ITEM_STAT_SPELLTIMERECOVERYPCT 652
  90. define ITEM_STAT_SPELLTIMECASTPCT 653
  91. define ITEM_STAT_MELEEWEAPONRANGE 654
  92. define ITEM_STAT_RANGEDWEAPONRANGE 655
  93. define ITEM_STAT_FALLINGDAMAGEREDUCTION 656
  94. define ITEM_STAT_SHIELDEFFECTIVENESS 657
  95. define ITEM_STAT_RIPOSTEDAMAGE 658
  96. define ITEM_STAT_MINIMUMDEFLECTIONCHANCE 659
  97. define ITEM_STAT_MOVEMENTWEAVE 660
  98. define ITEM_STAT_COMBATHPREGEN 661
  99. define ITEM_STAT_COMBATMANAREGEN 662
  100. define ITEM_STAT_CONTESTSPEEDBOOST 663
  101. define ITEM_STAT_TRACKINGAVOIDANCE 664
  102. define ITEM_STAT_STEALTHINVISSPEEDMOD 665
  103. define ITEM_STAT_LOOT_COIN 666
  104. define ITEM_STAT_ARMORMITIGATIONINCREASE 667
  105. define ITEM_STAT_AMMOCONSERVATION 668
  106. define ITEM_STAT_STRIKETHROUGH 669
  107. define ITEM_STAT_STATUSBONUS 670
  108. define ITEM_STAT_ACCURACY 671
  109. define ITEM_STAT_COUNTERSTRIKE 672
  110. define ITEM_STAT_SHIELDBASH 673
  111. define ITEM_STAT_WEAPONDAMAGEBONUS 674
  112. define ITEM_STAT_ADDITIONALRIPOSTECHANCE 675
  113. define ITEM_STAT_CRITICALMITIGATION 676
  114. define ITEM_STAT_COMBATARTDAMAGE 677
  115. define ITEM_STAT_SPELLDAMAGE 678
  116. define ITEM_STAT_HEALAMOUNT 679
  117. define ITEM_STAT_TAUNTAMOUNT 680
  118. define ITEM_STAT_SPELL_DAMAGE 700
  119. define ITEM_STAT_HEAL_AMOUNT 701
  120. define ITEM_STAT_SPELL_AND_HEAL 702

Food

Be sure to set the following fields:

  • items.item_type = 'Food'
  • items.slots = 4194304 (food slot)

EG where the item ID is: 11

UPDATE items SET slots = 4194304, item_type = 'Food' WHERE id = 11

You can then attach additional food information using the item_details_food table

item_details_food

  • item_id - the ID of the item (see items table)
  • type - 0 = water, 1 = food
  • level - The level this item is best suited for (usually in 10 increments), effects regen
  • duration - The duration the food will last for
  • satiation - 0 Low, 1 Normal, 2 High, and 3 Superior, effects regen
INSERT INTO item_details_food (item_id,type,level,duration,satiation) VALUES (11,1,1,30,0);