how to detect if a room is destroyed from server side ?

0 votes
as the server engine will destroy the empty room , so i need this function/event to destroy all server resource from that room
asked Feb 24, 2016 in AppWarpS2 by nguyenanhdung (51 points)

1 Answer

0 votes

Hi Nugyen,

You can mantain your own collection with the roomID at ZoneAdapter level. And can use following ways to release the resources.

  • Using Zone RPC : When a a room is destroyed from server side user will get the update notification of Room deletion. At that time you can call zone RPC from client side that do all the cleaning. On AppWarp at Zone Adapter you define that RPC API and clean the resources of by validating the collection you have maintain against the room ID.
  • Scheduling : You can create your own scheduler at Zone level that runs after a periodic time and fetch all available rooms and refresh the collection and clean the resources.

Let me know if it helps.

Thanks

Vishnu Garg

 

 

answered Feb 25, 2016 by Vishnu Garg (674 points)
do you mean the function "handleDeleteRoomRequest" at zone level to detect if a room is destroyed? i did try override that function but does not see any call there.
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
...