bladedpenguin wrote:I'm also curious about this. I set my items up as sprites though, and they go in itemslots, which are also sprites. I'm a little wary of this setup, as I'm not sure what kind of problems I might run into down the road. I admit its a little odd to keep them as physical objects instead of abstractions.
Anyway I can see a multiplayer scenario where the host has dozens of ItemSlots, all associated with different players, invisible and not synced with each client. The "paperdoll" sprites, as well as any attacks etc., will of course be synced to each client.
It seems like only your Option 2 is really secure? It seems like using a player's own data in a multiplayer scenario is likely to be subject to manipulation of some kind.
Option 1 can be secure as well as long as you occasionally sanity-check against the saved character data on the server... there are various ways you could 'append' security onto something functional after the fact. Option 1 might be the better bet, though.
Edit: I worry about setting up your items as sprites, because then that would create all sorts of limits on what you can do with that information; seems easier to set your items as data stored somehow (an array? a series of simple variables?) and then set the item slots to be sprites that display a different image (using animation frames perhaps?) to visually indicate what's in that slot according to the variable it's set to.