Search Unity

[RELEASED] Trivia Quiz Game Template

Discussion in 'Assets and Asset Store' started by puppeteer, Sep 25, 2015.

  1. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    It was tested on an Xbox One controller and another generic controller ( not even branded ), and the Amazon TV controller support was confirmed to me by a customer who owns it, as I don't.

    Now that it's possible to have an endless number of players ( in the hotseat demo you have up to 8, but it's not limited ) I'm looking into the input system more, as having 8 players each with his own input is going to be a problem with the default unity input manager. That's why I have Rewired on my sights which you've already suggested a while back. The only limitation is that I want the package to work as is without forcing the used to install anything extra. If that can happen and include Rewired as an option then we're good to go.
     
  2. longroadhwy

    longroadhwy

    Joined:
    May 4, 2014
    Posts:
    1,551
    Basically if you have one internal function (e.g. trivia_inputs) that all inputs go through. Then have an two other functions internal_input() and external_input() that both internally call trivia_input. That way your internal input system is completely separate from what is being used by users. Which is either Unity input or an alternative input system (e.g. Rewired).

    There is some discussion about that in this thread.

    http://forum.unity3d.com/threads/how-to-make-better-code-assets-for-the-asset-store.366355/
     
    Last edited: Feb 17, 2016
    puppeteer likes this.
  3. Andreas12345

    Andreas12345

    Joined:
    Oct 17, 2013
    Posts:
    526
    Hi,
    i did not find where can i set how man questions are needed to win the game.
    Also not in the Documentation.
    Where is it?
     
  4. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    The next update has been submitted and should be in the store within a few days (3-5 hopefully). In the Trello you can see what was added to this version, as well as what could possibly be in future updates:
    https://trello.com/b/ml2DoSW7/trivia-quiz-game

    @Andreas12345 : Are you referring to the flat questions-to-win number from the upcoming update? (https://trello.com/b/ml2DoSW7/trivia-quiz-game), or are you asking about the questions in the current version. Right now the question list is divided into question-groups based on the bonus they give ( from lowest bonus to highest bonus ). You can also set how many questions from each group are asked, so the game goes through each group and asks a certain amount of questions, then moves on to the next group, and so on until all groups are asked. Then you reach victory. The next update also has a simple flat-question-number that ignores all groups and whether we are correct or not, and just asks a X number of questions before finishing the game.

    In the documentation for the current version, read about Questions Per Group to see how to control the length of the game:
    http://puppeteerinteractive.com/Documentation/TQG/documentation.pdf

    @longroadhwy This is a great read, not just the external input suggestions, but making the asset more usable in general. So far I managed to keep the package working the same on all versions ( from 4.6 and upwards to 5.3+, you can even upgrade from 4.6 to 5.3 without trouble ), and so long as I manage to keep it all intact I'll try to make it as expandable as possible. I'm going to focus on three things for the next update:
    1. XML, getting it out of the main gamecontroller script, and adding more options, handling extreme cases, append, export(?), local load, and seeing if I can accept XLS as an alternative.
    2. Separating the inputs from the main gamecontroller, allowing them to be set up separately from unity's default manager.
    3. Allowing the entire theme of the game to be controlled from one place ( font, backgrounds, icons, tabs, and buttons ).
     
    Andreas12345 likes this.
  5. Andreas12345

    Andreas12345

    Joined:
    Oct 17, 2013
    Posts:
    526
    Helps me a lot thank you
     
  6. longroadhwy

    longroadhwy

    Joined:
    May 4, 2014
    Posts:
    1,551
    That is good news. Looking forward to this update. Hopefully the asset store does not take too long to release it.

    Glad you found the information useful. That is a large amount of work to keep a product working with so many different Unity versions. Keep up the good work.

    Your list is a good one.

    (a) I think having an export XML option would be a good one as is local load.
    (b) Separate Input so you can support Rewired or other third party input options will be my favorite feature.
     
    Last edited: Feb 24, 2016
  7. PoshTimmy

    PoshTimmy

    Joined:
    Feb 26, 2016
    Posts:
    1
    Very attractive template brother.

    Sorry for the newb question, but I'm having great trouble just getting the game to load in unity. The demo works fine.
     
  8. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    Which version of Unity are you using? The package should open and run straight-out-of-the-box for any Unity version between 4.6.9 and 5.3.2.
     
  9. rafasaints

    rafasaints

    Joined:
    Feb 27, 2016
    Posts:
    2
    HELLO!
    Just a question, it's possible to change the languange? Not for the questions because i can change on xml, but for the interface.
     
    puppeteer likes this.
  10. Publishmaker

    Publishmaker

    Joined:
    Oct 20, 2015
    Posts:
    7
    I'm from Brazil, my name is Rogerio.

    I bought the asset and is very good, but how do I use this mode with the wheel?
     
  11. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    The XML feature is used for importing questions into your project, but the project as a whole can be edited and customized from within Unity editor itself. Right to Left languages are not supported by default ( they appear flipped ), but there is a plugin on the store that allows you to use RTL languages ( Arabic, etc ).

    Did you open the project in Unity and take a look at it?

    This update has been submitted to the store. It will take a few more days to be accepted and appear on the store.
     
  12. Publishmaker

    Publishmaker

    Joined:
    Oct 20, 2015
    Posts:
    7
    Thanks!!!
     
  13. rafasaints

    rafasaints

    Joined:
    Feb 27, 2016
    Posts:
    2
    Hi, no i didn't buy yet.
    Thank for the answer.
     
  14. Publishmaker

    Publishmaker

    Joined:
    Oct 20, 2015
    Posts:
    7
    Hello!

    You could do a tutorial Unity ADS?
     
  15. patteamb

    patteamb

    Joined:
    May 6, 2015
    Posts:
    2
    We would love to integrate the trivia game into our project so that we can switch between our current game and different sets of trivia questions.

    We've tried two methods to no avail:
    1) adding a few gamecontroller prefabs to our project and disabling/enabling them in code at certain points. (This "works" in that the trivia game show on the canvas while enabled, but is non-functional).
    2) adding the gamecontroller prefab to a few different scenes and doing scene switches. We run into essentially the same problem above.

    I know this is meant to be a standalone game, but might you have any suggestions?

    Thanks a ton, and great work on this asset!
     
  16. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    I'll add it to the next update ( The one after this one, which was submitted several days ago). It's basically a couple of minutes of work to have ads showing up in the game. I already have it in most of my other packages, so it shouldn't be a problem.

    I think it would depend on the nature of the container game, but as long as it has some sort of pause functionality it shouldn't be much of a problem to stop the game, show a quiz, then proceed with the game once you answer the question/s.

    What if I add this feature as an example in the project? Something like a mario-like where at some point the game shows a quiz which must be answered in order to activate something or continue the game. Would such n example be useful to you?
     
  17. Publishmaker

    Publishmaker

    Joined:
    Oct 20, 2015
    Posts:
    7
    Hello!
    There exists a called scene: Puppeteer Unity Ads.
    You said that was already integrated, so how do?
     
  18. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    Unity updated some of the ways they integrate ads. There is documentation in the trivia quiz package for the current unityads, but here is the tutorial I'm working on for the latest UnityAds integration ( It's intended for Unity 5.2 and above, and refers to another package, but the process is the same ).

    UnityAds Integration

    Before starting download this updated UnityAds script:
    puppeteerinteractive.com/assets/PUPUnityAds.cs

    Since Unity 5.2 UnityAds integration has been simplified, here’s how you can have fullscreen video ads in your game:

    Activating UnityAds service
    From the top menu choose Window > Unity Services.



    In the new window that appears, choose your organization so that an ID will be generated. A list of services appears, choose the Ads service and turn it on. Then choose the age group this game will be targeted towards, and save the changes.



    Once you save the changes, a new screen appears. Here you can set which platform the ads are targeted to, Android or iOS. It’s advised that you Enable Test Mode while working on your game to avoid any potential problems. At the bottom of the screen you can see the IDs for the iOS platform and the Android platform.



    Showing ads in your game
    Before testing out the ads, make sure you are in a compatible platform in the editor, such as Android or iOS.



    Import the UnityAds script you downloaded into your project. If you haven't done so already, download it from here:
    puppeteerinteractive.com/assets/PUPUnityAds.cs

    Drag the script into an empty object in the game sceneyou want to show ads in.

    Click on the UnityAds object you have in the scene, here you can set the number of times the level needs to be loaded before showing an ad. By default it loads 3 times before showing an ad.



    That’s all, if you test the game now in the editor and restart the level several times you will be presented with a blue test ad screen.

    In the actual game released on Android/iOS the game would pause and present you with a full screen video advertisement.

    Before releasing a game, make sure you uncheck Enable Test Mode.

    For more info about integrating UnityAds read this:

    http://unityads.unity3d.com/help/monetization/integration-guide-unity

    Hope that helps. If you find this a bit too difficult, maybe I can make a narrated video showing how to put UnityAds quickly. What do you think? Text or Video?
     
  19. patteamb

    patteamb

    Joined:
    May 6, 2015
    Posts:
    2
    An example, or even just a basic idea of how you think it would work would be a life saver for us right now. The method we tried was to disable the Game Controller in the inspector, and then enable it via SetActive in code. Any other ideas? Thanks so much!
     
  20. Publishmaker

    Publishmaker

    Joined:
    Oct 20, 2015
    Posts:
    7
    Thank you!!!

    If you have any problem inform.
     
  21. longroadhwy

    longroadhwy

    Joined:
    May 4, 2014
    Posts:
    1,551
    Hopefully this update comes out today. What will the version number be for this update?
     
  22. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    I was hoping it would be accepted yesterday, but I still didn't get an answer. I'm going to wait one more day and then just offer the update manually until it's accepted.

    This is version 1.43 btw.
     
  23. longroadhwy

    longroadhwy

    Joined:
    May 4, 2014
    Posts:
    1,551
    Since this is the week before GDC 2016 I would expect Unity to be very busy. It seems like there are far more updates to various packages in the asset store than I have seen in a while. Maybe it is GDC related or developers updating assets due to Unity 5.3/5.4 beta API changes. Gaia sure seems to be driving many updates to various assets and creation of new assets.

    Thanks for the version info. Looking forward to your new update.
     
  24. Publishmaker

    Publishmaker

    Joined:
    Oct 20, 2015
    Posts:
    7
    Hello!

    The explanation was perfect, works on the project, but does not work when compiling smartphone.
     
  25. Publishmaker

    Publishmaker

    Joined:
    Oct 20, 2015
    Posts:
    7
    Hello!

    Thank you worked.

    But I have a question. Where will I see my earnings?
     
  26. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
  27. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    If anyone wants access to the upcoming update (1.43), just send me your invoice to my mail and I'll link you. Looks like the update will take a few more days to hit the store.
     
  28. karmik

    karmik

    Joined:
    Oct 8, 2014
    Posts:
    124
    Just checked update is in :)
     
  29. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    That's awesome, just saw the confirmation mail :D

    Tell me if you have any questions.
     
  30. longroadhwy

    longroadhwy

    Joined:
    May 4, 2014
    Posts:
    1,551
    Great news indeed. Downloading shortly. :)
     
  31. yazidane

    yazidane

    Joined:
    Oct 6, 2015
    Posts:
    29
    Sir...i already buy your template...great and i love it.

    Any consideration for future add on like

    - other option for hotseat maybe an online match making
    - social sharing button after finished the quiz to tell their friends about the score and telling they are playing this game and would share the link of the app link for example google play link to the apps
    - online score ranking between friends

    Just want to say you had done a great job with this trivia app. :)
     
    puppeteer likes this.
  32. karmik

    karmik

    Joined:
    Oct 8, 2014
    Posts:
    124
    The catogery wheel looks really cool.. It really is a great asset with consinuous updates..
    I read you are working on adding game progress and question review function to show which question is the user on and a screen to show the info on each question. Along with these I request you to add a review screen at the end of the quiz to show summary of the quiz and an option to go back and review the questions.. Or at the end of quiz at least the list of questions answered incorrectly to show the player where he is lacking..
    I am trying to code it but looks too hard for me to implement..
     
    puppeteer likes this.
  33. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    Online and social are the toughest parts for me to implement, but as I go through with more updates for this package I may be able to do some forms of social interaction, preferably using some Unity-native services ( https://unity3d.com/services/multiplayer ). Still a ways off though.


    So you would want a list displaying all previous questions along with the correct answer for each, with an option to show the wrong ones. That's a good idea, I'll add it to the to-do pool.

    It looks like more and more people are using this for training purposes, which was totally unexpected when I first made the quiz :D
     
    karmik likes this.
  34. longroadhwy

    longroadhwy

    Joined:
    May 4, 2014
    Posts:
    1,551
    Training is great market to be in. With the flexibility of Unity compared to the standalone options that are on the market today is what makes it a great product. Keep up the good work.
     
  35. karmik

    karmik

    Joined:
    Oct 8, 2014
    Posts:
    124
    Perhaps you should consider changing the asset name and description a bit as well give it a training solution feel.

    Might bring in more customers :)
     
  36. longroadhwy

    longroadhwy

    Joined:
    May 4, 2014
    Posts:
    1,551
    That could be a good idea for @puppeteer. He should include many of these different use cases in the first msg in this thread so people can start thinking of many different ways to apply this product.
     
  37. Realidade

    Realidade

    Joined:
    Mar 9, 2016
    Posts:
    24
    Hello! How are you?

    I have the following problem: The ads do not appear on my phone, but appears in others. What is the problem?
     
  38. yazidane

    yazidane

    Joined:
    Oct 6, 2015
    Posts:
    29
    sir...for trivia type apps you prefer unityads or admob.. which one better with this type of apps
     
  39. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    I'm not sure what could cause this, are both devices the same or are they different platforms? ( ex: Android and iOS )
    What are the devices you tested on?

    In my trivia template I have UnityAds support, which can show the video ad when loading a new level ( or restarting ). You can of course add other services like admob using the unity asset store. As to which ones are better, I personally prefer UnityAds in general because they are more reliable and have less chance of causing your app to be blocked by google.

    Read here more about the comparison between UnityAds and other services:
    http://forum.unity3d.com/threads/unityads-vs-admob-who-win.272572/
     
  40. gschamot

    gschamot

    Joined:
    Mar 2, 2014
    Posts:
    1
    Hi man, thanks for the great template. Now I am learning my way around it and as a beginner I find everything suprisingly easy.

    I have one question though; I wanted to add a 5th answer to questions and when I add another button, template automatically adds the button below the third answer. This pushes the other answers a little upwards and then they overlap with the question area.

    I tried moving it around myself but it seems like it's locked, may be this is to avoid other mistakes that could happen when we poke around your template I understand that.:) But is there any way to solve this?

    I might have other questions but so far this is it.

    Thanks again:)
     
    puppeteer likes this.
  41. oluwaseyeayinla

    oluwaseyeayinla

    Joined:
    Mar 22, 2016
    Posts:
    3

    Well if you haven't solved it by now, there should be a Grid Layout on the panel that holds the buttons.

    You would have to disable that to manually align it the way you want to.

    Or play around with the Grid Layout public variables to get your desired look
     
    puppeteer likes this.
  42. karmik

    karmik

    Joined:
    Oct 8, 2014
    Posts:
    124
    @puppeteer saw you are building a catogery selector grid so players can select catogeries to play from. That was exactly what i am looking for.. :)
    Save player name and math quiz look to be good options to have too..
     
  43. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    @Pappae: Thanks for answering that question, you beat me to it :D

    @gschamot: Like Pappae said this is the grid layout component that allows you to organize UI objects in a grid ( rows, columns, or both ). You can play around with the values to change the size of UI elements ( ex: answer buttons ) in the grid, or how far apart they are organized. Also how they are sorted out from top to bottom, left to right, etc.

    Read more about it here:
    http://docs.unity3d.com/Manual/script-GridLayoutGroup.html

    If you don't want any automatic sorting you can just remove that component or disable it, and then move around the parts freely. If you still want to have the grid but also have control over certain elements in the UI inside the grid, you can add a LayourElement component to the UI object, and set it to ignore anything that might affect it.

    Also, here's a great video from 3DBuzz that goes into the details of Unity's auto-sorting components:



    @karmik : Yes, that's going into the next update. The math thing will have to wait longer, though.
     
    gschamot likes this.
  44. Realidade

    Realidade

    Joined:
    Mar 9, 2016
    Posts:
    24
    I sent e mail with receipt.
     
  45. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    No need, the update has already been accepted to the store. You can download it now from your Downloads page through the Unity Editor Store page.
     
  46. Realidade

    Realidade

    Joined:
    Mar 9, 2016
    Posts:
    24
    Thanks!!!
     
  47. ntzeke

    ntzeke

    Joined:
    Mar 6, 2016
    Posts:
    8
    I notice after I choose an answer a/b/c/d, that same answer portion stays highlighted orange for the next question. It seems confusing. Is there any way to stop this? Sorry if this has already been covered
     
  48. soperemita

    soperemita

    Joined:
    Sep 3, 2015
    Posts:
    2
    Hi , i have a problem ,when i play in mobile am getting Highlighted Color ( i put green ) by default , before pressing any answer ,how can i solve it ?
    Screenshot_2016-03-25-19-39-50.png
     
  49. puppeteer

    puppeteer

    Joined:
    Sep 15, 2010
    Posts:
    1,282
    Does this appear only in the mobile version, or does it also show in the editor. By default, the highlight should be cleared before showing the answer, but I'll check it.

    This could also be the result of the same issue as the poster above. I'm taking a look at it. In Standalone (PC, Mac, etc) the buttons clear out after highlighting, and in mobile there should be no default highlighting at all.
     
  50. ntzeke

    ntzeke

    Joined:
    Mar 6, 2016
    Posts:
    8
    Yes, it is the mobile version. Specifically Android right now. It does sound like soperemita is experiencing the same issue.

    ***Just checked I am getting it on the editor (pressing play) as well***