Johann123's Forum Posts

  • Did you see the demo I posted in your other topic?

    https://www.dropbox.com/s/urehb4tsgeq816j/WheelOfFortune_Predictable.c3p?dl=0

    You can tell the wheel to spin to exactly the chosen number, and the result will be the same on any device.

    I did, thanks I think I'm going to use build my components off your project. Thanks for the guide, will be playing around with it!

  • Hi guys, now imagine that I have a really simple spinning wheel, and when a button is clicked, it generates an int(random(1,8), which randomizes the number between 1-8, and if 1 is selected, it'll stop at "1", and if the random number is 4, it'll stop at "4". Currently I'm just setting the rotate speed like this:

    This is the image of the wheel:

    The problem is: When I'm spinning the wheel on different devices, (Tested across 3 different screen sized mobile phone) the arrow always points at a different place. Is it possible for the results to be fixed across all screen sizes? If so, can someone provide an example for me or point me in the right direction? Thanks!

  • Good morning,

    As i remember you need only read and post.

    Please give me some hours to get home , i remember i have a C2 project at my pc that will help you.

    Good morning, that'll be amazing thanks you!

  • Using post php can do the job.

    I'm still wondering why you want to stop users playing your game. 🤔

    And may I ask why post PHP and not get? Should I not be getting the data from my database tables using GET request?

  • Using post php can do the job.

    I'm still wondering why you want to stop users playing your game. 🤔

    It’s because I’m distributing prizes to them, and I only have 10 prizes, so the first 10 players to meet the criteria will receive the prizes, and once the global variable hits 0, no one gets to play as I won’t have anything else to distribute out.

  • Use Local storage plugin

    Then "at the start of the layout"-->access the saved data

    if the accessed data is bigger than 0-->subtract 1 from it and save it back and continue the game

    else-->do not play the game

    I am attempting to make it so, once the variable is changed, when a different user plays the game it picks off from the new data, so I don't think local storage would work, let me know if I'm wrong but from my understanding, local storage only works on the same user's PC, and if another user is accessing the game the variable resets.

  • Hi guys, I’m wondering is it possible to read my global variables from a database? For example, by setting my global variable to “10”. No matter who is playing my game the global variable is set to “10”. I want to make it so after each time a player plays my game, the global variable is deducted by 1. So from 10, it goes to 9,8,7.... until 0, and I’ll have a screen where if Global variable == 0, no one can play anymore. So the way I thought of is by creating a database table, and storing my variable as “10” in the table, then after each play I will subtract 1, and update the data to the table, so when the next player plays it reads the updated data which is now 9. Or is there any other simpler way of doing this?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hey,

    I am trying to make a wheel of fortune (lucky wheel) game, where there are 8 prizes (Refer to image below).

    Now I'm using construct.net/en/forum/construct-2/how-do-i-18/spinwheel-wheel-fortune-124258 this as a guide, and currently there are the probability of the pointer landing on the each of the boxes is exactly 12.5%, which totals up to a 100% (fair chance). Is there any way I can change this probability without changing the size of the wheel? (All sizes of the wheel remains the same, but altering the chances to something like (The probability of landing on "1" is 50%, 2 is 20%, 3 is 10%.. etc.