Search Unity

Suggestions to develop a typical quiz (trivia) game - architecture

Discussion in 'Formats & External Tools' started by Jorhoto, Jun 4, 2019.

  1. Jorhoto

    Jorhoto

    Joined:
    May 7, 2019
    Posts:
    99
    Hello, New to Unity :)

    The game will be a quiz(trivia) 2D game and it should run in low-spec smartphones or tablets (Android and IOs), so performance is very important. Thinking on architecture, I got a few questions.

    1. In order to make it easily extendable with new categories/questions/answers the idea is to use SQLite, so basically I can load from it random-questions each time the player starts a category.

    2. Users need to login in order to be able to access the game. Would you use a webserver for this? I would build a php script that would check the user-pass and give or deny access. Communication between app and web-server could be done via HTTP-POST.

    3. I have to save all the player activity: the questions they got, what they answered and if they did it correct or wrong. The score they got, etc. I will save it also in SQLite in the own device, and, when available I will dump it again to a webserver, via php script. For this I think again in another PHP script. Please note in the end I won't control the webserver.

    So do you think this would be a good architecture?
    Thank you for your time and any suggestion is very much appreciated .
     
  2. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,779
    While this is feasible, why adding complexity, to such simple game? Prepare set of questions as game design process. And make a game single player, so players don't need an internet to play your game.
    Optionally make update option, so player can download new set of questions, which may extend playability. That can be up to the player decision, as example.
     
    Jorhoto likes this.
  3. Jorhoto

    Jorhoto

    Joined:
    May 7, 2019
    Posts:
    99
    Hello,
    The game is single player and the internet is just to limit access to certain users (in a db which resides in a web server). I will need to save info there also for things like a ladder and some statistics.

    There is a common group of categories required for all players but others are just for specific ones. That's why I need to identify players by login.

    BTW, I never developed any mobile app yet, please could you explain a bit how is the process of updating your app?

    Thanks ;)
     
  4. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,779
    I meant updating, using request to PHP. Rest is straight forward.
     
  5. Jorhoto

    Jorhoto

    Joined:
    May 7, 2019
    Posts:
    99
    request to PHP is the simplest method I can think to validate an user login against a DB that resides in a web server (the one the app customer will use). Would you suggest another approach?

    Thanks for the fast answer ;)
     
  6. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,779
    Indeed.