DEV Community

Jalal Uddin
Jalal Uddin

Posted on

How gamebots in chatroom are made?

If you ever have used mig33 chat application back in between 2006 to 2014, you know there were some gamerooms, where people joined to play games. Like if I give an example:

  • A chatroom named: "LowCard"
  • People can join the room and chat
  • when someone types: "!start bet_amount" the bot game is started
  • people types "!j" to join with spending the bet_amount
  • the bot plays in some round, and each round is timer based, 30 secs per round.
  • each round players can draw by typing "!d", and card draws randomly from 2 to A
  • each round the lowest card drawers are knocked out, and finally someone wins in the last round.

Now, my curiosity to seek knowledge is:

  • If I create an application using firebase as backend, we can easily setup the chat app.
  • but if we want to use the bot functionality, what will be my process?
  • I can not implement bot codes on client side, they are vulnerable and also bots are stateful.

How can I create this functionality using firebase as backend?

Discussion (1)

Collapse
hanifhefaz profile image
Hanif Hefaz

Csn anyone reply to this thread?