imhotep22's Recent Forum Activity

  • You have to do some debugging, start the game in debug mode on the right side click profile, and see what events take the most CPU time, then you will know what is making the lag.

  • I made you an example have a look.

    https://www.dropbox.com/s/fkaeepyh484k810/move_animation.capx?dl=0

  • Okay I see what are you trying to do, when you change the color it changes for every single instance, but you want it change for 1 only. This can be little tricky to implement. Add a global variable called color_picker, add the same variable as a instance variable to the square object. When you create your object increment both the local and the global variable by 1. Add the change color function, and call it with a parameter which is equal to the instance variable. This means that the function will trigger only once on the object with the current id, the next will spawn with different id because we are increment it by 1 each time you create the object and it wont be effect by the function.

  • Are you sure the variable are the ones causing the lag? I suggest running in debug move and in the event tab see what takes the most memory from the system.

  • Use a 9-patch for the rectangle, then you can resize it how you want without huge loss on quality.

  • Implementing a system clock is the way to go, wall clock can be easy abused because it uses the user time, which he can easy change to get some kind of advantage.

    I had a simple clock on my game implement with 3 variable, 1 for seconds, 1 for minutes and 1 for hours, every 1 second when the game should be running I increment the second variable by 1, when it gets to 60 I reset it to 0, and add 1 to minutes, when minutes get to 60 I reset it to 0 and add 1 to hours. You can make a simple clock like that, and If you want to continue where it stoped after the game is closed, you can keep the variable values in a json file and load that on game start.

  • When you recreate a new instance of an object, construct 2 uses its default values to Initialize the instance. You can have the function called after the new object is created to change its stats, or keep the first instance of the object somewhere in the layout, and change it values on layout load.

  • You are welcome, good luck with the game

  • That's the problem, I did the same thing as you described above, and I was unable to add more then 5 image points on some of the animation, sadly you will probably have to delete the whole sprite with all of its animation and assign all the image points manually so you don't get the cap.

    I am not sure if this a bug or just intended that way, so can maybe report it under the bug section.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Here is an example I made just now. You can make the scroll sprite invisible in the game, I just made it visible now for testing purposes.

    dropbox.com/s/gfrd4v2oqw2w6em/Mouse_scroll.capx?dl=0

  • That's weird, I tried testing on my construct projects, and there is no limit at all, I added up to 80-120 image points on all my frames and it kept going.

    You can try adding a test sprite and see if same thing happens to it.

  • There is no maximum number of image points. What error are you getting beyond 21 image point, the button does not work? And why do you need like 30 image points per frame?

imhotep22's avatar

imhotep22

Member since 18 May, 2017

None one is following imhotep22 yet!

Connect with imhotep22

Trophy Case

  • 7-Year Club
  • Coach One of your tutorials has over 1,000 readers
  • Email Verified

Progress

9/44
How to earn trophies