View Single Post
  #10  
Old 01-21-2014, 10:25 PM
Torankusu Torankusu is offline
Elite Member
Torankusu's Avatar
Join Date: Jun 2001
Posts: 10,065
Torankusu is a jewel in the roughTorankusu is a jewel in the rough
Quote:
Originally Posted by fowlplay4 View Post
That's how I would do it, except call it mods, store it as an array, and parse the array when the item is loaded to apply it to the item/clientr flags.
Yeah, specific modifications was more or less what I eas going for, just thought the enchantment would be simpler to explain.

Would the storing it in an array part follow this model:

CharacterItems

ID - CharacterID - ItemID - Quantity - Modifications (better name..)

1 - 1 - 1 - 2 - Null
2 - 1 - 2 - 1 - Null
3 - 2 - 3 - 4 - Null
4 - 2 - 4 - 3 - Null
5 - 1 - 5 - 1 - {str, 1}
6 - 1 - 5 - 1 - {str, 2}, {dex, 1} /same character , same item id, it has 2 modifications..giving str +2 dex +1..

Quote:
You could put enchantments in it's own table though. I.e.

ID - CharacterItemID - Enchantment - EnchantmentValue

1 - 5 - strength - 1
wouldnt this essentially mean that all items that the character owns with an item id of 5 would take on these chsracteristics? Just trying to make sure I read this right. That might be useful for something else im trying to do, but at the moment I am trying to have a single item id have the ability to have modifications , sometimes multiple modifications, done to it...

Thanks for the help.
__________________
Quote:
Originally posted by Spark910
Think befreo you type.
Reply With Quote