question

tbriley avatar image
tbriley asked

How to do a global game marketplace?

I've recently done a couple of experimental projects built on Ethereum and NEO blockchains. The DLT space is built on a lot of hype at the moment, but there's some really cool things you can do when you open up the economies to developers and players. But they're not that mature yet, and I'm wondering how to add similar kinds of features with PlayFab (I'm not at all experienced with online + connected games).

One thing I'm wondering how to achieve is a global marketplace, think not too unlike CryptoKitties. I looked into the player trading feature, but it seems it doesn't support virtual currencies. So the way I've currently setup my title is to have a single catalog of characters created on the server via scheduled tasks. They have baked in custom properties for eyes, body type, mouth, etc, and then some properties that can be edited like description, ownerID and price.

What I'd thought i could do is get the list of items in the client. If ownerID matches playerID the player could set a price and list the character via CloudScript. CloudScript would verify the ownerIDs match and if so update the price data. Other clients would see all characters whose ownerIDs are not theirs in the marketplace. If they have enough coins, they can purchase the character, also via CloudScript.

Where I'm getting stuck is how to update the catalog data via the server api in CloudScript. The closest most recent advice I've found is here. It seems like this isn't really a recommended or supported thing and I'll have to workaround it? Just looking for any advice the team or other users may have in achieving this, understanding that server side is very much outside my current wheelhouse (though I'm open to learning). Cheers!

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
brendan avatar image
brendan answered

No, catalogs cannot be changed as a result of player behavior. That would cause severe issues for your title, and may require us to disable the API calls that trigger this in your title, to prevent performance issues for others.

What you're describing is a global marketplace, where players can sell items to other players. We do have a backlog item to provide that in a future update, but it is not something we can support right now. Keep an eye on our blog page - we post there with updates on new features regularly, so when this is available, you'll see it there.

4 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

tbriley avatar image tbriley commented ·

cheers @Brendan, i figured as much but was hoping there was some way to hack this together while i worked out a long term solution.

another idea was to simply turn the virtual currency into an inventory item, but it seems we can't work with stackable items and when we open trades we can't request multiple item ids of the same type.

the only other thing i could think of is having some fancy denomination exchange logic going on. for example a token 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 20, 30, 40, 50, etc... so as i collect or purchase tokens or try to make a trade, the server could 'make change' as it were. or is there something other approach i'm missing?

i do hope to see this sooner rather than later. while it may not be a top requested feature i think opening game marketplaces in this way will become a very powerful tool for developers in the near future. a few days playing with blockchains for example and you start to get a lot of really interesting ideas for intra and inter-game marketplaces and economies. but the tech i think is still too immature to use in production, so it would be nice to have a more traditional solution like playfab which offers a somewhat comparable feature set.

0 Likes 0 ·
brendan avatar image brendan tbriley commented ·

Sorry, but while I do agree that this is a significant feature, it's not something we can support right now. As I said, we do have a backlog item to provide this in a future release, but I can't realistically provide a date for that just yet.

0 Likes 0 ·
tbriley avatar image tbriley brendan commented ·

I think I've got a basic structure working. But a couple more questions come to mind wrt interacting with trades:

1. Is there a way via the admin panel to view and, more importantly, interact with pending trades? It would simplify testing to be able to cancel and accept this way.

2. How can I serve up a global list of trades to players? I'm seeing conflicting advice on the forums and docs over time; it seems early on using a global instance of shared group data was recommended, but I've come across more recent warnings against this approach. Judging by what I'm seeing here, I can guess you'd recommend something like I setup an external data store for keeping a global list like this. But at the moment I'm planning a soft launch in a single region only, and I'd really like to keep things entirely in PlayFab if possible. Also, as you guys say, these sorts of data stores are one of the reasons to use services like PlayFab in the first place ;) What would you personally recommend were you to be testing a feature like this?

0 Likes 0 ·
Show more comments

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.