LBramley1996's Forum Posts

  • I'm creating a test of a game whereby the user must hold down a button which will shoot a ball and they must hold the button for the right amount of time so they get the ball to land on the target. The scores are as follows:

    Green circle - 2 points

    Yellow circle - 5 points

    Red circle - 10 points

    What I'm currently doing in the events is comparing which object the ball is overlapping to determine how many points are added to the score variable. However, when the ball is over the red circle for instance, it's adding 17 to score as it's also overlapping the other two circles.

    Is there a way to get around this?

  • Thanks a lot for your help guys - it works perfectly! Really appreciate it :)

  • The current code I've tried doesn't work at all so it's probably not much use to send over.

    It's to be used in the game layout. Basically, I have 3 different power-ups within the game that the user can get and when they do, I want text to appear and show in big writing the exact power-up they have earned. I've just used text so far as I'd hoped I could do this and set the text dependant on what power-up the user has just acquired, can it not be done using a text object?

  • I'm trying to figure out how to tween text size once it's created. The starting font size is 20 and I want to tween this up to 60, what's the best way to do this?

  • Got it working now, thanks!!

  • In the game, the user earns coins and I have used the local storage plugin to store the number of coins earned by the player. These are then spent on different things in the game but when coins are spent and the player returns to the home screen which displays the number of coins they have, it goes back to the original value. So, basically, I cannot subtract from the coins which I need to do.

    E.g. The user accumulates 200 coins and spends 100. The coins should then show 100 left but it still shows 200. I think it's because I'm setting the value of coins to LocalStorage.ItemValue so it's pulling the previous value and ignoring the subtraction.

    Any ideas how this can be solved?

  • Thanks a lot Dop - the solid border worked! Really appreciate your help :)

  • I have used the bullet behaviour, set to bounce off solids and set bound to layout. This makes the ball fly into the layout but after a few secs it falls to the bottom of the screen and sits there until it's destroyed.

    How do I keep it flying around the screen randomly for the full 10 secs?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thanks Dop, this makes sense. I think I can use a global variable number, randomise this on collision with the gold ball and each number will correspond to a different power-up.

    One last thing, I want the gold ball to appear to be shot into the screen and ping around in various directions randomly before being destroyed after 10 secs if the player hasn't collided with it. How would I go about doing this? All my attempts so far have failed.

    Thanks.

  • Hi Dop, sorry to message again but I'm wondering if you can help with something else.

    In the game, I want the player to get power-ups such as the ability to shoot the red balls, invincibility etc. The player gets a power-up for 10 secs when they collide with a gold ball and I'm using instance variables to do this and also having to use a different gold ball for each power up, and it feels very messy as I'm having to create a lot of events.

    Is there a way I can use one gold ball and randomise which power-up the player gets when they collide with it?

    Is instance variables the best way to go about doing this? I'm not 100% sure it is.

    Let me know what you would do.

    Thanks again.

  • That works - cheers Dop! Much appreciated.

  • I'm creating a game where the player (blue ball) has to dodge the red balls for as long as possible. The player can also shoot the red balls to destroy them but how do I set the angle of motion of the bullet to the correct touch?

    The player moves using drag and drop behaviour, so is already touching and to shoot the enemies they tap them. However, when I set the angle of motion to Touch.X and Touch.Y, it's using the X and Y of the player and not the second tap.

    Tagged:

  • I'm creating a daily quiz game but I only want each user to be able to play once-a-day.

    After the user has completed the quiz, they won't be able to answer more questions until the following day.

    I've tried to do this using a global boolean and setting it to false at the end of the quiz and then setting it to true once the time is midnight (using date plugin) but I don't think I've done this right as it's not working.

    What is the best way of doing this?

  • Got it! Works perfectly now - thanks a lot Lionz!! :)

  • Thanks Lionz. I've realised where I'm going wrong now - the question number variable is being added to after the player answers a question and it's also being added to when the countdown variable is equal to or less than zero. I need both of these within the project but how do I get it to only add one if the player has answered when the countdown variable is equal to zero?