AllanR's Recent Forum Activity

  • I just tried the repluse game in chrome, and it got stuck. refreshed and then the game played fine - until level 5, where the ball went out through the top of the screen and never came back (every once in a while one of the walls would flash which made me think the ball was still out there bouncing around outside of the game window. Other than that, the game looked great!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • bennettz, you will need a server to store the pictures and host the comments and discussions. Construct 2 could act as a client to send the pictures to the server and handle posting comments, but the back-end server would have to be some kind of database done in MySQL / PHP or something similar...

  • sizcoz

    here is a pinch to zoom capx I made a couple months ago while testing various interface things...

    You can pan around with one finger, zoom with two.

    http://www.rieperts.com/games/forum/TouchZoom.capx

  • Greaver - make the enemy objects Global - so they are not destroyed when you leave the layout. If you randomly create them at the beginning of that layout you will need to set a global variable so that you know not to create them again when you go back to the layout.

    Having the inventory on the same layout shouldn't slow things down it you do it right. If you need lot of code to handle the inventory, you can put that in a group and disable it (the group) when the inventory isn't showing. Then there is no unnecessary code running to slow things down...

  • Tekniko - what I was saying is use "Is Overlapping Another Object" to select only monsters near your player. The only thing I would keep an eye on is generating too many collision checks. You don't have to refer to each monster individually (you can loop through picked monsters if you want), but you can process them in groups: all monsters near player get z-order updated, all monsters outside the area you are checking get ignored. So, what you do is: pick monsters near player, then in a sub event pick monsters with Y less than play and set their z-order behind player, else set z-order in front of player. (the "else" clause would only select the near by monsters that don't have Y less than player)

    Since it sounds like you are talking about a relatively small number of monsters at any one time, you could also use "is on-screen" to select only visible monsters. Or compare X coordinates: pick monsters where abs(player.x - monster.x) < 200 (abs is the absolute value function - that would select monsters within 200 pixels to the left or right of player).

    So, that is three ways to only select monsters near the player and omit other monsters on the layout...

  • Tekniko

    I would check which monsters are overlapping the player, and only move those... or maybe an invisible sprite two or three times bigger than the player called "MosterDetector" and use that to select only the monsters near the player.

    Then if the the moster's Y is greater than player's Y then move the monster in front of player.

    if the monster's Y is less than player's Y then move the monster behind the player.

    that way you don't have to do any looping - just pick monsters overlapping, check the Y coordinates and move the z-order accordingly. Using that method, if your player walked through a whole group of monsters he would pass through them correctly (any higher up the screen would be behind him, and any farther down the screen would be in front).

  • Gogafem

    I did a drawing sample for someone a week or two ago, I very quickly adapted it to do flood fills. It requires the Canvas plugin... not the cleanest code, because it started as a test by my 14 year old son - but it should give you some ideas.

    left clicking draws with a brush, right clicking fills.

    http://www.rieperts.com/games/forum/CanvasPainterFill.capx

  • I'm not sure about how to "store" the different levels

    Yes, I would make them different layouts, but they could all use the same event sheet - because the functionality of the game mechanics is the same.

    Your menu layout would have to know details of what is on each level to be able to set filters... so you could store info about the levels in an array, or hard code it... it depends on how elaborate you want to get.

  • You should only create the limited revolute joint, and not use pin. If the joint is being created properly the head will stay where you want it.

  • Delsetray, it is much easier using a Family...

    but without Family, I would create a global variable, and set it to a random number between 1 and 10 and then create a sprite for each possible result:

    SpawnNumber = Round(Random(1,10))

    Then

    System Compare Variable -> SpawnNumber = 1 -> System Create Object -> Sprite1 on layer 0 at x , y

    System Compare Variable -> SpawnNumber = 2 -> System Create Object -> Sprite2 on layer 0 at x , y

    System Compare Variable -> SpawnNumber = 3 -> System Create Object -> Sprite3 on layer 0 at x , y

    .

    .

    .

    System Compare Variable -> SpawnNumber = 10 -> System Create Object -> Sprite10 on layer 0 at x , y

    Note: you would want to have all those lines be sub-events of some code that decides when you need to spawn a sprite. If they were top level events they would continuously spawn sprites as long as the global variable has a value...

  • rekjl

    PickCount isn't found on any menu, but it is a property you can enter in expressions. You can use Object.count to see how many total instances there are of Object, and you can use Object.PickCount to see how many are currently selected.

    We don't really need PickCount to do what you want, but I added it just to show you how to use it (by displaying the number in a text box).

    I set up your capx the way I described above. I made it show if the piece you click on is blocked from being removed, and it highlights all the pieces above it... (if there are none then it removes the piece).

    http://www.rieperts.com/games/forum/ZorderTest.capx

  • somersetjc

    Ah, for that you could give it bullet behavior, set the speed and angle of motion and initial coordinates. Then place invisible detector sprites at the top and bottom of the layout. When the object hits a detector, reverse the angle of motion.

AllanR's avatar

AllanR

Member since 21 Nov, 2013

Twitter
AllanR has 23 followers

Trophy Case

  • 10-Year Club
  • 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
  • Popular Game One of your games has over 1,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

19/44
How to earn trophies