dop2000's Recent Forum Activity

  • To make certain traits more rare, all I've done is added more of the same options to the column

    I suggest using the probability tables feature of AdvancedRandom plugin. You can define multiple values with different weights. To make things easier, you can store the entire probability table as a JSON string in the array. I prefer adjusting the weights so that they all add up to 100%. For example:

    [[5,"Super-Abundant"],[20,"Abundant"],[20,"Rich"],[30,"Common"],[25,"Barren"]]
    

    Use AdvancedRandom.weighted expression to return a random value. In the example above, "Super-Abundant" option will have 5% chance to be picked.

    You can store such probability strings for each planet type.

    Although I would suggest using a JSON or multuple JSONs instead of the array. In many cases JSON is much more convenient to work with in C3. You can come up with a good structure which will be easy to read and update. It can be something like this:

    {
     "Ice": {
     "RichnessChances": [[5,"Super-Abundant"],[20,"Abundant"],[20,"Rich"],[30,"Common"],[25,"Barren"]],
     "HabitableChance": 10,
     "Resources": "ice,water,glass"
     },
     "Desert": {
     "RichnessChances": [[1,"Super-Abundant"],[10,"Abundant"],[20,"Rich"],[40,"Common"],[29,"Barren"]],
     "HabitableChance": 30,
     "Resources": "sand,iron,copper"
     }
    }
    
  • no insted of blury i want it to be dark black or black sorry for too much

    Just use a different effect, or cover the screen with black sprite.

  • I tried with the bullet... but the movement becomes random... sometimes it goes up a lot and sometimes the ball goes down... I want it to move at the same height, at the same distance, and at the same speed.

    On collision with the ground, set bullet speed to a fixed value and bullet angle of motion to 270 degrees. It will go up, then drop down again with gravity.

  • It's easy to do with Bullet behavior. Give it gravity and set "Bounce off solids=on".

  • What is "side scroller" behavior? I've never heard of it.

    Check that you are spawning projectiles on the correct layer with 100% parallax

  • With so many different conditions it's tricky to make such code work corectly. Also, OR-blocks in Construct are difficult to work with. I would suggest changing the entire thing like this:

    On every tick
    For Each Button 
    
    .. Local variable activate=0
    
    .. Player overlapping button
    .. OR Boulder overlapping button : Set activate to 1
    
    .. Enemies animation "IceGiant" NOT playing
    .. Enemies overlapping button : Set activate to 1
    
    
    .. Enemies animation "IceGiant" IS playing
    .. Button has LOS to Enemies : Set activate to 1
    
    
    // And now you check if the button should change its state
    .. Button is activated
    .. activate=0 : Button set activated to false, play sound
    
    .. Button is NOT activated
    .. activate=1 : Button set activated to true, play sound
    
    
  • That's because you are using the "Wait" action wrong and picking the same one instance! See my screenshot.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • If you want to delete 5 sprites in the order from nearest to furthest with a small delay between them, try changing the code like this:

  • Is this loop nested under some parent event? You need to explain the task.

    The code you posted will destroy only one SpritesA instance at a time. Even if there are 100 sprite instances on the layout, the loop will repeat 101 times, but every time it will be picking the same single instance - closest to (0,0).

    Then after 0.07s delay it will destroy this one instance 101 times :)

  • Loading remotely is easier for for future edits because base game remains the same however if for web including the file in the project makes it harder to see then the effort would be worth it.

    If it's a web game and you have access to the server where it's hosted, you can simply update the json file, without re-uploading the entire game.

    Loading json from the same server should be more secure.

  • Press F12 in preview and check for error messages in Console tab.

dop2000's avatar

dop2000

Member since 26 May, 2016

Twitter
dop2000 has 256 followers

Connect with dop2000

Trophy Case

  • 8-Year Club
  • Entrepreneur Sold something in the asset store
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Forum Wizard Made 5,000 posts in the forums
  • Forum Unicorn Made 10,000 posts in the forums
  • x5
    Popular Game One of your games has over 1,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • Enduring Visitor Visited Construct.net 90 days in a row
  • Unrelenting Visitor Visited Construct.net 180 days in a row
  • Continuous Visitor Visited Construct.net 365 days in a row
  • RTFM Read the fabulous manual
  • x3
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • x13
    Great Comment One of your comments gets 3 upvotes
  • Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

28/44
How to earn trophies