Matchmaking over AppWarp

0 votes
Hello ,

Im working on a project using AppWarp service, I would like to create a room for matchmaking. lets say if USer A creates a room with at least 100$ and user B is looking for a room he will join to my room only if we set the the same range.

How Do I use the RoomProperty functions? give me an example please.

Thanks,
asked Jun 3, 2014 in AppWarp by tamirsagi (10 points)
recategorized Oct 24, 2014 by sushil

1 Answer

0 votes
You can use updateRoomProperties method to set some properties to a room like prize, etc. Then you can call the joinRoomWithProperties to join a room.

To learn more about matchmaking with room properties you can read here https://github.com/shephertz/AppWarpDeveloper/wiki/Match-Making-Basic-concept

You can view following samples
Android - https://github.com/shephertz/AppWarp_Android_SDK_JAR/tree/master/MatchMakingSample
Unity Sample - https://github.com/SuyashMShepHertz/AppWarpUnityChatSampleWithProperties
answered Jun 3, 2014 by Suyash Mohan (900 points)
Thanks for fast respond.
I think I have not made myself clear enough.

My Policy is if a user wants to join a room, the bet that was set to the room needs to be in his money range.(10% min to 33% max of his money)

Let say user A has 1000$
user B has 10000$
Assume user A creates a room and set the Bet to 1000$(so now the property for the room is "RoomBet,1000$"
now user B will look for a room with min 1000$ and max 3333$

How should I create such a matching?
How I get the property that set to the room?
That will not be possible, but you can pre-define ranges of money for example room type 1 has 100$-1000$, room type 2 has 1000$-10000$ and then join room with property roomType=1
yes exactly what I did already!

perfect!
Thanks!
I would like to ask you one more thing

when trying to JoinRoomWithProperties i get error #2 which is resource not found.
I pass as an argument a dictionary as is written on the API files.

just to make it clear, everything worked fine the only thing I changed today is from "joinRoom" to "JoinRoomWithProperties" because I added some properties.

any idea?
Such error should occur when the properties you defined is not contained by any room. Please make sure at-least a room has those properties and you are passing the properties arguments correctly. If still unsure you can paste your code snippet here.
Now it works fine but I have something else which is weird.
I tried using JoinRoomWithProperties, when my host created a room it found the room but could not subscribe .
when I changed the function to "GetRoomWithProperties" it worked fine.

any suggestions?
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on support@shephertz.com
...