how to join room when tap on push notification invitation for private room

0 votes

Hello,

i am creating a multipalyer game in which i wan to invite a player for a private table  using app42 push notificaiton form player to invited player in msg i pass name room in which inivted player should join when it tap on push notifiaction.

public void onMessage(String msg)

in this fuction i get msg which is name of room so on tap on msg it should direct join room.

 

But currenlt it launch application and all ohte ractivity destroy when i tap on message.

Plaese help me to solve this.

 

i want to kno that ifd i get message for push notification than tap on message how to redirect spicific window depend on message which message arrive on push notification.

 

asked Apr 6, 2016 in App42 DevOps by jns7309 (10 points)
recategorized Apr 6, 2016 by jns7309

1 Answer

0 votes

Hi Jns,

You need to do proper handling to join private room on opponent side. You can follow below steps for configuration.

1. Push Message format : You need to create Push message format that contains roomId as well as the message you want to show.You can use Json message for that and can modify plugin accordingly.

2. onMessage : In onMessage you can join that particular room with the specified room Id available in message , if player is connected with AppWarp, else you need to connect the player once and after succes you need to join that room.

Let me know if more queries are c oncern.

Thanks

Vishnu Garg

 

answered Apr 6, 2016 by Vishnu Garg (663 points)
i am using photon server to connect multiplayer. in my game first i login using my web server than i go in to create room screen and for private room i enter my room name which i will pass in push notification to invited player. here after input room name and max player is room i get list which player is available than i select it and send push notification. At another player here i receive push notification also witch display msg on top of screen but if my apps is close than it start from splash screen and stay on home screen. nothing happen. but i want to join room if i tap on message which has name of private room but cant get redirect on another specific window. so can you tell me if i tap on message than how can i redirect on specific window. like in private room with who has send me invitation.i have tried onMessage (string msg) to redirect on specific screen but cant succeed it Please help me how to slove it give me some idea.....
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
Migrate from Parse to ShepHertz App42
...